FROM debian:stable-slim WORKDIR /data EXPOSE 80 443 RUN apt-get update \ && apt-get install -y --reinstall ca-certificates debian-archive-keyring \ && apt-get update \ && apt-get install -y nginx certbot \ && apt-get clean # Install Nginx, Certbot, and clean up RUN apt-get update \ && apt-get install -y nginx certbot \ && apt-get clean # Overwrite the default nginx.conf with our custom configuration COPY nginx.conf /etc/nginx/nginx.conf # Copy HTTP and Stream configurations into the container COPY conf.d/ /etc/nginx/conf.d/ COPY stream.d/ /etc/nginx/stream.d/ # Copy SSL certificates COPY letsencrypt/ /etc/letsencrypt/ # Copy MTA-STS files COPY mta-sts/ /mta-sts/ # Start Nginx and tail logs CMD ["bash", "-c", "nginx && tail -f /var/log/nginx/access.log /var/log/nginx/error.log"]