Templating (deprecated) ΒΆ

Deprecated

Handlebars templating via nais/deploy is deprecated. Use environment mixins and --set flags with the Nais CLI instead. See Set up a complete deploy pipeline for the recommended setup.

If you have advanced templating needs that mixins and --set don't cover, consider adding a preprocessing step to your workflow (e.g. envsubst, yq, or a script) before calling nais apply.

Legacy reference ΒΆ

The legacy nais/deploy action uses Handlebars 3.0 syntax as templating language. Both the template and variable file supports either YAML or JSON syntax.

A practical example follows. Create a nais.yaml file:

yaml

Now, create a vars.yaml file containing variables for your deployment:

yaml

Run the nais validate tool to see the final results:

bash