Revert "Adds second hiera data directory"

This did not seem to work.

This reverts commit ed57cef9c5
This commit is contained in:
James E. Blair 2014-03-31 21:06:37 +00:00 committed by Gerrit Code Review
parent ed57cef9c5
commit 56562d83f7
12 changed files with 12 additions and 21 deletions

View File

@ -1 +0,0 @@
---

View File

@ -1 +0,0 @@
---

View File

@ -1 +0,0 @@
---

View File

@ -49,7 +49,7 @@ compatible, so be sure to use an older release - e.g. Ubuntu Precise.
sudo su - sudo su -
git clone https://git.openstack.org/openstack-infra/config /opt/config/production git clone https://git.openstack.org/openstack-infra/config /opt/config/production
/opt/config/production/install_puppet.sh /opt/config/production/install_puppet.sh
apt-get install puppetmaster-passenger apt-get install puppetmaster-passenger hiera hiera-puppet
Finally, install the modules, fix your hostname and use ``puppet apply`` to Finally, install the modules, fix your hostname and use ``puppet apply`` to
finish configuration: finish configuration:
@ -59,7 +59,7 @@ finish configuration:
bash /opt/config/production/install_modules.sh bash /opt/config/production/install_modules.sh
echo $REAL_HOSTNAME > /etc/hostname echo $REAL_HOSTNAME > /etc/hostname
service hostname restart service hostname restart
puppet apply --confdir=$(pwd) --modulepath='/opt/config/production/modules:/etc/puppet/modules' -e 'include openstack_project::puppetmaster' puppet apply --modulepath='/opt/config/production/modules:/etc/puppet/modules' -e 'include openstack_project::puppetmaster'
Note: Hiera uses a systemwide configuration file in ``/etc/puppet/hiera.yaml`` Note: Hiera uses a systemwide configuration file in ``/etc/puppet/hiera.yaml``
and this setup supports multiple configurations. The two sets of environments and this setup supports multiple configurations. The two sets of environments

View File

@ -88,7 +88,7 @@ repository::
./install_puppet.sh ./install_puppet.sh
./install_modules.sh ./install_modules.sh
puppet apply -l /tmp/manifest.log --confdir=`pwd` --modulepath=modules:/etc/puppet/modules manifests/local.pp puppet apply -l /tmp/manifest.log --modulepath=modules:/etc/puppet/modules manifests/local.pp
That should turn the system you are logged into into an etherpad That should turn the system you are logged into into an etherpad
server with the same configuration as that used by the OpenStack server with the same configuration as that used by the OpenStack

View File

@ -1 +0,0 @@
modules/openstack_project/files/puppetmaster/hiera.yaml

View File

