-input=false
The option that stops Terraform from asking any interactive question, so an automated run fails instead of hanging forever.
In more detail
Every pipeline should pass it, or set TF_INPUT=0, to init, plan and apply. With it, a variable that has no value and no default is an error rather than a prompt.
Example
terraform init -input=falseRelated terms
- terraform init — The command that prepares a directory for Terraform: it downloads providers, fetches modules, connects the backend and writes the lock file.
- pipeline — An automated sequence of steps, such as build, test, scan and publish, that runs on every change.
- input variable — A named, typed value a configuration or module takes from outside, declared in a variable block and read as var.<name>.
Taught in
- Initialising The Working Directory — Infrastructure as Code with Terraform
- Parameterising With Input Variables — Infrastructure as Code with Terraform
- Write, Plan, Apply, And What Init Prepares — HashiCorp Terraform Associate (004) Exam Prep
- Validate, Format, Destroy, And The Flags That Bend A Plan — HashiCorp Terraform Associate (004) Exam Prep