From 947045c0c020c29864b16c638dd8f7301a86d21b Mon Sep 17 00:00:00 2001 From: Peter Kessler Date: Sat, 11 Apr 2026 11:58:57 +0000 Subject: [PATCH] Dockerfile aktualisiert --- Dockerfile | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/Dockerfile b/Dockerfile index ed2038c..79955ca 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,8 +1,8 @@ # Base-Image FROM alpine:3.22 AS builder -# Pakete installieren -RUN apk add --no-cache gcc musl-dev +# Pakete installieren + Updates einspielen +RUN apk upgrade --no-cache && apk add --no-cache gcc musl-dev # Arbeitsverzeichnis setzen WORKDIR /app @@ -17,6 +17,9 @@ RUN gcc -O2 -o deployment deployment.c # Base-Image FROM alpine:3.22 +# Sicherheitsupdates einspielen +RUN apk upgrade --no-cache + # Arbeitsverzeichnis setzen WORKDIR /app @@ -35,14 +38,10 @@ VOLUME ["/output"] # nicht als root laufen USER appuser -#update -apt update && apt upgrade -y - - # Healthcheck HEALTHCHECK --interval=30s --timeout=5s --start-period=10s --retries=3 \ CMD test -s /output/output.txt || exit 1 # Ausgabe wird ins Volume geschrieben ENTRYPOINT ["/bin/sh", "-c"] -CMD ["touch /output/output.txt && ./deployment 10 >> /output/output.txt & tail -f /output/output.txt"] +CMD ["touch /output/output.txt && ./deployment 10 >> /output/output.txt & tail -f /output/output.txt"] \ No newline at end of file