Move /opt/system-config/production to /opt/system-config

The production directory is a relic from the puppet environment concept,
which we do not use. Remove it.

The puppet apply tests run puppet locally, where the production
environment is still needed, so don't update the paths in the
tools/prep-apply.sh.

Depends-On: https://review.openstack.org/592946
Change-Id: I82572cc616e3c994eab38b0de8c3c72cb5ec5413
This commit is contained in:
Monty Taylor 2018-08-16 18:56:30 -05:00
parent 7a0ac4ce03
commit 1a8c2f66da
No known key found for this signature in database
GPG Key ID: 7BAE94BC7141A594
14 changed files with 27 additions and 26 deletions

View File

@ -368,7 +368,7 @@ read-write volumes.
.. code-block:: console
root@puppetmaster:~# /opt/system-config/production/tools/hieraedit.py \
root@puppetmaster:~# /opt/system-config/tools/hieraedit.py \
--yaml /etc/puppet/hieradata/production/fqdn/mirror-update.openstack.org.yaml \
-f /path/to/foo.keytab KEYNAME

View File

@ -244,10 +244,10 @@ then deleted from disk.
.. code-block:: bash
root@puppetmaster:~# cd /etc/zuul-ca
root@puppetmaster:/etc/zuul-ca# /opt/system-config/production/tools/hieraedit.py \
root@puppetmaster:/etc/zuul-ca# /opt/system-config/tools/hieraedit.py \
> --yaml /etc/puppet/hieradata/production/group/gearman.yaml \
> -f newreq.pem gearman_ssl_key
root@puppetmaster:/etc/zuul-ca# /opt/system-config/production/tools/hieraedit.py \
root@puppetmaster:/etc/zuul-ca# /opt/system-config/tools/hieraedit.py \
> --yaml /etc/puppet/hieradata/production/group/gearman.yaml \
> -f newcert.pem gearman_ssl_cert
root@puppetmaster:/etc/zuul-ca# shred newreq.pem

View File

@ -379,7 +379,7 @@ An example of a task event from the running system is::
"puppetmaster": null,
"show_diff": false,
"certname": null,
"manifest": "/opt/system-config/production/manifests/site.pp",
"manifest": "/opt/system-config/manifests/site.pp",
"environment": "production",
"debug": false,
"noop": false,

View File

@ -457,7 +457,7 @@ To rename a project:
#. Run the ansible rename repos playbook, passing in the path to your yaml
file::
sudo ansible-playbook -f 10 /opt/system-config/production/playbooks/rename_repos.yaml -e repolist=ABSOLUTE_PATH_TO_VARS_FILE
sudo ansible-playbook -f 10 /opt/system-config/playbooks/rename_repos.yaml -e repolist=ABSOLUTE_PATH_TO_VARS_FILE
#. :ref:`Force-merge <force-merging-a-change>` the prepared Puppet
configuration changes.

View File

@ -46,12 +46,12 @@ Ansible and Puppet 3 is known to run on Precise, Trusty, Centos 6 and Centos 7.
.. code-block:: bash
sudo su -
git clone https://git.openstack.org/openstack-infra/system-config /opt/system-config/production
bash /opt/system-config/production/install_puppet.sh
bash /opt/system-config/production/install_modules.sh
git clone https://git.openstack.org/openstack-infra/system-config /opt/system-config
bash /opt/system-config/install_puppet.sh
bash /opt/system-config/install_modules.sh
echo $REAL_HOSTNAME > /etc/hostname
service hostname restart
puppet apply --modulepath='/opt/system-config/production/modules:/etc/puppet/modules' -e 'include openstack_project::puppetmaster'
puppet apply --modulepath='/opt/system-config/modules:/etc/puppet/modules' -e 'include openstack_project::puppetmaster'
Hiera uses a systemwide configuration file in ``/etc/puppet/hiera.yaml``
and this setup supports multiple configurations. The two sets of environments
@ -82,7 +82,7 @@ Adding a node
-------------
For adding a new node to your puppet master, you can either use the
``/opt/system-config/production/launch/launch-node.py`` script
``/opt/system-config/launch/launch-node.py`` script
(see :cgit_file:`launch/README` for full details) or bootstrap puppet manually.
For manual bootstrap, you need to run on the new server connecting
@ -101,7 +101,7 @@ In OpenStack's Infrastructure, puppet runs are triggered from a cronjob
running on the puppetmaster which in turn runs a single run of puppet apply on
each host we know about.
The entry point for this process is ``/opt/system-config/production/run_all.sh``
The entry point for this process is ``/opt/system-config/run_all.sh``
There are a few sets of nodes which have their own playbooks so that they
are run in sequence before the rest of the nodes are run in parallel.
@ -110,12 +110,12 @@ creation of the master repos on the gerrit server.
If an admin needs to run puppet by hand, it's a simple matter of either
logging in to the server in question and running
`puppet apply /opt/system-config/production/manifests/site.pp` or, on the
`puppet apply /opt/system-config/manifests/site.pp` or, on the
puppetmaster, running:
.. code-block:: bash
ansible-playbook --limit="$HOST:localhost" /opt/system-config/production/playbooks/remote_puppet_adhoc.yaml
ansible-playbook --limit="$HOST:localhost" /opt/system-config/playbooks/remote_puppet_adhoc.yaml
as root, where `$HOST` is the host you want to run puppet on.
The `:localhost` is important as some of the plays depend on performing a task

