Skip to content

Commit

Permalink
🔧 Add Dockerfile to Deploy
Browse files Browse the repository at this point in the history
  • Loading branch information
UltiRequiem committed Sep 22, 2021
1 parent fac3ded commit 291b7d9
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
FROM golang:alpine

ENV GO111MODULE=on \
CGO_ENABLED=0 \
GOOS=linux \
GOARCH=amd64

WORKDIR /build

COPY go.mod .
COPY go.sum .
RUN go mod download

COPY . .

RUN go build -o main .

WORKDIR /dist

RUN cp /build/main .

EXPOSE 3000

CMD ["/dist/main"]

0 comments on commit 291b7d9

Please sign in to comment.