proposition de Dockerfile a l'ancienne pour Guichet
This commit is contained in:
parent
e7e05ed929
commit
7d8a41ec93
1 changed files with 7 additions and 3 deletions
10
Dockerfile
10
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"]
|
||||
|
|
Loading…
Reference in a new issue