bglug.it/Dockerfile

21 lines
544 B
Docker
Raw Normal View History

2024-04-09 22:10:09 +02:00
FROM alpine:latest
RUN \
apk -U upgrade && \
apk add nginx curl logrotate tini && \
mkdir -p /wwwroot /logs && \
2024-04-09 22:10:09 +02:00
chown -R nginx:www-data /wwwroot /logs && \
chmod -R a-x,a=rX,ug+w /wwwroot /logs
COPY docker/rootfs /
COPY --chown=nginx:www-data public/ /wwwroot/
RUN find /wwwroot/ -type d -exec chmod 755 {} \; -o -type f -exec chmod 644 {} \;
2024-04-09 22:10:09 +02:00
# config test
RUN nginx -t
HEALTHCHECK --timeout=10s CMD curl --silent --fail -o /dev/null http://127.0.0.1:80/
ENTRYPOINT ["/sbin/tini", "--"]
CMD [ "/bin/sh", "/app/entrypoint.sh" ]