planning-btp-leo (e5706ce)
Published 2026-09-05 20:28:56 +02:00 by krokodyle
Installation
docker pull git.zestes.fr/krokodyle/planning-btp-leo:e5706cesha256:e34d0dcfb2b4b12246927fa634db5943a4911d2032b00b2ead1440b341e99d80Image layers
| ADD alpine-minirootfs-3.22.5-x86_64.tar.gz / # buildkit |
| CMD ["/bin/sh"] |
| RUN /bin/sh -c apk add --no-cache ca-certificates tzdata && addgroup -S -g 1001 app && adduser -S -u 1001 -G app -h /app app # buildkit |
| WORKDIR /app |
| COPY /out/server ./server # buildkit |
| COPY templates/ ./templates/ # buildkit |
| COPY static/ ./static/ # buildkit |
| COPY migrations/ ./migrations/ # buildkit |
| RUN /bin/sh -c printf '%s\n' '#!/bin/sh' 'set -e' 'DIR=$(dirname "${DB_PATH:-/app/data/planning.db}")' 'mkdir -p "$DIR" 2>/dev/null || true' 'if [ ! -w "$DIR" ]; then' ' echo "ERREUR: $DIR non inscriptible par uid $(id -u):$(id -g)." >&2' ' echo " -> utilise le volume nomme (defaut), ou: chown 1001:1001 <dossier-hote>" >&2' ' exit 1' 'fi' 'exec /app/server "$@"' > /usr/local/bin/entrypoint.sh && chmod +x /usr/local/bin/entrypoint.sh # buildkit |
| RUN /bin/sh -c mkdir -p /app/data && chown -R app:app /app # buildkit |
| USER app |
| ENV PORT=8080 DB_PATH=/app/data/planning.db APP_ENV=production TZ=Europe/Paris |
| EXPOSE [8080/tcp] |
| VOLUME [/app/data] |
| HEALTHCHECK {Test:[CMD-SHELL wget -q --spider "http://127.0.0.1:${PORT}/login" || exit 1] Interval:30s Timeout:3s StartPeriod:5s StartInterval:0s Retries:3} |
| ENTRYPOINT ["/usr/local/bin/entrypoint.sh"] |