init
This commit is contained in:
+19
@@ -0,0 +1,19 @@
|
||||
# syntax=docker/dockerfile:1.7
|
||||
FROM golang:1.23-alpine AS build
|
||||
WORKDIR /src
|
||||
RUN apk add --no-cache ca-certificates tzdata
|
||||
COPY go.mod ./
|
||||
COPY third_party ./third_party
|
||||
COPY cmd ./cmd
|
||||
COPY internal ./internal
|
||||
COPY web ./web
|
||||
RUN CGO_ENABLED=0 GOOS=linux go build -trimpath -ldflags="-s -w" -o /out/ai-disclosure ./cmd/server
|
||||
|
||||
FROM scratch
|
||||
COPY --from=build /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ca-certificates.crt
|
||||
COPY --from=build /usr/share/zoneinfo /usr/share/zoneinfo
|
||||
COPY --from=build /out/ai-disclosure /ai-disclosure
|
||||
USER 65532:65532
|
||||
EXPOSE 8080
|
||||
ENV LISTEN_ADDRESS=:8080 LICENSE_CACHE_FILE=/data/license-lease.json
|
||||
ENTRYPOINT ["/ai-disclosure"]
|
||||
Reference in New Issue
Block a user