forked from kyverno/kyverno
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.goreleaser.yml
80 lines (71 loc) · 1.54 KB
/
.goreleaser.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
version: 2
project_name: kyverno-cli
before:
hooks:
- go mod download
builds:
- id: kyverno-cli
# As mentioned in https://github.com/golang/go/issues/51831, to include build info, we should use go build <package>
# instead of go build main.go here.
# see https://goreleaser.com/customization/builds/
main: ./cmd/cli/kubectl-kyverno
binary: kyverno
env:
- CGO_ENABLED=0
ldflags:
- -s -w -X github.com/kyverno/kyverno/pkg/version.BuildVersion={{.Version}}
goos:
- linux
- darwin
- windows
goarch:
- amd64
- arm64
- s390x
ignore:
- goos: darwin
goarch: s390x
- goos: windows
goarch: s390x
signs:
- cmd: cosign
env:
- COSIGN_EXPERIMENTAL=1
certificate: '${artifact}.pem'
args:
- sign-blob
- --output-certificate=${certificate}
- --output-signature=${signature}
- ${artifact}
- --yes
artifacts: all
output: true
archives:
- id: kyverno-cli-archive
name_template: |-
kyverno-cli_{{ .Tag }}_{{ .Os }}_
{{- with .Arch -}}
{{- if eq . "amd64" -}}x86_64{{- else if eq . "386" -}}i386{{- else -}}{{- . -}}{{- end -}}
{{- end -}}
{{- with .Arm -}}
{{- if eq . "6" -}}hf{{- else -}}v{{- . -}}{{- end -}}
{{- end -}}
builds:
- kyverno-cli
format_overrides:
- goos: windows
format: zip
files: ["LICENSE"]
checksum:
name_template: checksums.txt
source:
enabled: true
release:
prerelease: auto
changelog:
sort: asc
filters:
exclude:
- '^docs:'
- typo
- '^test:'