Skip to content

Commit 4ce2159

Browse files
committed
Always verify the integrity of downloaded binaries for security. For tini we
use the checksum of the binary that was released and gpg-signed by the author. Fix a FROM ... AS ... case mismatch as pointed out by docker compose.
1 parent 6b79a71 commit 4ce2159

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

Dockerfile.rocky8

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1713,8 +1713,10 @@ FROM --platform=linux/$ARCH setup_mig_configs AS start_mig
17131713
ARG DOMAIN
17141714

17151715
# Reap defuncted/orphaned processes
1716+
# IMPORTANT: always verify tini gpg signature and use checksum in download here
17161717
ARG TINI_VERSION=v0.18.0
1717-
ADD https://github.com/krallin/tini/releases/download/${TINI_VERSION}/tini /tini
1718+
ARG TINI_CHECKSUM=sha256:12d20136605531b09a2c2dac02ccee85e1b874eb322ef6baf7561cd93f93c855
1719+
ADD --checksum=${TINI_CHECKSUM} https://github.com/krallin/tini/releases/download/${TINI_VERSION}/tini /tini
17181720
RUN chmod +x /tini
17191721
ENTRYPOINT ["/tini", "--"]
17201722

Dockerfile.rocky9

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -302,7 +302,7 @@ RUN echo "Enable python3 support: $WITH_PY3"
302302
#RUN echo "Enable git checkout: $WITH_GIT"
303303

304304
#------------------------- next stage -----------------------------#
305-
FROM --platform=linux/$ARCH init as base
305+
FROM --platform=linux/$ARCH init AS base
306306
ARG DOMAIN
307307
ARG WILDCARD_DOMAIN
308308
ARG ENABLE_GDP
@@ -1600,8 +1600,10 @@ FROM --platform=linux/$ARCH setup_mig_configs AS start_mig
16001600
ARG DOMAIN
16011601

16021602
# Reap defuncted/orphaned processes
1603+
# IMPORTANT: always verify tini gpg signature and use checksum in download here
16031604
ARG TINI_VERSION=v0.18.0
1604-
ADD https://github.com/krallin/tini/releases/download/${TINI_VERSION}/tini /tini
1605+
ARG TINI_CHECKSUM=sha256:12d20136605531b09a2c2dac02ccee85e1b874eb322ef6baf7561cd93f93c855
1606+
ADD --checksum=${TINI_CHECKSUM} https://github.com/krallin/tini/releases/download/${TINI_VERSION}/tini /tini
16051607
RUN chmod +x /tini
16061608
ENTRYPOINT ["/tini", "--"]
16071609

0 commit comments

Comments
 (0)