-
-
Notifications
You must be signed in to change notification settings - Fork 16
/
.goreleaser.yml
211 lines (206 loc) · 6.42 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
203
204
205
206
207
208
209
210
211
project_name: trusted-cgi
before:
hooks:
- python3 assemble_md.py ./docs --output MANUAL.md --exclude ./docs/vendor ./docs/.bundle ./docs/.jekyll-cache ./docs/_site
- pandoc MANUAL.md -s -t man -o trusted-cgi.1
- pandoc --metadata title="Trusted-CGI manual" MANUAL.md -s --include-in-header=./docs/assets/github-pandoc.css --toc -o MANUAL.html
- gzip -f trusted-cgi.1
builds:
- main: ./cmd/trusted-cgi/main.go
id: server
binary: trusted-cgi
env:
- CGO_ENABLED=0
goarch:
- amd64
- arm
- arm64
goos:
- linux
- windows
- darwin
flags:
- -trimpath
- main: ./cmd/cgi-ctl
id: client
binary: cgi-ctl
env:
- CGO_ENABLED=0
goarch:
- amd64
- arm
- arm64
goos:
- linux
- windows
- darwin
flags:
- -trimpath
nfpms:
- id: debian
package_name: "trusted-cgi"
file_name_template: "{{ .ProjectName }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}{{ if .Arm }}v{{ .Arm }}{{ end }}"
homepage: https://github.com/reddec/trusted-cgi
maintainer: Baryshnikov Aleksandr <owner@reddec.net>
description: Lightweigt runner for lambda functions/apps in CGI like mode
license: MIT
meta: true
dependencies:
- "trusted-cgi-server"
- "trusted-cgi-client"
formats:
- deb
- id: debian-server
package_name: "trusted-cgi-server"
file_name_template: "{{ .ProjectName }}-server_{{ .Version }}_{{ .Os }}_{{ .Arch }}{{ if .Arm }}v{{ .Arm }}{{ end }}"
homepage: https://github.com/reddec/trusted-cgi
maintainer: Baryshnikov Aleksandr <owner@reddec.net>
description: Lightweigt runner for lambda functions/apps in CGI like mode
license: MIT
builds:
- server
formats:
- deb
recommends:
- make
- python3
- python3-venv
- git
suggests:
- php-cli
- nodejs
- npm
scripts:
postinstall: "debian/postinstall.sh"
preremove: "debian/preremove.sh"
contents:
- dst: /var/trusted-cgi
type: dir
- dst: /etc/trusted-cgi
type: dir
- src: debian/trusted-cgi.service
dst: /etc/systemd/system/trusted-cgi.service
- src: trusted-cgi.1.gz
dst: /usr/local/share/man/man1/trusted-cgi.1.gz
- src: debian/trusted-cgi.env
dst: /etc/trusted-cgi/trusted-cgi.env
type: config
- id: debian-client
package_name: "trusted-cgi-client"
file_name_template: "{{ .ProjectName }}-client_{{ .Version }}_{{ .Os }}_{{ .Arch }}{{ if .Arm }}v{{ .Arm }}{{ end }}"
homepage: https://github.com/reddec/trusted-cgi
maintainer: Baryshnikov Aleksandr <owner@reddec.net>
description: Client for lightweigt runner for lambda functions/apps in CGI like mode
license: MIT
formats:
- deb
builds:
- client
archives:
- name_template: "{{ .ProjectName }}_{{ .Os }}_{{ .Arch }}{{ if .Arm }}v{{ .Arm }}{{ end }}"
files:
- LICENSE
- README.md
- MANUAL.md
- MANUAL.html
format: tar.gz
format_overrides:
- goos: windows
format: zip
dockers:
# build full images for ARM and AMD64
- image_templates:
- "reddec/trusted-cgi:{{ .Tag }}-amd64"
- "reddec/trusted-cgi:v{{ .Major }}-amd64"
- "reddec/trusted-cgi:v{{ .Major }}.{{ .Minor }}-amd64"
- "reddec/trusted-cgi:latest-amd64"
use: buildx
dockerfile: Dockerfile
ids:
- server
build_flag_templates:
- "--platform=linux/amd64"
- image_templates:
- "reddec/trusted-cgi:{{ .Tag }}-arm64v8"
- "reddec/trusted-cgi:v{{ .Major }}-arm64v8"
- "reddec/trusted-cgi:v{{ .Major }}.{{ .Minor }}-arm64v8"
- "reddec/trusted-cgi:latest-arm64v8"
use: buildx
goarch: arm64
dockerfile: Dockerfile
ids:
- server
build_flag_templates:
- "--platform=linux/arm64/v8"
# build light images for ARM and AMD64
- image_templates:
- "reddec/trusted-cgi:{{ .Tag }}-light-amd64"
- "reddec/trusted-cgi:v{{ .Major }}-light-amd64"
- "reddec/trusted-cgi:v{{ .Major }}.{{ .Minor }}-light-amd64"
- "reddec/trusted-cgi:latest-light-amd64"
use: buildx
dockerfile: Dockerfile.minimal
ids:
- server
build_flag_templates:
- "--platform=linux/amd64"
- image_templates:
- "reddec/trusted-cgi:{{ .Tag }}-light-arm64v8"
- "reddec/trusted-cgi:v{{ .Major }}-light-arm64v8"
- "reddec/trusted-cgi:v{{ .Major }}.{{ .Minor }}-light-arm64v8"
- "reddec/trusted-cgi:latest-light-arm64v8"
use: buildx
goarch: arm64
dockerfile: Dockerfile.minimal
ids:
- server
build_flag_templates:
- "--platform=linux/arm64/v8"
docker_manifests:
# full versions
- name_template: "reddec/trusted-cgi:v{{ .Major }}.{{ .Minor }}"
image_templates:
- "reddec/trusted-cgi:v{{ .Major }}.{{ .Minor }}-amd64"
- "reddec/trusted-cgi:v{{ .Major }}.{{ .Minor }}-arm64v8"
- name_template: "reddec/trusted-cgi:v{{ .Major }}"
image_templates:
- "reddec/trusted-cgi:v{{ .Major }}.{{ .Minor }}-amd64"
- "reddec/trusted-cgi:v{{ .Major }}.{{ .Minor }}-arm64v8"
- name_template: "reddec/trusted-cgi:latest"
image_templates:
- "reddec/trusted-cgi:v{{ .Major }}.{{ .Minor }}-amd64"
- "reddec/trusted-cgi:v{{ .Major }}.{{ .Minor }}-arm64v8"
# light versions
- name_template: "reddec/trusted-cgi:v{{ .Major }}.{{ .Minor }}-light"
image_templates:
- "reddec/trusted-cgi:v{{ .Major }}.{{ .Minor }}-light-amd64"
- "reddec/trusted-cgi:v{{ .Major }}.{{ .Minor }}-light-arm64v8"
- name_template: "reddec/trusted-cgi:v{{ .Major }}-light"
image_templates:
- "reddec/trusted-cgi:v{{ .Major }}.{{ .Minor }}-light-amd64"
- "reddec/trusted-cgi:v{{ .Major }}.{{ .Minor }}-light-arm64v8"
- name_template: "reddec/trusted-cgi:light"
image_templates:
- "reddec/trusted-cgi:v{{ .Major }}.{{ .Minor }}-light-amd64"
- "reddec/trusted-cgi:v{{ .Major }}.{{ .Minor }}-light-arm64v8"
publishers:
- name: production
ids:
- debian
- debian-server
- debian-client
checksum: false
signature: false
cmd: "curl -X POST -u '{{.Env.UPLOAD_PRODUCTION_USERNAME}}:{{.Env.UPLOAD_PRODUCTION_SECRET}}' -F file=@{{.ArtifactPath}} https://apt.reddec.net/api/files/{{ .ProjectName }}"
checksum:
name_template: 'checksums.txt'
snapshot:
name_template: "{{ .Tag }}"
changelog:
sort: asc
filters:
exclude:
- '^docs:'
- '^doc:'
- '^test:'
- '^build:'