add alternative port for certbot, change path for spa__app int docker-compose.yml, change Dockerfile
This commit is contained in:
@@ -25,3 +25,6 @@ HTTPS_OUTER_PORT=443
|
||||
# NGINX
|
||||
EMAIL=valitovgaziz@yandex.ru
|
||||
DOMAINS=yalarba.ru,www.yalarba.ru
|
||||
|
||||
# CERTBOT
|
||||
CERTBOT_PORT=333
|
||||
|
||||
+2
-1
@@ -76,6 +76,7 @@ services:
|
||||
volumes:
|
||||
- ./nginx/configs:/etc/nginx/conf.d
|
||||
- certbot-etc:/etc/letsencrypt
|
||||
- ./spa/app:/var/www/yalarba.ru/html
|
||||
networks:
|
||||
- web-network
|
||||
depends_on:
|
||||
@@ -87,7 +88,7 @@ services:
|
||||
volumes:
|
||||
- certbot-etc:/etc/letsencrypt
|
||||
- certbot-var:/var/lib/letsencrypt
|
||||
command: sh -c "certbot certonly --standalone --noninteractive --agree-tos --email ${EMAIL} -d ${DOMAINS} --keep-until-expiring"
|
||||
command: sh -c "certbot certonly --standalone -p ${CERBOT_PORT} --noninteractive --agree-tos --email ${EMAIL} -d ${DOMAINS} --keep-until-expiring"
|
||||
env_file:
|
||||
- .env
|
||||
restart: unless-stopped
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
FROM nginx:latest
|
||||
|
||||
RUN mkdir -p /var/www/yalarba.ru/html
|
||||
|
||||
COPY spa_app/index.html /var/www/yalarba.ru/html
|
||||
|
||||
@@ -55,3 +55,11 @@ server {
|
||||
# fastcgi_pass unix:/var/run/php/php8.1-fpm.sock;
|
||||
# }
|
||||
}
|
||||
|
||||
# HTTP for certbot ssl certificate alterante port
|
||||
server {
|
||||
listen ${CERTBOT_PORT}; # альтернативный порт для Certbot
|
||||
location ~ /.well-known {
|
||||
allow all;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user