Hello
I have FreeBSD 14.2 setup with py311-cloud-init-24.1.4_2 package. I have enabled
Now, I have created a user-data file under /root/cloud/ with following content
I have cleared /var/run/cloud-init directory and started the cloud-init service
However nothing happened. I was expected 2 files to be created in /root/cloud folder.
Am I missing anything?
I have FreeBSD 14.2 setup with py311-cloud-init-24.1.4_2 package. I have enabled
cloudinit_enable="YES"
in rc.conf. All cloudinit config files are located in /usr/local/etc/cloud/ and I have added an new config file under /usr/local/etc/cloud.cfg.d/00_nocloud.cfg
Code:
datasource_list: ["NoCloud","None"]
datasource:
NoCloud:
seedfrom: file:///root/cloud/
network:
config: disabled
timeout: 1
Now, I have created a user-data file under /root/cloud/ with following content
Code:
#cloud-config
# run an arbitrary command very early on
bootcmd:
- echo bootcmd | tee -a /root/cloud/cloudinit_was_here
# touch arbitrary files very early on, note YAML list for multiple files
write_files:
- content: |
writefiles
path: /root/cloud/cloudinit_was_here
append: true
- content: |
writefiles
path: /root/cloud/writefiles_was_here
append: true
# run an arbitrary command later on
runcmd:
- echo runcmd | tee -a /root/cloud/cloudinit_was_here
I have cleared /var/run/cloud-init directory and started the cloud-init service
Code:
service cloudinit start
cloud-init --debug init --local
cloud-init --debug init
cloud-init --debug modules --mode config
cloud-init modules --mode final
Am I missing anything?