forked from circonus-labs/circonus-unified-agent
-
Notifications
You must be signed in to change notification settings - Fork 1
/
.goreleaser.yml
140 lines (133 loc) · 4.2 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
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
130
131
132
133
134
135
136
137
138
139
140
project_name: circonus-unified-agent
before:
hooks:
- go mod tidy
- golangci-lint run
#- ./build_lint.sh
builds:
-
id: cua
main: ./cmd/circonus-unified-agent
binary: sbin/circonus-unified-agentd
env:
- CGO_ENABLED=0
goos:
- linux
- windows
- freebsd
goarch:
- amd64
- arm64
ignore:
-
goarch: 386
- goos: openbsd
goarch: arm64
ldflags:
- -s
- -w
- -extldflags "-static"
- -X main.version={{.Version}}
- -X main.commit={{.ShortCommit}}
- -X main.branch={{.Branch}}
- -X main.buildDate={{.Date}}
- -X main.buildTag={{.Tag}}
dockers:
-
goos: linux
goarch: amd64
goarm: ''
ids: ['cua']
image_templates:
- "circonus/{{.ProjectName}}:{{.Tag}}-amd64"
- "circonus/{{.ProjectName}}:latest-amd64"
skip_push: false
dockerfile: docker/x86_64/Dockerfile
build_flag_templates:
- "--label=org.label-schema.schema-version=1.0"
- "--label=org.label-schema.version={{.Version}}"
- "--label=org.label-schema.name={{.ProjectName}}"
extra_files:
- etc/example-circonus-unified-agent.conf
-
goos: linux
goarch: arm64
goarm: ''
ids: ['cua']
image_templates:
- "circonus/{{.ProjectName}}:{{.Tag}}-arm64"
- "circonus/{{.ProjectName}}:latest-arm64"
skip_push: false
dockerfile: docker/arm64/Dockerfile
build_flag_templates:
- "--label=org.label-schema.schema-version=1.0"
- "--label=org.label-schema.version={{.Version}}"
- "--label=org.label-schema.name={{.ProjectName}}"
extra_files:
- etc/example-circonus-unified-agent.conf
docker_manifests:
- name_template: "circonus/{{.ProjectName}}:latest"
image_templates:
- "circonus/{{.ProjectName}}:latest-amd64"
- "circonus/{{.ProjectName}}:latest-arm64"
- name_template: "circonus/{{.ProjectName}}:{{.Tag}}"
image_templates:
- "circonus/{{.ProjectName}}:{{.Tag}}-amd64"
- "circonus/{{.ProjectName}}:{{.Tag}}-arm64"
nfpms:
- vendor: Circonus, Inc.
homepage: https://circonus.commit
maintainer: Circonus <support@circonus.com>
description: Circonus Unified Agent
license: MIT
file_name_template: "{{ .ProjectName }}_{{ .Version }}_{{ .Arch }}"
replacements:
darwin: macOS
formats:
- deb
- rpm
bindir: /opt/circonus/unified-agent
empty_folders:
- /opt/circonus/unified-agent/etc/config.d
contents:
- src: "scripts/circonus-unified-agent.service"
dst: "/opt/circonus/unified-agent/service/circonus-unified-agent.service"
- src: "scripts/init.sh"
dst: "/opt/circonus/unified-agent/service/init.sh"
- src: "etc/example-circonus-unified-agent.conf"
dst: "/opt/circonus/unified-agent/etc/circonus-unified-agent.conf"
type: "config|noreplace"
overrides:
deb:
scripts:
preinstall: "scripts/deb/pre-install.sh"
postinstall: "scripts/deb/post-install.sh"
preremove: "scripts/deb/pre-remove.sh"
postremove: "scripts/deb/post-remove.sh"
rpm:
scripts:
preinstall: "scripts/rpm/pre-install.sh"
postinstall: "scripts/rpm/post-install.sh"
postremove: "scripts/rpm/post-remove.sh"
archives:
-
id: default
name_template: "{{.ProjectName}}_{{.Version}}_{{.Os}}_{{.Arch}}"
format: tar.gz
replacements:
amd64: x86_64
files:
- LICENSE
- README.md
- CHANGELOG.md
- etc/*
- etc/**/*
- scripts/circonus-unified-agent.service
release:
github:
owner: circonus-labs
name: circonus-unified-agent
draft: false
prerelease: auto
checksum:
name_template: "{{.ProjectName}}_checksums.txt"