From b340b22f0c23fb4a858afbe5abd1092993664ef2 Mon Sep 17 00:00:00 2001 From: Mohan <86064887+binarybaron@users.noreply.github.com> Date: Thu, 18 Sep 2025 15:19:24 -0400 Subject: [PATCH] fix(asb, asb-controller): install root certificates in docker image (#569) Co-authored-by: binarybaron --- swap-asb/Dockerfile | 8 ++++++++ swap-controller/Dockerfile | 8 ++++++++ 2 files changed, 16 insertions(+) diff --git a/swap-asb/Dockerfile b/swap-asb/Dockerfile index f9bbcea6..e5eaf535 100644 --- a/swap-asb/Dockerfile +++ b/swap-asb/Dockerfile @@ -93,6 +93,14 @@ RUN cargo build --release --locked -vv -p swap-controller --bin=asb-controller # Latest Ubuntu 24.04 image as of Tue, 05 Aug 2025 15:34:08 GMT FROM ubuntu:24.04@sha256:a08e551cb33850e4740772b38217fc1796a66da2506d312abe51acda354ff061 AS runner +# Install native root certificates +ENV DEBIAN_FRONTEND=noninteractive +RUN --mount=type=cache,target=/var/cache/apt \ + --mount=type=cache,target=/var/lib/apt \ + apt-get update && \ + apt-get install -y ca-certificates && \ + update-ca-certificates + COPY --from=builder /target/release/asb /bin/asb COPY --from=builder /target/release/asb-controller /bin/asb-controller diff --git a/swap-controller/Dockerfile b/swap-controller/Dockerfile index fa3df2d1..04bb1a95 100644 --- a/swap-controller/Dockerfile +++ b/swap-controller/Dockerfile @@ -12,6 +12,14 @@ RUN cargo build --locked --bin asb-controller --release # Latest Debian Bookworm image as of Tue, 05 Aug 2025 15:34:08 GMT FROM debian:bookworm@sha256:b6507e340c43553136f5078284c8c68d86ec8262b1724dde73c325e8d3dcdeba AS runner +# Install native root certificates +ENV DEBIAN_FRONTEND=noninteractive +RUN --mount=type=cache,target=/var/cache/apt \ + --mount=type=cache,target=/var/lib/apt \ + apt-get update && \ + apt-get install -y ca-certificates && \ + update-ca-certificates + COPY --from=builder /build/target/release/asb-controller /usr/local/bin/asb-controller ENTRYPOINT ["/usr/local/bin/asb-controller"] \ No newline at end of file