Compare commits

..

6 Commits

Author SHA1 Message Date
6a9e363852 MultiOriginal 2026-04-25 13:58:41 +00:00
86a45d2708 ubuntu Build stage aber alpine prod
UbuntuBased aber Multistage
2026-04-25 13:57:43 +00:00
f195da7021 Mehr oder weniger fertig
hab noch keine erlaubniss auf output, ansonsten fertig
2026-04-25 13:52:43 +00:00
14535e58b6 MultiStageBuild 2026-04-25 11:16:35 +00:00
f2b91dba26 Test, ob securitygefixed ist. Noch nichts geaendert, allerdings gibt es neue alpine Version 2026-04-16 10:56:15 +00:00
644c7e7685 Dies ist mein erster Commit 2026-04-11 13:34:51 +00:00

View File

@ -1,5 +1,5 @@
# Base-Image
FROM ubuntu:latest
FROM ubuntu:latest AS build_stage
# Pakete installieren
RUN apt-get update
@ -14,9 +14,18 @@ COPY . .
# Code kompilieren
RUN gcc -o deployment deployment.c
FROM alpine AS runtime
RUN apk add --no-cache bash
WORKDIR /app
COPY --from=build_stage /app/deployment .
# Verzeichnis für Ausgabe anlegen
RUN mkdir /output
# Ausgabe wird ins Container-Dateisystem geschrieben
ENTRYPOINT ["/bin/bash", "-c"]
CMD ["./deployment 10 > /output/output.txt && tail -f /output/output.txt"]
CMD ["./deployment 10 > /output/output.txt && tail -f /output/output.txt"]