This action updates a Terraform Cloud variable https://www.terraform.io/docs/cloud/api/variables.html
It borrows heavily from the work done by https://github.com/sarathkrish/invoke-terraform-run-api so shout out to them.
Required The name of the workspace.
Required Your Organization.
Required Your Terraform token. Please use secret to store your Terraform token.
Required This is the Terraform Host Name. For Terraform cloud its app.terraform.io.
Required The variable name to be updated.
Required The value to update the variable with.
The variable ID.
uses: patrontech/[email protected]
with:
workSpaceName: MyTestWorkspace
organizationName: {{env.organization}}
terraformToken: {{secrets.Terraform_Token}}
terraformHost: 'app.terraform.io'
variableName: 'container_tag'
variableValue: 'v1.1.1'