Right now we use vars section in the cfn-compose.yml file to supply go template variables and replace with them dynamically in the rest of the template configuration. Since the template and variables are declared in the same template we need to parse cfn-compose.yml file twice.
one just to scan the vars as key value pairs and
other to replace the template variable in the compose configuration.
It might be better to separate vars section as a separate file to have better control, extensibility and independence for future use cases.
Summary Example Compose file:
Right now we use
vars
section in thecfn-compose.yml
file to supply go template variables and replace with them dynamically in the rest of the template configuration. Since the template and variables are declared in the same template we need to parsecfn-compose.yml
file twice.It might be better to separate
vars section
as a separate file to have better control, extensibility and independence for future use cases.