Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

add option to customize flags to terraform init for terraform validate

Open
#73 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
38/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
shell, terraform
Domain
devops, tooling

Research direction

Start by locating the pre-commit hook for terraform validate and the terraform init invocation it uses. Reproduce the automated validation scenario with a Terraform lock file, then define how custom init flags should be supplied. Done means users can customize those flags and terraform validate no longer causes unintended lockfile changes.

Written by the indexing model from the issue text.

Description

enhancement

Describe the solution you'd like
The terraform lock file is causing issues with terraform validate being run in an automated job. Terraform init is updating the hashes in the lockfile and thus failing the job because it detects changes were made to files.

For now this can be fixed by not checking in the lock file but this is outside of what hashicorp is recommending.

Dominant language
Shell
Stars
546
Forks
167
PR merge metrics
No merged PRs in 30d

Getting set up

  • No Dockerfile or Docker Compose file
  • Has a pull request template
  • No contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from gruntwork-io/pre-commit

All issues in gruntwork-io/pre-commit

Similar issues

More Shell/Bash issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.