-
-
Notifications
You must be signed in to change notification settings - Fork 577
Open
Labels
bug_with_workaroundSomething isn't working but there is a workaroundSomething isn't working but there is a workarounddocumentationImprovements or additions to documentationImprovements or additions to documentationestimate/1dayNeed 1 work day to be doneNeed 1 work day to be donehook/terraform_providers_lockBash hookBash hookhook/terraform_validateBash hookBash hook
Description
What problem are you facing?
#620 introduces parallelism, this can lead to data races when the plugin cache is enabled, with terraform init writing in parallel to the cache, and creating corrupted providers (especially visible with the lock file where random provider hashes get appended).
This can be worked around by setting the --hook-config=--parallelism-limit=1 arg on terraform_validate hook.
How could pre-commit-terraform help solve your problem?
It would be nice if the hooks using terraform init (mostly terraform_validate, but terragrunt_providers_lock has it deprecated too) could disable parallelism automatically when the TF_PLUGIN_CACHE_DIR environment variable is set.
Not sure if handling the case where plugin_cache_dir is set in the config file would be possible.
ento, lc-nyovchev and carlosjgp
Metadata
Metadata
Assignees
Labels
bug_with_workaroundSomething isn't working but there is a workaroundSomething isn't working but there is a workarounddocumentationImprovements or additions to documentationImprovements or additions to documentationestimate/1dayNeed 1 work day to be doneNeed 1 work day to be donehook/terraform_providers_lockBash hookBash hookhook/terraform_validateBash hookBash hook