Red Hat Bugzilla – Bug 990572
cloud-init integration - REST API
Last modified: 2015-10-27 19:57:47 EDT
merged to master, pending ovirt-engine-3.3 backport acceptance
Hi, can this one get backported in 3.3.1 or at least 3.3.2?
I would help and provide testing for this.
Verified in rhevm-3.3.0-0.44.el6ev.noarch (is31).
1. Create new fresh VM with two network interfaces. I used RHEL 6.5 x86_64 with installed cloud-init-0.7.2-2.el6.noarch.
2. In your favorite REST client send the attached XML request via POST method to https://<fqdn>/api/vms/<vm-uuid>/start
- see example at http://www.ovirt.org/Features/Cloud-Init_Integration - API Design section
3. When the VM is fully started, log into it (using the specified root password and also with SSH key) and check the following:
* hostname (/etc/sysconfig/network)
* network interfaces (IP address, mask, boot protocol, gateway)
* DNS settings (/etc/resolv.conf)
* system time zone (/etc/sysconfig/clock)
* new file with proper content (/tmp/file1.txt)
All data are corresponding with those from the XML request.
Optionally, the cloud-init config drive data are visible via REST API as the CD-ROM payload. Do a GET request on the VM (https://<fqdn>/api/vm/<vm-uuid>/) and search for the <payload type="cdrom"> node.
Created attachment 850603 [details]
REST API request to run VM with cloud-init data
Closing - RHEV 3.3 Released