Parameterization keeps changeable configuration outside application or infrastructure code. Parameters and placeholders are filled with values when a command or deployment pipeline runs, avoiding repeated edits to hardcoded files. section 8.9.2 section 7.11.3
Use parameterization when values vary between deployments or change frequently:
- Pass environment-specific names, such as separate production and testing infrastructure, through Terraform variables. section 7.11.3
- Keep container registry locations and microservice version numbers out of deployment configuration. section 8.9.2
- Inject environment-variable values into Kubernetes configuration during continuous deployment with envsubst. section 8.9.2
Parameterized deployment configuration
Set CONTAINER_REGISTRY and VERSION in the pipeline environment, then run envsubst against deploy.yaml. The same configuration can receive different registry locations or versions without changing the repository’s deployment file. section 8.9.2
var.app_name
Enter a value: flixtube
var.kubernetes_version
Enter a value: 1.24.6
Terraform prompts for parameter values that have no defaults, including an application name and Kubernetes version. section 7.11.3

