From 7d8a41ec937f2d41790174b366c333ace346f4b0 Mon Sep 17 00:00:00 2001 From: ADRN Date: Mon, 10 Jun 2024 20:29:33 +0200 Subject: proposition de Dockerfile a l'ancienne pour Guichet --- Dockerfile | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'Dockerfile') diff --git a/Dockerfile b/Dockerfile index 69f7f3a..87cb772 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,12 +1,16 @@ -FROM alpine:latest as certs +FROM golang:alpine3.20 as builder RUN apk --update add ca-certificates +COPY . . +RUN go get -d -v \ + && CGO_ENABLED=0 GOOS=linux go build -a -v -o /guichet + FROM scratch -COPY --from=certs /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ca-certificates.crt +COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ca-certificates.crt +COPY --from=builder /guichet /guichet ADD static /static -ADD guichet.static /guichet ADD templates /templates ENTRYPOINT ["/guichet"] -- cgit v1.2.3