Kevin Nowak 566e564e77
Some checks failed
continuous-integration/drone/push Build is failing
Dockerfile aktualisiert
2026-04-11 12:00:10 +00:00

26 lines
524 B
Docker

# Base-Image
FROM alpine
# Pakete installieren
RUN apk update && apk upgrade
RUN apk add --no-cache build-base curl vim net-tools
# Arbeitsverzeichnis setzen
WORKDIR /app
# alles kopieren
COPY . .
# Code kompilieren
RUN gcc -o deployment deployment.c
# Verzeichnis für Ausgabe anlegen
RUN mkdir /output
# User hinzufügen
RUN adduser -D appuser
USER appuser
# Ausgabe wird ins Container-Dateisystem geschrieben
ENTRYPOINT ["/bin/bash", "-c"]
CMD ["./deployment 10 > /output/output.txt && tail -f /output/output.txt"]