|
| 1 | +archives: |
| 2 | + - files: |
| 3 | + # Ensure only built binary is archived |
| 4 | + - 'none*' |
| 5 | + format: zip |
| 6 | + name_template: '{{ .ProjectName }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}' |
| 7 | +before: |
| 8 | + hooks: |
| 9 | + - 'go mod download' |
| 10 | +builds: |
| 11 | + - # Binary naming only required for Terraform CLI 0.12 |
| 12 | + binary: '{{ .ProjectName }}_v{{ .Version }}_x5' |
| 13 | + env: |
| 14 | + - CGO_ENABLED=0 |
| 15 | + flags: |
| 16 | + - -trimpath |
| 17 | + goos: |
| 18 | + - darwin |
| 19 | + - freebsd |
| 20 | + - linux |
| 21 | + - windows |
| 22 | + goarch: |
| 23 | + - '386' |
| 24 | + - amd64 |
| 25 | + - arm |
| 26 | + - arm64 |
| 27 | + ignore: |
| 28 | + - goarch: arm |
| 29 | + goos: windows |
| 30 | + - goarch: arm64 |
| 31 | + goos: freebsd |
| 32 | + - goarch: arm64 |
| 33 | + goos: windows |
| 34 | + ldflags: |
| 35 | + - -s -w -X main.Version={{.Version}} |
| 36 | + mod_timestamp: '{{ .CommitTimestamp }}' |
| 37 | +checksum: |
| 38 | + algorithm: sha256 |
| 39 | + extra_files: |
| 40 | + - glob: 'terraform-registry-manifest.json' |
| 41 | + name_template: '{{ .ProjectName }}_{{ .Version }}_manifest.json' |
| 42 | + name_template: '{{ .ProjectName }}_{{ .Version }}_SHA256SUMS' |
| 43 | +publishers: |
| 44 | + - checksum: true |
| 45 | + # Terraform CLI 0.10 - 0.11 perform discovery via HTTP headers on releases.hashicorp.com |
| 46 | + # For providers which have existed since those CLI versions, exclude |
| 47 | + # discovery by setting the protocol version headers to 5. |
| 48 | + cmd: hc-releases upload-file {{ abs .ArtifactPath }} -header=x-terraform-protocol-version=5 -header=x-terraform-protocol-versions=5.0 |
| 49 | + env: |
| 50 | + - AWS_ACCESS_KEY_ID={{ .Env.AWS_ACCESS_KEY_ID }} |
| 51 | + - AWS_SECRET_ACCESS_KEY={{ .Env.AWS_SECRET_ACCESS_KEY }} |
| 52 | + - AWS_SESSION_TOKEN={{ .Env.AWS_SESSION_TOKEN }} |
| 53 | + extra_files: |
| 54 | + - glob: 'terraform-registry-manifest.json' |
| 55 | + name_template: '{{ .ProjectName }}_{{ .Version }}_manifest.json' |
| 56 | + name: hc-releases |
| 57 | + signature: true |
| 58 | +release: |
| 59 | + extra_files: |
| 60 | + - glob: 'terraform-registry-manifest.json' |
| 61 | + name_template: '{{ .ProjectName }}_{{ .Version }}_manifest.json' |
| 62 | + ids: |
| 63 | + - none |
| 64 | +signs: |
| 65 | + - args: ["sign", "--dearmor", "--file", "${artifact}", "--out", "${signature}"] |
| 66 | + artifacts: checksum |
| 67 | + cmd: signore |
| 68 | + signature: ${artifact}.sig |
| 69 | + - args: ["sign", "--dearmor", "--file", "${artifact}", "--out", "${signature}"] |
| 70 | + artifacts: checksum |
| 71 | + cmd: signore |
| 72 | + id: key-id |
| 73 | + signature: ${artifact}.72D7468F.sig |
| 74 | +snapshot: |
| 75 | + name_template: "{{ .Tag }}-next" |
0 commit comments