generated from steadybit/extension-scaffold
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.goreleaser.yaml
115 lines (106 loc) · 3.13 KB
/
.goreleaser.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
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
project_name: steadybit-extension-host
version: 2
before:
hooks:
- go mod download
- make licenses-report
release:
prerelease: "false"
git:
ignore_tags:
- steadybit-extension-host-*
builds:
- binary: extension-host
env:
- CGO_ENABLED=0
- MEMFILL_VERSION=v1.1.1
- NSMOUNT_VERSION=v1.0.0
goos:
- linux
goarch:
- amd64
- arm64
flags:
- -cover={{ if index .Env "BUILD_WITH_COVERAGE" }}{{ .Env.BUILD_WITH_COVERAGE }}{{ else }}false{{ end }}
- -covermode=atomic
ldflags:
- -s -w
- -X github.com/steadybit/extension-kit/extbuild.ExtensionName={{.ProjectName}}
- -X github.com/steadybit/extension-kit/extbuild.Version={{.Version}}
- -X github.com/steadybit/extension-kit/extbuild.Revision={{.Commit}}
hooks:
post: sh -c "curl -sfL \"https://github.com/steadybit/nsmount/releases/download/${NSMOUNT_VERSION}/nsmount.{{ .Arch }}\" -o \"./dist/nsmount.{{ .Arch }}\" && chmod a+x \"./dist/nsmount.{{ .Arch }}\" && curl -sfL \"https://github.com/steadybit/memfill/releases/download/${MEMFILL_VERSION}/memfill.{{ .Arch }}\" -o \"./dist/memfill.{{ .Arch }}\" && chmod a+x \"./dist/memfill.{{ .Arch }}\""
archives:
- name_template: "{{ .ProjectName }}_{{ .Os }}_{{ .Arch }}"
checksum:
name_template: 'checksums.txt'
snapshot:
version_template: "{{ incpatch .Version }}-{{ .Timestamp }}-next"
changelog:
sort: asc
filters:
exclude:
- '^docs:'
- '^test:'
nfpms:
- package_name: "steadybit-extension-host"
file_name_template: "{{ .ConventionalFileName }}"
formats:
- deb
- rpm
maintainer: "Johannes Edmeier <johannes.edmeier@steadybit.com>"
description: |
Steadybit Extension Host
vendor: "steadybit GmbH"
homepage: "https://steadybit.com"
license: "Steadybit license"
builds:
- steadybit-extension-host
dependencies:
- procps
- stress-ng
- iptables
- iproute2
- bind9-dnsutils
- runc
- libcap2-bin
- cgroup-tools
bindir: /opt/steadybit/extension-host
contents:
- src: ./linuxpkg/systemd
dst: /usr/lib/systemd/system
- src: ./linuxpkg/init.d
dst: /etc/init.d
- src: ./linuxpkg/config
dst: /etc
type: config
- src: ./dist/nsmount.{{ .Arch }}
dst: /opt/steadybit/extension-host/nsmount
- src: ./dist/memfill.{{ .Arch }}
dst: /opt/steadybit/extension-host/memfill
- src: ./licenses
dst: /opt/steadybit/extension-host/licenses
scripts:
preinstall: ./linuxpkg/scripts/preinstall.sh
postinstall: ./linuxpkg/scripts/postinstall.sh
preremove: ./linuxpkg/scripts/preremove.sh
postremove: ./linuxpkg/scripts/postremove.sh
rpm:
signature:
key_file: ./gpg.key
deb:
signature:
key_file: ./gpg.key
overrides:
rpm:
dependencies:
- /usr/bin/ps
- /usr/bin/stress-ng
- /usr/sbin/tc
- /usr/sbin/ip
- /usr/bin/dig
- runc
- /usr/sbin/capsh
- /usr/bin/cgexec
recommends:
- kernel-modules-extra