Created
August 4, 2021 06:47
-
-
Save mikemackintosh/52dba09d44c20f87ea4fe9177ff99b0a to your computer and use it in GitHub Desktop.
Revisions
-
mikemackintosh created this gist
Aug 4, 2021 .There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,26 @@ FROM node:16-alpine3.11 as build-node RUN apk --no-cache --virtual build-dependencies add \ python \ make \ g++ WORKDIR /workdir COPY web/ . RUN yarn install RUN yarn build FROM golang:1.17rc2-alpine3.14 as build-go ENV GOPATH "" RUN go env -w GOPROXY=direct RUN apk add git ADD go.mod go.sum ./ RUN go mod download ADD . . COPY --from=build-node /workdir/build ./web/build RUN go build -o /main FROM alpine:3.13 COPY --from=build-go /main /main ENTRYPOINT [ "/main" ]