cloud-init user-data not working via OVF iso data source on vSphere 6
I recently downloaded the OVA version of the Ubuntu 16.04 cloud image (release-20160721) to import into my vSphere 6 based environment.
https:/
The OVA exposes cloud-init config values as vApp Options such that you can enter values into the deployment wizard and they will be passed to cloud-init via a mounted ISO that gets processed by the OVF datasource in cloud-init. All of the exposed options (e.g. hostname, default user password) seem to be working except "Encoded user-data".
I'm trying to embed a simple #cloud-config script into user-data just to test the functionality. The contents of the script is this.
#cloud-config
users:
- name: demo
The help text for "Encoded user-data" claims the data entered should be base64 encoded. "In order to fit into a xml attribute, this value is base64 encoded. It will be decoded, and then processed normally as user-data." The base64 encoded version of my #cloud-config script is this.
I2Nsb3VkLWNvbmZ
But when I enter that base64 encoded value into the deployment wizard, the demo user is never created and the following warning shows up in the cloud-init.log file.
__init_
If I skip the base64 encoding and just try to paste the raw #cloud-config script manually into the wizard, things get slightly better. Cloud-init seems to recognize the script from the "#cloud-config" header and set the mime type appropriately. But all of the line breaks get stripped out which invalidates the yaml format of the file.
util.py[DEBUG]: Attempting to load yaml from string of length 33 with allowed root types (<class 'dict'>,)
util.py[WARNING]: Failed loading yaml blob
util.py[DEBUG]: Failed loading yaml blob#012Traceback (most recent call last):#012 File "/usr/lib/
util.py[WARNING]: Failed at merging in cloud config part from part-001
util.py[DEBUG]: Failed at merging in cloud config part from part-001#
Does anyone have an idea what I'm doing wrong here?
Question information
- Language:
- English Edit question
- Status:
- Expired
- For:
- Ubuntu Edit question
- Assignee:
- No assignee Edit question
- Last query:
- Last reply: