Connection to the apk repositories is HTTPS by default

This commit is contained in:
Razvan Stoica 2021-03-16 09:58:57 +02:00
parent 2986d618f4
commit b757aa7334

View file

@ -5,17 +5,11 @@ LABEL \
org.label-schema.url="https://dockerbench.com" \
org.label-schema.vcs-url="https://github.com/docker/docker-bench-security.git"
# Switch to the HTTPS endpoint for the apk repositories
# https://github.com/gliderlabs/docker-alpine/issues/184
RUN set -eux; \
sed -i 's!http://dl-cdn.alpinelinux.org/!https://alpine.global.ssl.fastly.net/!g' /etc/apk/repositories && \
apk add --no-cache \
iproute2 \
docker-cli \
dumb-init
RUN apk add --no-cache iproute2 \
docker-cli \
dumb-init
COPY ./*.sh /usr/local/bin/
COPY ./tests/*.sh /usr/local/bin/tests/
COPY . /usr/local/bin/
HEALTHCHECK CMD exit 0