Packer: allow templates to be defined using yaml

Created on 23 Nov 2016  ยท  5Comments  ยท  Source: hashicorp/packer

Please allow templates to be defined in YAML. It is easier to read and, more importantly, allows comments.

It is a common use case, even Amazon now allows CloudFormation to be defined with YAML.

duplicate question

Most helpful comment

I would really like to put comments in my config files without having to process my config files

All 5 comments

You can just do:

cat template.yaml | ruby -r json -r yaml -e "yaml = YAML.load(ARGF.read); print yaml.to_json"

Duplicates #1047

edit: actually I think we want this to be done outside packer regardless

We may in the future however support hcl which supports comments.

I would really like to put comments in my config files without having to process my config files

I'm going to lock this issue because it has been closed for _30 days_ โณ. This helps our maintainers find and focus on the active issues.

If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

Was this page helpful?
0 / 5 - 0 ratings