@@ -28,18 +28,17 @@ before:
28
28
builds :
29
29
-id :coder-slim
30
30
dir :cmd/coder
31
- ldflags :
32
- ["-s -w -X github.com/coder/coder/buildinfo.tag={{ .Version }}"]
31
+ ldflags :["-s -w -X github.com/coder/coder/buildinfo.tag={{ .Version }}"]
33
32
env :[CGO_ENABLED=0]
34
33
goos :[darwin, linux, windows]
35
34
goarch :[amd64, arm, arm64]
36
35
goarm :["7"]
37
36
# Only build arm 7 for Linux
38
37
ignore :
39
38
-goos :windows
40
- goarm :' 7 '
39
+ goarm :" 7 "
41
40
-goos :darwin
42
- goarm :' 7 '
41
+ goarm :" 7 "
43
42
hooks :
44
43
# The "trimprefix" appends ".exe" on Windows.
45
44
post :|
@@ -48,8 +47,7 @@ builds:
48
47
-id :coder-linux
49
48
dir :cmd/coder
50
49
flags :[-tags=embed]
51
- ldflags :
52
- ["-s -w -X github.com/coder/coder/buildinfo.tag={{ .Version }}"]
50
+ ldflags :["-s -w -X github.com/coder/coder/buildinfo.tag={{ .Version }}"]
53
51
env :[CGO_ENABLED=0]
54
52
goos :[linux]
55
53
goarch :[amd64, arm, arm64]
@@ -58,24 +56,22 @@ builds:
58
56
-id :coder-windows
59
57
dir :cmd/coder
60
58
flags :[-tags=embed]
61
- ldflags :
62
- ["-s -w -X github.com/coder/coder/buildinfo.tag={{ .Version }}"]
59
+ ldflags :["-s -w -X github.com/coder/coder/buildinfo.tag={{ .Version }}"]
63
60
env :[CGO_ENABLED=0]
64
61
goos :[windows]
65
62
goarch :[amd64, arm64]
66
63
67
64
-id :coder-darwin
68
65
dir :cmd/coder
69
66
flags :[-tags=embed]
70
- ldflags :
71
- ["-s -w -X github.com/coder/coder/buildinfo.tag={{ .Version }}"]
67
+ ldflags :["-s -w -X github.com/coder/coder/buildinfo.tag={{ .Version }}"]
72
68
env :[CGO_ENABLED=0]
73
69
goos :[darwin]
74
70
goarch :[amd64, arm64]
75
71
hooks :
76
72
# This signs the binary that will be located inside the zip.
77
73
# MacOS requires the binary to be signed for notarization.
78
- #
74
+ #
79
75
# If it doesn't successfully sign, the zip sign step will error.
80
76
post :|
81
77
sh -c 'codesign -s {{.Env.AC_APPLICATION_IDENTITY}} -f -v --timestamp --options runtime {{.Path}} || true'
@@ -107,6 +103,54 @@ nfpms:
107
103
-src :coder.service
108
104
dst :/usr/lib/systemd/system/coder.service
109
105
106
+ dockers :
107
+ -image_templates :["ghcr.io/coder/coder:{{ .Tag }}-amd64"]
108
+ id :coder-linux
109
+ dockerfile :Dockerfile
110
+ use :buildx
111
+ build_flag_templates :
112
+ ---platform=linux/amd64
113
+ ---label=org.opencontainers.image.title=Coder
114
+ ---label=org.opencontainers.image.description=A tool for provisioning self-hosted development environments with Terraform.
115
+ ---label=org.opencontainers.image.url=https://github.com/coder/coder
116
+ ---label=org.opencontainers.image.source=https://github.com/coder/coder
117
+ ---label=org.opencontainers.image.version={{ .Version }}
118
+ ---label=org.opencontainers.image.revision={{ .FullCommit }}
119
+ ---label=org.opencontainers.image.licenses=AGPL-3.0
120
+ -image_templates :["ghcr.io/coder/coder:{{ .Tag }}-arm64"]
121
+ goarch :arm64
122
+ dockerfile :Dockerfile
123
+ use :buildx
124
+ build_flag_templates :
125
+ ---platform=linux/arm64/v8
126
+ ---label=org.opencontainers.image.title=coder
127
+ ---label=org.opencontainers.image.description=A tool for provisioning self-hosted development environments with Terraform.
128
+ ---label=org.opencontainers.image.url=https://github.com/coder/coder
129
+ ---label=org.opencontainers.image.source=https://github.com/coder/coder
130
+ ---label=org.opencontainers.image.version={{ .Tag }}
131
+ ---label=org.opencontainers.image.revision={{ .FullCommit }}
132
+ ---label=org.opencontainers.image.licenses=AGPL-3.0
133
+ -image_templates :["ghcr.io/coder/coder:{{ .Tag }}-armv7"]
134
+ goarch :arm
135
+ goarm :" 7"
136
+ dockerfile :Dockerfile
137
+ use :buildx
138
+ build_flag_templates :
139
+ ---platform=linux/arm/v7
140
+ ---label=org.opencontainers.image.title=Coder
141
+ ---label=org.opencontainers.image.description=A tool for provisioning self-hosted development environments with Terraform.
142
+ ---label=org.opencontainers.image.url=https://github.com/coder/coder
143
+ ---label=org.opencontainers.image.source=https://github.com/coder/coder
144
+ ---label=org.opencontainers.image.version={{ .Tag }}
145
+ ---label=org.opencontainers.image.revision={{ .FullCommit }}
146
+ ---label=org.opencontainers.image.licenses=AGPL-3.0
147
+ docker_manifests :
148
+ -name_template :ghcr.io/coder/coder:{{ .Tag }}
149
+ image_templates :
150
+ -ghcr.io/coder/coder:{{ .Tag }}-amd64
151
+ -ghcr.io/coder/coder:{{ .Tag }}-arm64
152
+ -ghcr.io/coder/coder:{{ .Tag }}-armv7
153
+
110
154
release :
111
155
ids :[coder-linux, coder-darwin, coder-windows, packages]
112
156