-
Notifications
You must be signed in to change notification settings - Fork 142
/
Copy path.goreleaser.yml
202 lines (202 loc) · 6.17 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
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
project_name: 'geoipupdate'
version: 2
archives:
- id: 'archives-unix'
builds:
- 'geoipupdate-unix'
wrap_in_directory: true
files:
- 'CHANGELOG.md'
- 'LICENSE-APACHE'
- 'LICENSE-MIT'
- 'README.md'
- src: 'build/unix/*'
dst: '.'
strip_parent: true
- id: 'archives-windows'
builds:
- 'geoipupdate-windows'
wrap_in_directory: true
files:
- 'CHANGELOG.md'
- 'LICENSE-APACHE'
- 'LICENSE-MIT'
- 'README.md'
- src: 'build/windows/*'
dst: '.'
strip_parent: true
format: 'zip'
builds:
- id: 'geoipupdate-unix'
main: './cmd/geoipupdate'
binary: 'geoipupdate'
goarch:
- '386'
- 'amd64'
- 'arm'
- 'arm64'
goos:
- 'darwin'
- 'linux'
- 'freebsd'
- 'openbsd'
ignore:
- goos: freebsd
goarch: arm
- goos: openbsd
goarch: arm
- goos: freebsd
goarch: arm64
- goos: openbsd
goarch: arm64
hooks:
post: 'make data BUILDDIR="build/unix"'
env:
- CGO_ENABLED=0
# This is a separate build as we want to specify different paths in the
# ldflags.
- id: 'geoipupdate-packages'
main: './cmd/geoipupdate'
binary: 'geoipupdate'
goarch:
- '386'
- 'amd64'
- 'arm'
- 'arm64'
goos:
- 'linux'
hooks:
post: 'make data BUILDDIR="build/packages" CONFFILE=/etc/GeoIP.conf DATADIR=/usr/share/GeoIP'
ldflags:
- '-s -w -X main.version={{.Version}} -X main.defaultConfigFile=/etc/GeoIP.conf -X main.defaultDatabaseDirectory=/usr/share/GeoIP'
env:
- CGO_ENABLED=0
- id: 'geoipupdate-windows'
main: './cmd/geoipupdate'
binary: 'geoipupdate'
goarch:
- '386'
- 'amd64'
goos:
- 'windows'
hooks:
post: 'make data OS=Windows_NT BUILDDIR="build/windows"'
env:
- CGO_ENABLED=0
dockers:
- ids:
- 'geoipupdate-unix'
image_templates:
- "maxmindinc/geoipupdate:{{ .Tag }}-amd64"
- "ghcr.io/maxmind/geoipupdate:{{ .Tag }}-amd64"
dockerfile: docker/Dockerfile
use: buildx
goarch: amd64
extra_files:
- docker/entry.sh
- docker/healthcheck.sh
build_flag_templates:
- "--platform=linux/amd64"
- image_templates:
- "maxmindinc/geoipupdate:{{ .Tag }}-arm64"
- "ghcr.io/maxmind/geoipupdate:{{ .Tag }}-arm64"
dockerfile: docker/Dockerfile
use: buildx
goarch: arm64
extra_files:
- docker/entry.sh
- docker/healthcheck.sh
build_flag_templates:
- "--platform=linux/arm64"
- image_templates:
- "maxmindinc/geoipupdate:{{ .Tag }}-arm-v6"
- "ghcr.io/maxmind/geoipupdate:{{ .Tag }}-arm-v6"
dockerfile: docker/Dockerfile
use: buildx
goarch: arm
goarm: 6
extra_files:
- docker/entry.sh
- docker/healthcheck.sh
build_flag_templates:
- "--platform=linux/arm/v6"
docker_manifests:
- name_template: "maxmindinc/geoipupdate:{{ .Tag }}"
image_templates:
- "maxmindinc/geoipupdate:{{ .Tag }}-amd64"
- "maxmindinc/geoipupdate:{{ .Tag }}-arm64"
- "maxmindinc/geoipupdate:{{ .Tag }}-arm-v6"
- name_template: "maxmindinc/geoipupdate:v{{ .Major }}"
image_templates:
- "maxmindinc/geoipupdate:{{ .Tag }}-amd64"
- "maxmindinc/geoipupdate:{{ .Tag }}-arm64"
- "maxmindinc/geoipupdate:{{ .Tag }}-arm-v6"
- name_template: "maxmindinc/geoipupdate:v{{ .Major }}.{{ .Minor }}"
image_templates:
- "maxmindinc/geoipupdate:{{ .Tag }}-amd64"
- "maxmindinc/geoipupdate:{{ .Tag }}-arm64"
- "maxmindinc/geoipupdate:{{ .Tag }}-arm-v6"
- name_template: "maxmindinc/geoipupdate:latest"
image_templates:
- "maxmindinc/geoipupdate:{{ .Tag }}-amd64"
- "maxmindinc/geoipupdate:{{ .Tag }}-arm64"
- "maxmindinc/geoipupdate:{{ .Tag }}-arm-v6"
- name_template: "ghcr.io/maxmind/geoipupdate:{{ .Tag }}"
image_templates:
- "ghcr.io/maxmind/geoipupdate:{{ .Tag }}-amd64"
- "ghcr.io/maxmind/geoipupdate:{{ .Tag }}-arm64"
- "ghcr.io/maxmind/geoipupdate:{{ .Tag }}-arm-v6"
- name_template: "ghcr.io/maxmind/geoipupdate:v{{ .Major }}"
image_templates:
- "ghcr.io/maxmind/geoipupdate:{{ .Tag }}-amd64"
- "ghcr.io/maxmind/geoipupdate:{{ .Tag }}-arm64"
- "ghcr.io/maxmind/geoipupdate:{{ .Tag }}-arm-v6"
- name_template: "ghcr.io/maxmind/geoipupdate:v{{ .Major }}.{{ .Minor }}"
image_templates:
- "ghcr.io/maxmind/geoipupdate:{{ .Tag }}-amd64"
- "ghcr.io/maxmind/geoipupdate:{{ .Tag }}-arm64"
- "ghcr.io/maxmind/geoipupdate:{{ .Tag }}-arm-v6"
- name_template: "ghcr.io/maxmind/geoipupdate:latest"
image_templates:
- "ghcr.io/maxmind/geoipupdate:{{ .Tag }}-amd64"
- "ghcr.io/maxmind/geoipupdate:{{ .Tag }}-arm64"
- "ghcr.io/maxmind/geoipupdate:{{ .Tag }}-arm-v6"
nfpms:
- builds:
- 'geoipupdate-packages'
vendor: 'MaxMind, Inc.'
homepage: https://www.maxmind.com/
maintainer: 'MaxMind, Inc. <support@maxmind.com>'
description: Program to perform automatic updates of GeoIP2 and GeoLite2 binary databases.
license: Apache 2.0 or MIT
formats:
- deb
- rpm
bindir: /usr/bin
contents:
- dst: /usr/share/GeoIP
type: 'dir'
- src: 'CHANGELOG.md'
dst: '/usr/share/doc/geoipupdate/CHANGELOG.md'
- src: 'LICENSE-APACHE'
dst: '/usr/share/doc/geoipupdate/LICENSE-APACHE'
- src: 'LICENSE-MIT'
dst: '/usr/share/doc/geoipupdate/LICENSE-MIT'
- src: 'README.md'
dst: '/usr/share/doc/geoipupdate/README.md'
- src: 'build/packages/GeoIP.conf'
dst: '/usr/share/doc/geoipupdate/GeoIP.conf'
- src: 'build/packages/GeoIP.conf.md'
dst: '/usr/share/doc/geoipupdate/GeoIP.conf.md'
- src: 'build/packages/geoipupdate.md'
dst: '/usr/share/doc/geoipupdate/geoipupdate.md'
- src: 'build/packages/GeoIP.conf.5'
dst: '/usr/share/man/man5/GeoIP.conf.5'
- src: 'build/packages/geoipupdate.1'
dst: '/usr/share/man/man1/geoipupdate.1'
- src: 'build/packages/GeoIP.conf'
dst: '/etc/GeoIP.conf'
type: config
release:
name_template: "{{.Version}}"
target_commitish: "{{ .FullCommit }}"