-
Notifications
You must be signed in to change notification settings - Fork 3
/
.goreleaser.dev.yaml
69 lines (67 loc) · 2.27 KB
/
.goreleaser.dev.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
# yaml-language-server: $schema=https://goreleaser.com/static/schema-pro.json
project_name: tracetest
changelog:
sort: asc
filters:
exclude:
- '^docs:'
- '^test:'
release:
disable: true
before:
hooks:
- dir: ./server
cmd: go mod tidy
- dir: ./cli
cmd: go mod tidy
env:
- VERSION={{ if index .Env "VERSION" }}{{ .Env.VERSION }}{{ else }}dev{{ end }}
# if TAG is defined, use it. Fallback to VERSION
- TAG={{ if index .Env "TAG" }}{{ .Env.TAG }}{{ else }}{{ if index .Env "VERSION" }}{{ .Env.VERSION }}{{ else }}dev{{ end }}{{ end }}
- TRACETEST_ENV={{ if index .Env "TRACETEST_ENV" }}{{ .Env.TRACETEST_ENV }}{{ else }}dev{{ end }}
- ANALYTICS_BE_KEY={{ if index .Env "ANALYTICS_BE_KEY" }}{{ .Env.ANALYTICS_BE_KEY }}{{ else }}{{ end }}
- ANALYTICS_FE_KEY={{ if index .Env "ANALYTICS_FE_KEY" }}{{ .Env.ANALYTICS_FE_KEY }}{{ else }}{{ end }}
builds:
- id: server
binary: tracetest-server
main: ./server/main.go
ldflags:
- -X github.com/kubeshop/tracetest/server/app.Version={{ .Env.VERSION }}
- -X github.com/kubeshop/tracetest/server/app.Env={{ .Env.TRACETEST_ENV }}
- -X github.com/kubeshop/tracetest/server/analytics.SecretKey={{ .Env.ANALYTICS_BE_KEY }}
- -X github.com/kubeshop/tracetest/server/analytics.FrontendKey={{ .Env.ANALYTICS_FE_KEY }}
env:
- CGO_ENABLED=0
goos:
- linux
goarch:
- amd64
- id: cli
binary: tracetest
main: ./cli/main.go
ldflags:
- -X github.com/kubeshop/tracetest/cli/config.Version={{ .Env.VERSION }}
- -X github.com/kubeshop/tracetest/cli/config.Env={{ .Env.TRACETEST_ENV }}
- -X github.com/kubeshop/tracetest/cli/analytics.SecretKey={{ .Env.ANALYTICS_BE_KEY }}
env:
- CGO_ENABLED=0
goos:
- linux
goarch:
- amd64
dockers:
- skip_push: true
image_templates:
- 'kubeshop/tracetest:{{ .Env.TAG }}'
extra_files:
- web/build
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}}"
- "--platform=linux/amd64"
goos: linux
goarch: amd64