Skip to content

Instantly share code, notes, and snippets.

@andersonvom
Created July 23, 2015 16:44
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save andersonvom/c87f7c5791b201c58dae to your computer and use it in GitHub Desktop.
Save andersonvom/c87f7c5791b201c58dae to your computer and use it in GitHub Desktop.
Bootstrap script to set up puppetmaster according to openstack-infra/system-config
#!/bin/bash
apt-get update
apt-get upgrade -y
apt-get install git -y
git clone https://git.openstack.org/openstack-infra/system-config /opt/system-config/production
/opt/system-config/production/install_puppet.sh
apt-get install puppetmaster-passenger hiera hiera-puppet -y
export REAL_HOSTNAME=puppetmaster.openstack.org
bash /opt/system-config/production/install_modules.sh
echo $REAL_HOSTNAME > /etc/hostname
service hostname restart
puppet apply --debug --verbose --modulepath='/opt/system-config/production/modules:/etc/puppet/modules' -e "
node 'puppetmaster.openstack.org' {
class { 'openstack_project::server':
iptables_public_tcp_ports => [4505, 4506, 8140],
sysadmins => hiera('sysadmins', []),
pin_puppet => '3.6.',
}
class { 'openstack_project::puppetmaster':
root_rsa_key => hiera('puppetmaster_root_rsa_key', 'XXX'),
}
}
"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment