How do I enable run promotion in a Terraform stack configuration?

Last updated: July 14, 2025

Context

When creating stacks through the UI, the "Allow Run Promotion" setting is enabled by default. However, when configuring stacks using Terraform, users need to know which property controls this functionality.

Answer

To enable run promotion in a stack using Terraform, you need to set the github_action_deploy property to true in your stack resource configuration.

Example configuration:

resource "spacelift_stack" "example" {
  # ... other configuration ...
  github_action_deploy = true
}

Source: Spacelift Terraform Provider Documentation