Last active
January 30, 2023 03:24
-
-
Save sunny-b/f0b6e01e0cf39cf5bb0f9df591828f6f to your computer and use it in GitHub Desktop.
golang dockerfiles
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
FROM golang:latest | |
WORKDIR /src | |
COPY go.sum go.mod ./ | |
RUN go mod download | |
COPY . . | |
RUN CGO_ENABLED=0 go build -o /bin/app . | |
ENTRYPOINT ["/bin/app"] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment