[BUILD-881] Review Terraform error like "Required plugins are not installed" Created: 09/Aug/22 Updated: 24/Apr/23 |
|
| Status: | In Progress |
| Project: | Build |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Task | Priority: | Neutral |
| Reporter: | Roberto Gomez | Assignee: | Unassigned |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Template: | |
| Acceptance criteria: |
Empty
|
| Task DoR: |
Empty
|
| Team: | |
| Approved: |
Yes
|
| Description |
|
Sometimes Jenkins builds failed with the Terraform error like: 13:26:26 ╷ There's a probable solution, that suggests the error is caused by: <<The issue is that my local workstation is a Mac which uses the darwin platform, so all of the providers are downloaded for darwin and the hashes stored in the lockfile for that platform. When the CI system, which is running on Linux runs, it attempts to retrieve the providers listed in the lockfile, but the checksums don't match because they use a different platform.>>
We can check this kind of solution, but then again, also the lock files like the following must be included in VCS?
$ find . -name ".lock"
|
| Comments |
| Comment by Roberto Gomez [ 27/Mar/23 ] |
|
Trying env param TF_PLUGIN_CACHE_MAY_BREAK_DEPENDENCY_LOCK_FILE, see https://developer.hashicorp.com/terraform/cli/config/config-file#allowing-the-provider-plugin-cache-to-break-the-dependency-lock-file |
| Comment by Roberto Gomez [ 24/Apr/23 ] |
|
Adding the .terraform.lock.hcl seems to have improve the situation, as we don't get the error so frequently. But, still not there, because today's renovate PR failed again. |