atmos terraform generate backend
Use this command to generate a Terraform backend config file for an Atmos terraform component in a stack.
Usage​
Execute the terraform generate backend
command like this:
atmos terraform generate backend <component> -s <stack>
This command generates a backend config file for an Atmos terraform component in a stack.
Run atmos terraform generate backend --help
to see all the available options
Examples​
atmos terraform generate backend top-level-component1 -s tenant1-ue2-dev
atmos terraform generate backend infra/vpc -s tenant1-ue2-staging
atmos terraform generate backend test/test-component -s tenant1-ue2-dev
atmos terraform generate backend test/test-component-override-2 -s tenant2-ue2-prod
Arguments​
component
(required)Atmos terraform component.
Flags​
--stack
(alias-s
) (required)Atmos stack.
--dry-run
(optional)Dry run.
atmos terraform generate backend <component> -s <stack> --dry-run=true
--process-templates
(optional)Enable/disable Go template processing in Atmos stack manifests when executing terraform commands.
If the flag is not passed, template processing is enabled by default.
atmos terraform generate backend <component> -s <stack> --process-templates=false
--process-functions
(optional)Enable/disable YAML functions processing in Atmos stack manifests
when executing terraform commands.If the flag is not passed, YAML function processing is enabled by default.
atmos terraform generate backend <component> -s <stack> --process-functions=false
--skip
(optional)Skip processing a specific Atmos YAML function in Atmos stacks manifests when executing terraform commands.
To specify more than one function, use multiple
--skip
flags, or separate the functions with a comma.atmos terraform generate backend <component> -s <stack> --skip=eval --skip=include
atmos terraform generate backend <component> -s <stack> --skip=terraform.output,include
Refer to Terraform backend configuration for more details
on terraform
backends and supported formats