Hello,
I am having a lot of trouble getting cloud-init user data to work when attempting to deploy a machine through the cli/api. Deployment kicks off but the user_data=x seems to have no effect in the cli, uploading it via web gui it works as expected.
[Config File at /home/aweare/cloud-init/user-data]
#cloud-config
user: terminal
password: MyHorribleLabPass
chpasswd: {expire: False}
ssh_pwauth: True
package_update: true
package_upgrade: true
runcmd:
- ‘curl -L https://bootstrap.saltstack.com -o install_salt.sh’
- ‘sh install_salt.sh -A [SaltStack URI]’
- ‘apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 78BD65473CB3BD13’
[cmds]
user_data=$(base64 -w 0 /home/aweare/cloud-init/user-data)
maas aweare machine deploy mktpfp user_data=$user_data
I am following this:
Am I missing something here?