If you need more control over how
terraform is executed, you can define a Runtime Extensions yourself instead. Inside your runtime config, mark the extension type as
runtime: name: my-terraform-runner extension: type: TERRAFORM ... # the rest of extension config goes here
Make sure that:
fetchcommand is defined and ends with
terraform plan -detailed-exitcode.
terraformto exit 0 when there are no changes, 1 on errors, and 2 if there are changes - exactly what the Runtime Extension interface expects.
applycommand ends with
terraform initis run before both
- Pass a
60s) to both
terraform apply, as we run
plancontinuously in a loop and so cause the two commands to conflict.
As this is now your own Runtime Extension, you can define whatever parameters you would like to expose to your services.
Updated 3 months ago