mirror of
https://github.com/coder/coder.git
synced 2026-09-21 20:51:01 +08:00
fix: pin Terraform 1.15.5 for all Nix platforms (#25799)
The terraform_1_15_5 derivation previously only handled linux/amd64, falling through to unstablePkgs.terraform on all other platforms. On macOS this meant a different Terraform version was used, which caused the version check in make pre-commit to trigger generate.sh, regenerating all testdata with the host platform's OS/arch (darwin/arm64) instead of the committed linux/amd64 values. Three changes: 1. `flake.nix`: add explicit linux_arm64, darwin_arm64, and darwin_amd64 cases with SHA256 hashes from the official HashiCorp release. Unknown platforms still fall back to unstablePkgs.terraform. 2. `provisioner/terraform/testdata/generate.sh`: guard full regeneration behind a Linux-only check. The committed testdata encodes linux/amd64 values from the coder_provisioner data source, so regenerating on macOS would permanently bake in darwin/arm64. The --check path still runs on all platforms so the version target can detect provider mismatches. Regeneration via CI or an explicit Linux run is unchanged. 3. `scripts/release/check_commit_metadata.sh`: fix a shfmt (>=3.13) false positive. The [install.sh] key in an associative array literal was parsed as floating-point arithmetic (a zsh-only feature). Moving it to a post-declaration assignment satisfies the stricter parser without changing runtime behavior. <!-- If you have used AI to produce some or all of this PR, please ensure you have read our [AI Contribution guidelines](https://coder.com/docs/about/contributing/AI_CONTRIBUTING) before submitting. --> Linear: DOCS-279
This commit is contained in:
@@ -78,7 +78,6 @@ main() {
|
||||
[enterprise]="Enterprise"
|
||||
[examples]="Examples"
|
||||
[helm]="Helm"
|
||||
[install.sh]="Installer"
|
||||
[provisionersdk]="SDK"
|
||||
[provisionerd]="Provisioner"
|
||||
[provisioner]="Provisioner"
|
||||
@@ -88,6 +87,8 @@ main() {
|
||||
[support]="Support"
|
||||
[tailnet]="Networking"
|
||||
)
|
||||
# shfmt (>=3.13) parses [install.sh] as floating-point arithmetic in array literals.
|
||||
humanized_areas["install.sh"]="Installer"
|
||||
|
||||
# Get hashes for all cherry-picked commits between the selected ref
|
||||
# and main. These are sorted by commit title so that we can group
|
||||
|
||||
Reference in New Issue
Block a user