terraform-provider-ignition icon indicating copy to clipboard operation
terraform-provider-ignition copied to clipboard

RFE: Allow ignition_file to append to a file

Open nhi-vanye opened this issue 7 years ago • 2 comments

It would be nice to allow appending content to files rather than over-writing the existing content

The use case is to add environment variables to /etc/profile.env to set the HTTP_PROXY variable so the newly deployed OS can access the internet.

nhi-vanye avatar Jul 10 '18 16:07 nhi-vanye

Ignition works only during the first VM startup. That's why even you change the content of the file and suppress the recreation of the VM (due to the custom data change) you will never get an expected result.

IvanovOleg avatar Jun 28 '19 14:06 IvanovOleg

The current ignition version (since 2.2.0) supports appending to files:

append (boolean): whether to append to the specified file. Creates a new file if nothing exists at the path. Cannot be set if overwrite is set to true.

Spec: https://coreos.com/ignition/docs/latest/configuration-v2_3.html

captn3m0 avatar Jul 15 '19 08:07 captn3m0