Dockerfile 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. FROM nginxproxymanager/testca AS testca
  2. FROM nginxproxymanager/nginx-full:certbot-node
  3. LABEL maintainer="Jamie Curnow <[email protected]>"
  4. SHELL ["/bin/bash", "-o", "pipefail", "-c"]
  5. ENV SUPPRESS_NO_CONFIG_WARNING=1 \
  6. S6_BEHAVIOUR_IF_STAGE2_FAILS=1 \
  7. S6_CMD_WAIT_FOR_SERVICES_MAXTIME=0 \
  8. S6_FIX_ATTRS_HIDDEN=1 \
  9. S6_KILL_FINISH_MAXTIME=10000 \
  10. S6_VERBOSITY=2 \
  11. NODE_OPTIONS="--openssl-legacy-provider"
  12. RUN echo "fs.file-max = 65535" > /etc/sysctl.conf \
  13. && apt-get update \
  14. && apt-get install -y jq python3-pip logrotate moreutils \
  15. && apt-get clean \
  16. && rm -rf /var/lib/apt/lists/*
  17. # Task
  18. WORKDIR /usr
  19. RUN curl -sL https://taskfile.dev/install.sh | sh
  20. WORKDIR /root
  21. COPY rootfs /
  22. COPY scripts/install-s6 /tmp/install-s6
  23. RUN rm -f /etc/nginx/conf.d/production.conf \
  24. && chmod 644 /etc/logrotate.d/nginx-proxy-manager \
  25. && /tmp/install-s6 "${TARGETPLATFORM}" \
  26. && rm -f /tmp/install-s6 \
  27. && chmod 644 -R /root/.cache
  28. # Certs for testing purposes
  29. COPY --from=testca /home/step/certs/root_ca.crt /etc/ssl/certs/NginxProxyManager.crt
  30. EXPOSE 80 81 443
  31. ENTRYPOINT [ "/init" ]