Description of problem: Fedora (and many other distros) provide pre-built cloud images. These typically have no default password set, requiring the cloud-init service to pull a password and/or ssh public key off the host metadata service, or config-drive disk. It would be desirable to use the pre-built cloud images in non-cloud world, using virt-manager and/or virt-install --import. Without a way to populate the login password/ssh keys, this isn't practical http://fedoraproject.org/en/get-fedora-options#clouds It would be desirable if virt-install have a way to specify arbitrary key,value pairs to populate the metadata source. It could then auto-generate a disk image to act as a config drive thus: http://ubuntu-smoser.blogspot.co.uk/2013/02/using-ubuntu-cloud-images-without-cloud.html
Moving to the upstream tracker
See also http://rwmj.wordpress.com/2013/12/10/creating-a-cloud-init-config-disk-for-non-cloud-boots/
Dan, Would it be a good first step if virt-install/virt-manager had the ability to accept a file or directory to use and build a resulting iso image and attach it to the guest on install/import? Key/Value pair could come later.
1+
Work for this is committed upstream. Simplest invocation is: virt-install --cloud-init ... Which will generate a random root password, print it to the console, and set cloud-init to be disabled after the first boot up. This is to facilitate the case of grabbing a distro cloud image and wanting to use it like a regular VM. --cloud-init has some suboptions for different usecases: $ ./virt-install --cloud-init=help --cloud-init options: disable meta-data root-password-file root-password-generate ssh-key user-data For example, user-data=/path/to/user-data for cloudinit user-data passthrough, and ssh-key=/path/to/ssh-key.pub for initializing the default user with your ssh key. Setting to MODIFIED, I will close when a new release is out
This is in virt-manager 3.0.0 release now