-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Using goreleaser to build the docker image too
- Loading branch information
1 parent
3f9aa08
commit 8ece330
Showing
3 changed files
with
19 additions
and
34 deletions.
There are no files selected for viewing
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,17 +1,18 @@ | ||
FROM golang:alpine as base | ||
# the base image is only used for compilation | ||
ARG BUILD_VERSION=0.0.1-test | ||
ENV CGO_ENABLED=0 | ||
ENV GOOS=linux | ||
ENV GOARCH=amd64 | ||
WORKDIR /go/src/github.com/VEVO/awsRetagger | ||
RUN apk add --no-cache git build-base | ||
COPY . . | ||
RUN make go-build | ||
# ARG BUILD_VERSION=0.0.1-test | ||
# ENV CGO_ENABLED=0 | ||
# ENV GOOS=linux | ||
# ENV GOARCH=amd64 | ||
# WORKDIR /go/src/github.com/VEVO/awsRetagger | ||
# RUN apk add --no-cache git build-base | ||
# COPY . . | ||
# RUN make go-build | ||
|
||
# Getting a small image with only the binary | ||
FROM scratch | ||
COPY --from=base /go/src/github.com/VEVO/awsRetagger/awsRetagger /awsRetagger | ||
# COPY --from=base /go/src/github.com/VEVO/awsRetagger/awsRetagger /awsRetagger | ||
COPY awsRetagger / | ||
# This is needed when you do HTTPS requests | ||
COPY --from=base /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ | ||
ENTRYPOINT ["/awsRetagger"] |
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