-
-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci: Use goreleaser to build docker images (#589)
* add yaml schema comment * update dockerfile to just copy over the pre-compiled binary * add docker config to goreleaser * since goreleaser now pushes to GHCR, we need to authenticate before running gorelaeser * we don't need the docker release workflow anymore
- Loading branch information
1 parent
973a67b
commit 1084d11
Showing
4 changed files
with
56 additions
and
86 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,3 @@ | ||
ARG VERSION | ||
|
||
## ================================================================================================ | ||
## Builder Stage -> creating the binary | ||
## ================================================================================================ | ||
FROM golang:1.23.0-alpine AS builder | ||
ARG VERSION | ||
|
||
WORKDIR /build | ||
COPY . . | ||
RUN go build -ldflags="-s -w -X github.com/budimanjojo/talhelper/v3/cmd.version=${VERSION}" -o /usr/local/bin/talhelper | ||
|
||
|
||
## ================================================================================================ | ||
## Serving/Production Stage | ||
## ================================================================================================ | ||
FROM scratch | ||
COPY --from=builder /usr/local/bin/talhelper /usr/local/bin/talhelper | ||
COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ | ||
WORKDIR /config | ||
ENTRYPOINT [ "/usr/local/bin/talhelper" ] | ||
FROM alpine:3.20.3@sha256:beefdbd8a1da6d2915566fde36db9db0b524eb737fc57cd1367effd16dc0d06d | ||
COPY talhelper /bin/talhelper | ||
ENTRYPOINT ["/bin/talhelper"] |