Dateien
Hetzner-Backup/v2_nginx/Dockerfile.letsencrypt

21 Zeilen
448 B
Docker

FROM nginx:alpine
# Certbot für Let's Encrypt installieren
RUN apk add --no-cache certbot certbot-nginx
# SSL-Verzeichnis erstellen
RUN mkdir -p /etc/nginx/ssl
# Default config entfernen
RUN rm -f /etc/nginx/conf.d/default.conf
# Nginx-Konfiguration kopieren
COPY nginx.conf /etc/nginx/nginx.conf
# Entrypoint für Certbot
COPY entrypoint-letsencrypt.sh /entrypoint.sh
RUN chmod +x /entrypoint.sh
EXPOSE 80 443
ENTRYPOINT ["/entrypoint.sh"]