Created
June 5, 2019 02:54
-
-
Save llitfkitfk/07e7608e82f45e507310c2157991e9c6 to your computer and use it in GitHub Desktop.
Dockerfile
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:alpine AS builder | |
| RUN apk add --no-cache git make | |
| WORKDIR /home/app | |
| ENV GOPROXY=https://mod.gokit.info | |
| COPY go.mod go.sum ./ | |
| RUN go mod download | |
| COPY . . | |
| RUN make build-linux | |
| FROM alpine:3.9 | |
| LABEL maintainer="llitfkitfk@gmail.com" | |
| RUN apk add --no-cache tzdata ca-certificates | |
| ENV TZ=Asia/Macao | |
| COPY --from=builder /home/app/bin /home/app/bin | |
| COPY docker-entrypoint.sh /usr/local/bin/ | |
| ENTRYPOINT ["docker-entrypoint.sh"] | |
| CMD [] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment