Jelajahi Sumber

Expose Certbot ports

Jon Chambers 2 tahun lalu
induk
melakukan
79b96cad6e
2 mengubah file dengan 2 tambahan dan 1 penghapusan
  1. 1 1
      data/nginx-terminate/nginx.conf
  2. 1 0
      docker-compose.yml

+ 1 - 1
data/nginx-terminate/nginx.conf

@@ -10,7 +10,7 @@ http {
         listen 80;
         listen 80;
 
 
         location /.well-known/acme-challenge/ {
         location /.well-known/acme-challenge/ {
-            root /var/www/certbot;
+            alias /var/www/certbot/;
         }
         }
     }
     }
 }
 }

+ 1 - 0
docker-compose.yml

@@ -10,6 +10,7 @@ services:
       - ./data/certbot/www:/var/www/certbot
       - ./data/certbot/www:/var/www/certbot
     ports:
     ports:
       - "443:443"
       - "443:443"
+      - "80:80"
     command: "/bin/sh -c 'while :; do sleep 6h & wait $${!}; /opt/nginx/sbin/nginx -s reload; done & /opt/nginx/sbin/nginx -c /etc/nginx/conf.d/nginx.conf -g \"daemon off;\"'"
     command: "/bin/sh -c 'while :; do sleep 6h & wait $${!}; /opt/nginx/sbin/nginx -s reload; done & /opt/nginx/sbin/nginx -c /etc/nginx/conf.d/nginx.conf -g \"daemon off;\"'"
   nginx-relay:
   nginx-relay:
     build: ./nginx-relay/
     build: ./nginx-relay/