@ -24,7 +24,7 @@ if cat /etc/*release | grep -e "CentOS" -e "Red Hat" &> /dev/null; then
# yum-config-manager --enable rhel-6-server-optional-rpms # yum-config-manager --enable rhel-6-server-optional-rpms
# NOTE: we preinstall lsb_release to ensure facter sets lsbdistcodename # NOTE: we preinstall lsb_release to ensure facter sets lsbdistcodename
yum install -y redhat-lsb-core git puppet heira heira-puppet yum install -y redhat-lsb-core git puppet
else #defaults to Ubuntu else #defaults to Ubuntu
@ -41,11 +41,11 @@ else #defaults to Ubuntu
apt-get update apt-get update
apt-get dist-upgrade apt-get dist-upgrade
apt-get install -y puppet git rubygems heira heira-puppet apt-get install -y puppet git rubygems
fi fi
git clone https://git.openstack.org/openstack-infra/config git clone https://git.openstack.org/openstack-infra/config
bash config/install_modules.sh bash config/install_modules.sh
puppet apply --confdir=$(pwd) --modulepath=$(pwd)/config/modules:/etc/puppet/modules -e 'node default {class { "openstack_project::bare_slave": install_users => false }}' puppet apply --modulepath=`pwd`/config/modules:/etc/puppet/modules -e 'node default {class { "openstack_project::bare_slave": install_users => false }}'

View File

@ -63,7 +63,7 @@ EOF
# yum-config-manager --enable rhel-6-server-optional-rpms # yum-config-manager --enable rhel-6-server-optional-rpms
# NOTE: we preinstall lsb_release to ensure facter sets lsbdistcodename # NOTE: we preinstall lsb_release to ensure facter sets lsbdistcodename
yum install -y redhat-lsb-core git puppet heira hiera-puppet yum install -y redhat-lsb-core git puppet
else else
#defaults to Ubuntu #defaults to Ubuntu
# NB: keep in sync with openstack_project/files/00-puppet.pref # NB: keep in sync with openstack_project/files/00-puppet.pref
@ -83,5 +83,5 @@ EOF
DEBIAN_FRONTEND=noninteractive apt-get --option 'Dpkg::Options::=--force-confold' \ DEBIAN_FRONTEND=noninteractive apt-get --option 'Dpkg::Options::=--force-confold' \
--assume-yes dist-upgrade --assume-yes dist-upgrade
DEBIAN_FRONTEND=noninteractive apt-get --option 'Dpkg::Options::=--force-confold' \ DEBIAN_FRONTEND=noninteractive apt-get --option 'Dpkg::Options::=--force-confold' \
--assume-yes install -y --force-yes puppet git rubygems hiera hiera-puppet --assume-yes install -y --force-yes puppet git rubygems
fi fi

View File

@ -45,10 +45,10 @@ sudo git clone --depth=1 git://git.openstack.org/openstack-infra/config.git \
/root/config /root/config
sudo /bin/bash /root/config/install_modules.sh sudo /bin/bash /root/config/install_modules.sh
if [ -z "$NODEPOOL_SSH_KEY" ] ; then if [ -z "$NODEPOOL_SSH_KEY" ] ; then
sudo puppet apply --confdir=/root/config --modulepath=/root/config/modules:/etc/puppet/modules \ sudo puppet apply --modulepath=/root/config/modules:/etc/puppet/modules \
-e "class {'openstack_project::single_use_slave': sudo => $SUDO, bare => $BARE, python3 => $PYTHON3, include_pypy => $PYPY, all_mysql_privs => $ALL_MYSQL_PRIVS, }" -e "class {'openstack_project::single_use_slave': sudo => $SUDO, bare => $BARE, python3 => $PYTHON3, include_pypy => $PYPY, all_mysql_privs => $ALL_MYSQL_PRIVS, }"
else else
sudo puppet apply --confdir=/root/config --modulepath=/root/config/modules:/etc/puppet/modules \ sudo puppet apply --modulepath=/root/config/modules:/etc/puppet/modules \
-e "class {'openstack_project::single_use_slave': install_users => false, sudo => $SUDO, bare => $BARE, python3 => $PYTHON3, include_pypy => $PYPY, all_mysql_privs => $ALL_MYSQL_PRIVS, ssh_key => '$NODEPOOL_SSH_KEY', }" -e "class {'openstack_project::single_use_slave': install_users => false, sudo => $SUDO, bare => $BARE, python3 => $PYTHON3, include_pypy => $PYPY, all_mysql_privs => $ALL_MYSQL_PRIVS, ssh_key => '$NODEPOOL_SSH_KEY', }"
fi fi

View File

@ -1,13 +1,8 @@
--- ---
:hierarchy: :hierarchy:
- fqdn/%{::fqdn}
- %{::osfamily}/%{::lsbdistcodename}
- %{::osfamily}/common
- %{operatingsystem} - %{operatingsystem}
- common - common
:backends: :backends:
- yaml - yaml
:yaml: :yaml:
:datadir: '/etc/puppet/hieradata/%{environment}' :datadir: '/etc/puppet/hieradata/%{environment}'
:datadir: '%{confdir}/data'
:datadir: '/opt/config/%{environment}/data'

View File

@ -13,4 +13,4 @@ MANIFEST_LOG=/var/log/manifest.log
cd $BASE_DIR cd $BASE_DIR
/usr/bin/git pull -q && \ /usr/bin/git pull -q && \
/bin/bash install_modules.sh && \ /bin/bash install_modules.sh && \
/usr/bin/puppet apply -l $MANIFEST_LOG --confdir=$BASE_DIR --modulepath=$MODULE_PATH manifests/site.pp /usr/bin/puppet apply -l $MANIFEST_LOG --modulepath=$MODULE_PATH manifests/site.pp

View File

@ -13,5 +13,5 @@ sed -i -e 's/hiera..sysadmins../["admin"]/' applytest/puppetapplytest*
sed -i -e 's/hiera..listadmins../["admin"]/' applytest/puppetapplytest* sed -i -e 's/hiera..listadmins../["admin"]/' applytest/puppetapplytest*
sed -i -e 's/hiera.*/PASSWORD,/' applytest/puppetapplytest* sed -i -e 's/hiera.*/PASSWORD,/' applytest/puppetapplytest*
for f in `find applytest -name 'puppetapplytest*' -print` ; do for f in `find applytest -name 'puppetapplytest*' -print` ; do
puppet apply --confdir=$(pwd) --modulepath=./modules:/etc/puppet/modules -v --noop --debug $f >/dev/null puppet apply --modulepath=./modules:/etc/puppet/modules -v --noop --debug $f >/dev/null
done done