Dockerfile

This commit is contained in:
Gnarwhal 2024-10-02 19:15:07 +00:00
parent e0e4813806
commit 5c34ce2825
Signed by: Gnarwhal
GPG key ID: 0989A73D8C421174
2 changed files with 14 additions and 0 deletions

1
.gitignore vendored
View file

@ -23,3 +23,4 @@
!*/ !*/
!hash.sh !hash.sh
!Dockerfile

13
Dockerfile Normal file
View file

@ -0,0 +1,13 @@
FROM chimeralinux/chimera:latest AS base
RUN apk add go
FROM base AS builder
WORKDIR /app
COPY . .
RUN go build -ldflags "-s -w" -o diodemail -buildmode=pie ./cmd/server
FROM base AS runner
WORKDIR /app
COPY --from=builder /app/diodemail ./diodemail
CMD ["./diodemail"]