2023-06-13 01:32:21 +00:00
|
|
|
FROM debian:12-slim
|
2022-04-02 18:32:22 +00:00
|
|
|
|
|
|
|
ARG BUILD_DATE
|
|
|
|
|
|
|
|
LABEL \
|
|
|
|
maintainer="Logan Marchione <logan@loganmarchione.com>" \
|
|
|
|
org.opencontainers.image.authors="Logan Marchione <logan@loganmarchione.com>" \
|
|
|
|
org.opencontainers.image.title="docker-webdav-nginx" \
|
|
|
|
org.opencontainers.image.description="Runs a Nginx WebDav server in Docker" \
|
|
|
|
org.opencontainers.image.created=$BUILD_DATE
|
|
|
|
|
|
|
|
ARG DEBIAN_FRONTEND=noninteractive
|
|
|
|
|
2023-03-28 00:58:11 +00:00
|
|
|
RUN apt-get update && apt-get -y install --no-install-recommends \
|
2022-04-02 18:32:22 +00:00
|
|
|
apache2-utils \
|
2023-06-19 18:49:20 +00:00
|
|
|
netcat-openbsd \
|
2022-04-02 18:32:22 +00:00
|
|
|
nginx-extras && \
|
|
|
|
rm -rf /var/lib/apt/lists/* && \
|
|
|
|
mkdir -p "/var/www/webdav/restricted" && \
|
|
|
|
mkdir -p "/var/www/webdav/public" && \
|
|
|
|
chown -R www-data:www-data "/var/www" && \
|
|
|
|
rm /etc/nginx/sites-enabled/default
|
|
|
|
|
|
|
|
EXPOSE 80
|
|
|
|
|
|
|
|
VOLUME [ "/var/www/webdav" ]
|
|
|
|
|
2023-06-19 19:13:01 +00:00
|
|
|
COPY entrypoint.sh /
|
2023-03-28 01:28:35 +00:00
|
|
|
|
|
|
|
COPY VERSION /
|
2022-04-02 18:32:22 +00:00
|
|
|
|
|
|
|
COPY webdav.conf /etc/nginx/sites-enabled/webdav
|
|
|
|
|
2023-06-19 19:13:01 +00:00
|
|
|
ENTRYPOINT ["/entrypoint.sh"]
|
2022-04-02 18:32:22 +00:00
|
|
|
|
|
|
|
CMD ["nginx", "-g", "daemon off;"]
|
|
|
|
|
|
|
|
HEALTHCHECK CMD nc -z localhost 80 || exit 1
|