I am using openstack to create a VM using \'nova boot\' command. My image is cloud-init enabled. I pass a --user-data script which is a bash shell format for cloud-init to run d
Since this keeps popping up in search results, what works for me:
Delete semaphores in /var/lib/cloud/instances/i-xxxxxxx/sem
. Cloud-init will not re-run if these files are present.
Edit /var/lib/cloud/instances/i-xxxxxxxx/scripts/part-001
. This is your user-data script.
Execute only the user scripts module of cloud-init. This will not re-download user data but execute the already downloaded (and now, modified) script from step 2.
sudo /usr/bin/cloud-init single -n cc_scripts_user