mirror of
https://github.com/marcel-dempers/docker-development-youtube-series.git
synced 2025-06-06 17:01:30 +00:00
19 lines
418 B
Plaintext
19 lines
418 B
Plaintext
FROM golang:1.12.5-alpine3.9 as dev
|
|
|
|
# installing git
|
|
RUN apk update && apk upgrade && \
|
|
apk add --no-cache git
|
|
|
|
RUN go get github.com/sirupsen/logrus
|
|
RUN go get github.com/buaazp/fasthttprouter
|
|
RUN go get github.com/valyala/fasthttp
|
|
|
|
WORKDIR /work
|
|
COPY ./src /work/
|
|
RUN go build -o app
|
|
###########START NEW IMAGE###################
|
|
|
|
FROM alpine:3.9 as prod
|
|
COPY --from=dev /work/app /
|
|
CMD ./app
|