Created
November 1, 2018 10:41
-
-
Save billglover/29fff1b4542a59e7d06fea35fe706710 to your computer and use it in GitHub Desktop.
Dockerfile-arm
This file contains hidden or 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
FROM golang:1.11.1-alpine as build | |
RUN apk add --update --no-cache ca-certificates git | |
RUN mkdir /app | |
WORKDIR /app | |
COPY . . | |
RUN GOOS=linux GOARCH=arm go build -a -installsuffix cgo -ldflags="-w -s" -o /go/bin/app | |
FROM scratch | |
COPY --from=build /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ | |
COPY --from=build /go/bin/app /go/bin/app | |
ENTRYPOINT ["/go/bin/app"] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment