chore: add Dockerfile and basic CI test

This commit is contained in:
2022-05-23 23:26:25 +01:00
parent 0003d6f9ec
commit 64c234f07c
4 changed files with 60 additions and 0 deletions

13
Dockerfile Normal file
View File

@@ -0,0 +1,13 @@
FROM golang:1.18-alpine as builder
RUN apk add --no-cache git make
WORKDIR /app
COPY . .
RUN env CGO_ENABLED=0 go build -a -o dotkatapult -ldflags "-s -w"
FROM scratch
ENV PORT 8080
EXPOSE 8080
WORKDIR /
COPY --from=builder /app/dotkatapult /
CMD ["/dotkatapult"]