View File

@ -27,7 +27,7 @@ To launch a node in the OpenStack CI account (production servers)::
export OS_REGION_NAME=DFW
export FLAVOR="8 GB Performance"
export FQDN=servername01.openstack.org
cd /opt/system-config/production/launch/
cd /opt/system-config/launch/
./launch-node.py $FQDN --flavor "$FLAVOR" \
--cloud=$OS_CLOUD --region=$OS_REGION_NAME

View File

@ -1,7 +1,8 @@
copy_hieradata: true
copy_puppet: true
manifest: /opt/system-config/production/manifests/site.pp
manifest: /opt/system-config/manifests/site.pp
manifest_base: /opt/system-config
mgmt_manifestpath: /opt/system-config
puppet_logdest: syslog
distro_lookup_path:
- "{{ ansible_facts.distribution }}.{{ ansible_facts.lsb.codename }}.{{ ansible_facts.architecture }}.yaml"
@ -21,7 +22,7 @@ puppet:
logdest: syslog
copy_hieradata: true
copy_puppet: true
manifest: /opt/system-config/production/manifests/site.pp
manifest: /opt/system-config/manifests/site.pp
manifest_base: /opt/system-config
# When adding new users, always pick a UID larger than the last UID, do not

View File

@ -4,7 +4,7 @@ library=/usr/share/ansible
log_path=/var/log/ansible.log
callback_plugins=/etc/ansible/callback_plugins
inventory_plugins=/etc/ansible/inventory_plugins
roles_path=/opt/system-config/production/roles:/etc/ansible/roles
roles_path=/opt/system-config/roles:/etc/ansible/roles
retry_files_enabled=False
retry_files_save_path=
gathering=smart

View File

@ -7,15 +7,15 @@
- name: Make sure system-config repo is up to date
git:
repo: https://git.openstack.org/openstack-infra/system-config
dest: /opt/system-config/production
dest: /opt/system-config
force: yes
- name: Clone puppet modules to /etc/puppet/modules
command: ./install_modules.sh
args:
chdir: /opt/system-config/production
chdir: /opt/system-config
- name: Install ansible roles to /etc/ansible/roles
command: ansible-galaxy install --force -r roles.yaml
args:
chdir: /opt/system-config/production
chdir: /opt/system-config

View File

@ -3,10 +3,10 @@
tasks:
- git:
repo: https://git.openstack.org/openstack-infra/system-config
dest: /opt/system-config/production
dest: /opt/system-config
force: yes
- shell: ./install_puppet.sh
args:
chdir: /opt/system-config/production
chdir: /opt/system-config
environment:
PUPPET_VERSION: 4

View File

@ -19,7 +19,7 @@
# expect.
set -e
export ANSIBLE_LOG_PATH=/var/log/puppet_run_all.log
SYSTEM_CONFIG=/opt/system-config/production
SYSTEM_CONFIG=/opt/system-config
ANSIBLE_PLAYBOOKS=$SYSTEM_CONFIG/playbooks
# It's possible for connectivity to a server or manifest application to break

View File

@ -19,7 +19,7 @@
# expect.
set -e
export ANSIBLE_LOG_PATH=/var/log/puppet_run_cloud_launcher.log
SYSTEM_CONFIG=/opt/system-config/production
SYSTEM_CONFIG=/opt/system-config
ANSIBLE_PLAYBOOKS=$SYSTEM_CONFIG/playbooks
# It's possible for connectivity to a server or manifest application to break

View File

@ -19,7 +19,7 @@
# expect.
set -e
export ANSIBLE_LOG_PATH=/var/log/puppet_run_all_infracloud.log
SYSTEM_CONFIG=/opt/system-config/production
SYSTEM_CONFIG=/opt/system-config
ANSIBLE_PLAYBOOKS=$SYSTEM_CONFIG/playbooks
# It's possible for connectivity to a server or manifest application to break

View File

@ -16,5 +16,5 @@
for playbook in base.yaml remote_puppet_adhoc.yaml ; do
ansible-playbook -f1 --limit $1 \
/opt/system-config/production/playbooks/$playbook
/opt/system-config/playbooks/$playbook
done