Wikimedia Labs/Instance creation improvement project

Instance creation, though currently fully automated, is slow and doesn't provide enough feedback. This project aims to make this better.

Bootstrapping
Here's the current bootstrapping method:


 * 1) User creates an instance
 * 2) OpenStackManager calls the OpenStack Nova API and creates an instance, injecting a bootstrapping script into the instance's UserData
 * 3) OpenStackManager adds an LDAP entry for puppet
 * 4) * Have nova handle this?
 * 5) OpenStackManager adds an LDAP entry for DNS, minus the A record
 * 6) OpenStackManager adds a job into the job queue that waits until nova-network has assigned an IP address to the instance. When the IP address is assigned, the job adds the IP address into the instance's LDAP DNS A record.
 * 7) * Bug 46818: Have an OpenStack service handle DNS.
 * 8) The instance boots, gets its IP and DNS information from DHCP
 * 9) The instance runs cloud-init, pulling its information from UserData. It then executes the bootstrapping script
 * 10) The bootstrapping script installs puppet, and forces a puppet run
 * 11) The initial puppet run requests a certificate signature from the puppet master
 * 12) The puppet master has a cron that runs every minute to check for new certificate requests. When a new request comes it, it checks to see if the certificate's name is an entry in LDAP. If so, it signs it.
 * 13) After the signature request is signed, the puppet run continues on the client, instance creation is finished when this is done
 * 14) * Bug 32163: At this point we should fire an event to the master that lists the instance's ssh fingerprint and store the fingerprint in MediaWiki, or possibly in the instance's metadata in nova.