-
Notifications
You must be signed in to change notification settings - Fork 4
/
.goreleaser.yaml
129 lines (121 loc) · 3.52 KB
/
.goreleaser.yaml
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
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
project_name: auth0-simple-exporter
builds:
- id: "linux"
env:
- CGO_ENABLED=0
mod_timestamp: "{{ .CommitTimestamp }}"
flags:
- -trimpath
ldflags:
- '-s -w -X "github.com/tfadeyi/{{ .ProjectName }}/pkg/version.Platform=linux/unknown" -X "github.com/tfadeyi/{{ .ProjectName }}/pkg/version.Version={{ .Version }}" -X "github.com/tfadeyi/{{ .ProjectName }}/pkg/version.Commit={{ .Commit }}" -X "github.com/tfadeyi/{{ .ProjectName }}/pkg/version.Date={{ .Date }}"'
binary: "{{ .ProjectName }}"
goos:
- linux
goarch:
- amd64
- arm64
- arm
- id: "darwin"
env:
- CGO_ENABLED=0
mod_timestamp: "{{ .CommitTimestamp }}"
flags:
- -trimpath
ldflags:
- '-s -w -X "github.com/tfadeyi/{{ .ProjectName }}/pkg/version.Platform=darwin/unknown" -X "github.com/tfadeyi/{{ .ProjectName }}/pkg/version.Version={{ .Version }}" -X "github.com/tfadeyi/{{ .ProjectName }}/pkg/version.Commit={{ .Commit }}" -X "github.com/tfadeyi/{{ .ProjectName }}/pkg/version.Date={{ .Date }}"'
binary: "{{ .ProjectName }}"
goos:
- darwin
goarch:
- amd64
- arm64
archives:
- id: linux
format: tar.gz
name_template: "{{ .ProjectName }}-{{ .Os }}-{{ .Arch }}"
wrap_in_directory: true
builds:
- "linux"
- id: darwin
format: tar.gz
name_template: "{{ .ProjectName }}-{{ .Os }}-{{ .Arch }}"
wrap_in_directory: true
builds:
- "darwin"
kos:
- working_dir: .
id: "linux"
build: "linux"
base_image: gcr.io/distroless/base:nonroot
# labels are going to be supported in goreleaser 1.16.3, waiting for the release
labels:
org.opencontainers.image.source: https://github.com/tfadeyi/auth0-simple-exporter
org.opencontainers.image.description: "Simple Prometheus exporter for Auth0 log events"
org.opencontainers.image.licenses: APACHE
org.opencontainers.image.title: "Auth0 Exporter"
org.opencontainers.image.vendor: ""
org.opencontainers.image.authors: "Oluwole Fadeyi"
platforms:
- linux/amd64
- linux/arm64
- linux/arm
tags:
- '{{.Tag}}'
- '{{if not .Prerelease}}latest{{end}}'
sbom: cyclonedx
bare: true
base_import_paths: true
checksum:
name_template: "{{ .ProjectName }}-SHA256SUMS"
algorithm: sha256
release:
draft: true
prerelease: auto
changelog:
sort: asc
use: github
filters:
exclude:
- "^test:"
- "^chore"
- "merge conflict"
- Merge pull request
- Merge remote-tracking branch
- Merge branch
groups:
- title: Dependency updates
regexp: '^.*?(feat|fix)\(deps\)!?:.+$'
order: 300
- title: "New Features"
regexp: '^.*?feat(\([[:word:]]+\))??!?:.+$'
order: 100
- title: "Security updates"
regexp: '^.*?sec(\([[:word:]]+\))??!?:.+$'
order: 150
- title: "Bug fixes"
regexp: '^.*?fix(\([[:word:]]+\))??!?:.+$'
order: 200
- title: "Documentation updates"
regexp: ^.*?doc(\([[:word:]]+\))??!?:.+$
order: 400
- title: "Build process updates"
regexp: ^.*?build(\([[:word:]]+\))??!?:.+$
order: 400
- title: Other work
order: 9999
signs:
- cmd: cosign
args:
- "sign-blob"
- "${artifact}"
- "--output-signature=${signature}"
- "--yes" # needed on cosign 2.0.0+
artifacts: all
# the image signing doesn't seem to work when using ku to build the image
docker_signs:
- cmd: cosign
args:
- "sign"
- "${artifact}"
- "--yes"
artifacts: all