learn-terraform-github-actions icon indicating copy to clipboard operation
learn-terraform-github-actions copied to clipboard

Use approved plan file for apply

Open sblack4 opened this issue 4 years ago • 0 comments

I think ideally, you run the plan you approved instead of applying with -auto-approve. I'm wondering if others feel the same way

I hacked at it a while ago and was able to do it by using artifacts.

  • PR with workflow https://github.com/sblack4/learning-terraform-github-actions/pull/8
  • upload the plan file https://github.com/sblack4/learning-terraform-github-actions/blob/main/.github/workflows/terraform.yaml#L73
  • download the plan file https://github.com/sblack4/learning-terraform-github-actions/blob/main/.github/workflows/terraform.yaml#L111

sblack4 avatar Aug 24 '21 20:08 sblack4