2022-04-26 21:50:00 +00:00
|
|
|
# This is an example .goreleaser.yml file with some sensible defaults.
|
|
|
|
# Make sure to check the documentation at https://goreleaser.com
|
|
|
|
before:
|
|
|
|
hooks:
|
|
|
|
- make clean
|
2022-07-27 04:33:36 +00:00
|
|
|
- make stage-static
|
2022-04-26 21:50:00 +00:00
|
|
|
- go generate ./...
|
|
|
|
builds:
|
|
|
|
- main: ./cmd/relay
|
|
|
|
binary: relay
|
|
|
|
ldflags:
|
|
|
|
- -s
|
|
|
|
- -w
|
|
|
|
- -extldflags
|
|
|
|
- -static
|
|
|
|
- -X main.Commit={{.Commit}}
|
|
|
|
- -X main.Version={{.Version}}
|
|
|
|
env:
|
|
|
|
- CGO_ENABLED=0
|
|
|
|
goarch:
|
|
|
|
- amd64
|
|
|
|
- arm64
|
|
|
|
goos:
|
|
|
|
- linux
|
|
|
|
- darwin
|
|
|
|
mod_timestamp: "{{ .CommitTimestamp }}"
|
|
|
|
universal_binaries:
|
|
|
|
- replace: true
|
|
|
|
archives:
|
|
|
|
- replacements:
|
|
|
|
darwin: Darwin
|
|
|
|
linux: Linux
|
|
|
|
windows: Windows
|
|
|
|
386: i386
|
|
|
|
amd64: x86_64
|
|
|
|
dockers:
|
|
|
|
- use: buildx
|
|
|
|
goos: linux
|
|
|
|
goarch: amd64
|
|
|
|
image_templates:
|
2022-07-27 04:56:55 +00:00
|
|
|
- "feditools/{{ .ProjectName }}:{{ .Version }}-amd64"
|
|
|
|
- "feditools/{{ .ProjectName }}:latest-amd64"
|
2022-04-26 21:50:00 +00:00
|
|
|
build_flag_templates:
|
|
|
|
- "--platform=linux/amd64"
|
|
|
|
- "--label=org.opencontainers.image.created={{.Date}}"
|
|
|
|
- "--label=org.opencontainers.image.title={{.ProjectName}}"
|
|
|
|
- "--label=org.opencontainers.image.revision={{.FullCommit}}"
|
|
|
|
- "--label=org.opencontainers.image.version={{.Version}}"
|
|
|
|
- use: buildx
|
|
|
|
goos: linux
|
|
|
|
goarch: arm64
|
|
|
|
image_templates:
|
2022-07-27 04:56:55 +00:00
|
|
|
- "feditools/{{ .ProjectName }}:{{ .Version }}-arm64v8"
|
|
|
|
- "feditools/{{ .ProjectName }}:latest-arm64v8"
|
2022-04-26 21:50:00 +00:00
|
|
|
build_flag_templates:
|
|
|
|
- "--platform=linux/arm64/v8"
|
|
|
|
- "--label=org.opencontainers.image.created={{.Date}}"
|
|
|
|
- "--label=org.opencontainers.image.title={{.ProjectName}}"
|
|
|
|
- "--label=org.opencontainers.image.revision={{.FullCommit}}"
|
|
|
|
- "--label=org.opencontainers.image.version={{.Version}}"
|
|
|
|
docker_manifests:
|
2022-07-27 04:33:36 +00:00
|
|
|
- name_template: feditools/{{ .ProjectName }}:{{ .Version }}
|
2022-04-26 21:50:00 +00:00
|
|
|
image_templates:
|
2022-07-27 04:33:36 +00:00
|
|
|
- feditools/{{ .ProjectName }}:{{ .Version }}-amd64
|
|
|
|
- feditools/{{ .ProjectName }}:{{ .Version }}-arm64v8
|
2022-07-27 04:56:55 +00:00
|
|
|
- name_template: feditools/{{ .ProjectName }}:latest
|
2022-04-26 21:50:00 +00:00
|
|
|
image_templates:
|
2022-07-27 04:33:36 +00:00
|
|
|
- feditools/{{ .ProjectName }}:latest-amd64
|
|
|
|
- feditools/{{ .ProjectName }}:latest-arm64v8
|
2022-04-26 21:50:00 +00:00
|
|
|
checksum:
|
|
|
|
name_template: 'checksums.txt'
|
|
|
|
snapshot:
|
|
|
|
name_template: "{{ incpatch .Version }}-dev"
|
|
|
|
changelog:
|
|
|
|
sort: asc
|
|
|
|
filters:
|
|
|
|
exclude:
|
|
|
|
- '^docs:'
|
|
|
|
- '^deployments:'
|