Does cloud-init store the copy of the init it ran first?
-
I'm sending my cloud-init file to Terraform via
user_data
. Is this stored anywhere on the machine that runs it? I know it may get merged with other stuff before it's run.
-
It seems to be stored under
/var/lib/cloud/instances
Under your https://devops.stackexchange.com/q/15483/18965 .
cd /var/lib/cloud/instances/$(cloud-init query instance_id)
For me I found the information I wanted in
user-data.txt
.sudo cat "/var/lib/cloud/instances/$(cloud-init query instance_id)/user-data.txt"