Bootstrap Ubuntu 11.10 Instances with Cloud-config User-Data and Puppet
4/29/2012 12:32:00 AM
Posted by johnhomer
Assuming you or HPCloud already worked out DNS' PTR issue and a puppet master host is setup, you can use the following user-data to bootstrap an Ubuntu server instance:
#cloud-config puppet: conf: agent: server: "PUPPET-MASTER-FQDN" puppetd: listen: true # /var/lib/puppet/ssl/ca/ca_crt.pem on the puppetmaster host. ca_cert: | -----BEGIN CERTIFICATE----- PUT-CERT-HERE -----END CERTIFICATE----- runcmd: - |- echo "path /run method save allow PUPPET-MASTER-FQDN" >> /etc/puppet/auth.conf - |- echo "[puppetrunner] allow PUPPET-MASTER-FQDN" >> /etc/puppet/namespaceauth.conf
Note: Make sure that the cloud-config user-data is a valid YAML file, go here to check.
To run a server instance with a User-Data, setup euca2ools CLI, then run:
euca-run-instances ami-000015cb -t standard.xsmall -g Web -k hpcloud -f user-data.txt
All you need to do after is sign the certificate request at the puppet master host and do a puppetrun:
puppetca --list puppetca --sign PUPPET-CLIENT-FQDN puppetrun PUPPET-CLIENT-FQDN
If you goes well, you should be able to administer every aspect of an Ubuntu server instance from the puppet master host with manifest files.
This entry was posted on October 4, 2009 at 12:14 pm, and is filed under
cloud,
hpcloud
. Follow any responses to this post through RSS. You can leave a response, or trackback from your own site.
Subscribe to:
Post Comments (Atom)
Post a Comment