From 1e392f94a710658d60019b8e3045b4fda12495a6 Mon Sep 17 00:00:00 2001 From: Philippe Caseiro Date: Mon, 5 Feb 2024 11:04:28 +0100 Subject: [PATCH] fix(dockerfile): updating base images versions. Keep things up to date and security alerts away from trivi. Using apk package for dumb-init --- Dockerfile | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/Dockerfile b/Dockerfile index 9e8607d..d736576 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM golang:1.20 AS BUILD +FROM reg.cadoles.com/proxy_cache/library/golang:1.21.6 AS BUILD RUN apt-get update \ && apt-get install -y make @@ -21,17 +21,11 @@ RUN /src/dist/bouncer_linux_amd64_v1/bouncer -c '' config dump > /src/dist/bounc && yq -i '.admin.auth.privateKey = "/etc/bouncer/admin-key.json"' /src/dist/bouncer_linux_amd64_v1/config.yml \ && yq -i '.redis.adresses = ["redis:6379"]' /src/dist/bouncer_linux_amd64_v1/config.yml -FROM alpine:3.18 AS RUNTIME +FROM reg.cadoles.com/proxy_cache/library/alpine:3.19.1 AS RUNTIME -ARG DUMB_INIT_VERSION=1.2.5 +RUN apk add --no-cache ca-certificates dumb-init -RUN apk add --no-cache ca-certificates - -RUN mkdir -p /usr/local/bin \ - && wget -O /usr/local/bin/dumb-init https://github.com/Yelp/dumb-init/releases/download/v${DUMB_INIT_VERSION}/dumb-init_${DUMB_INIT_VERSION}_x86_64 \ - && chmod +x /usr/local/bin/dumb-init - -ENTRYPOINT ["/usr/local/bin/dumb-init", "--"] +ENTRYPOINT ["/usr/bin/dumb-init", "--"] RUN mkdir -p /usr/local/bin /usr/share/bouncer/bin /etc/bouncer