hishtory/backend/server/Dockerfile
2022-04-08 23:56:02 -07:00

9 lines
224 B
Docker

FROM golang:1.17
COPY go.mod ./
COPY go.sum ./
RUN unset GOPATH; go mod download
COPY . ./
RUN unset GOPATH; go build -o /server -ldflags "-X main.ReleaseVersion=v0.`cat VERSION`" backend/server/server.go
CMD [ "/server" ]