Skip to content

Commit 6737e4f

Browse files
nbudinclaude
andcommitted
Add OpenTofu validate job to CI for all custom modules
Runs tofu init + tofu validate for each module in terraform/modules/ via a matrix strategy, catching provider API validation errors (like invalid enum values) before they reach a terraform apply. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent a1f6e2b commit 6737e4f

1 file changed

Lines changed: 21 additions & 0 deletions

File tree

.github/workflows/ci.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -368,6 +368,27 @@ jobs:
368368
with:
369369
recreate: true
370370
path: code-coverage-results.md
371+
opentofu-validate:
372+
name: OpenTofu validate (${{ matrix.module }})
373+
runs-on: ubuntu-latest
374+
strategy:
375+
matrix:
376+
module:
377+
- cloudfront_intercode
378+
- forwardemail_receiving
379+
- ses_email_receiving
380+
- intercode_aws_resources
381+
- sentry
382+
steps:
383+
- uses: actions/checkout@v6
384+
- uses: opentofu/setup-opentofu@v1
385+
- name: tofu init
386+
run: tofu init -backend=false
387+
working-directory: terraform/modules/${{ matrix.module }}
388+
- name: tofu validate
389+
run: tofu validate
390+
working-directory: terraform/modules/${{ matrix.module }}
391+
371392
update-release-draft:
372393
runs-on: ubuntu-latest
373394
name: Update release draft

0 commit comments

Comments
 (0)