'plan.cache: no matching files, unable to attach terraform report to the MR
I have following plan stage in my gitlab CI, which I took from here but unlike gitlab-terraform, terraform v1.1.0 doesnt have any option of plan-json, so I am trying to reproduce the same with the following. Aim is attached the plan changes as report in gitlab merge requests.
plan:
stage: plan
script:
- terraform plan -out=plan.json
- terraform show -json plan.json
artifacts:
name: plan
paths:
- ${TF_ROOT}/plan.cache
reports:
terraform: ${TF_ROOT}/plan.json
However, in MR all I see is 1 Terraform report failed to generate and in the complete job log I see following:
plan.cache: no matching files
12ERROR: No files to upload
Question is what is the difference between artifacts:path and the path given under artifacts:reports:terraform. and,
Where can I find/generate plan.cache?
$ terraform -v
Terraform v1.1.0
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
