forked from dailymotion-oss/osiris
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.goreleaser.yml
45 lines (40 loc) · 1.51 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
# Configuration file for http://goreleaser.com
builds:
- goos:
- linux
- darwin
goarch:
- amd64
ldflags:
- -X github.com/dailymotion-oss/osiris/pkg/version.version={{.Version}}
- -X github.com/dailymotion-oss/osiris/pkg/version.commit={{.Commit}}
- -X github.com/dailymotion-oss/osiris/pkg/version.date={{.Date}}
env:
- CGO_ENABLED=0
archives:
- format: binary
dockers:
- dockerfile: Dockerfile.goreleaser
extra_files:
- bin/
image_templates:
- "ghcr.io/dailymotion-oss/{{.ProjectName}}:{{ .Version }}"
- "ghcr.io/dailymotion-oss/{{.ProjectName}}:{{ .Tag }}"
- "ghcr.io/dailymotion-oss/{{.ProjectName}}:v{{ .Major }}"
- "ghcr.io/dailymotion-oss/{{.ProjectName}}:v{{ .Major }}.{{ .Minor }}"
- "ghcr.io/dailymotion-oss/{{.ProjectName}}:latest"
build_flag_templates:
- "--pull"
- "--label=org.opencontainers.image.created={{.Date}}"
- "--label=org.opencontainers.image.name={{.ProjectName}}"
- "--label=org.opencontainers.image.revision={{.FullCommit}}"
- "--label=org.opencontainers.image.version={{.Version}}"
- "--label=org.opencontainers.image.source={{.GitURL}}"
before:
hooks:
# package Helm chart
- rm -rf .cr-release-packages
- mkdir -p .cr-release-packages
- helm package --app-version={{if .IsSnapshot}}latest{{else}}{{.Version}}{{end}} --version={{if .IsSnapshot}}0.0.0{{else}}{{.Version}}{{end}} --destination .cr-release-packages charts/osiris
changelog:
sort: asc