From f8c4fe04a63ea1f85015f433de6109e6840c4b85 Mon Sep 17 00:00:00 2001 From: allthatjazzleo Date: Mon, 28 Oct 2024 13:50:36 +0800 Subject: [PATCH] chore: fix ca cert for docker --- Dockerfile | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/Dockerfile b/Dockerfile index 98ff98c..3262c5b 100644 --- a/Dockerfile +++ b/Dockerfile @@ -72,9 +72,16 @@ RUN set -eux;\ CGO_LDFLAGS="-L/rocksdb -L/usr/lib -L/lib -lrocksdb -lstdc++ -lm -lz -lbz2 -lsnappy -llz4 -lzstd";\ go build -tags 'rocksdb pebbledb' -ldflags "$LDFLAGS" -a -o snapshot . + +# Use alpine to source the latest CA certificates +FROM alpine:3 as alpine-3 + # Build final image from scratch FROM scratch +# Install trusted CA certificates +COPY --from=alpine-3 /etc/ssl/cert.pem /etc/ssl/cert.pem + WORKDIR / USER 1025:1025 COPY --from=builder --chown=1025:1025 /workspace/snapshot .