Skip to content

Commit

Permalink
dockerfile: init
Browse files Browse the repository at this point in the history
  • Loading branch information
dezeroku committed Sep 29, 2024
1 parent 05d5b45 commit cfbd4ce
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
FROM golang:1.23 AS build

WORKDIR /app

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

COPY *.go ./

RUN CGO_ENABLED=0 GOOS=linux go build

FROM build-stage AS test
RUN go test -v ./...

FROM gcr.io/distroless/static-debian12 AS release

WORKDIR /

COPY --from=build /app/ses_local_email /ses_local_email

USER nonroot:nonroot

ENTRYPOINT ["/ses_local_email"]

0 comments on commit cfbd4ce

Please sign in to comment.