updated nginx container ports
Some checks failed
Automatisch Backend Tests / test (pull_request) Has been cancelled
Automatisch CI / linter (pull_request) Has been cancelled
Automatisch CI / start-backend-server (pull_request) Has been cancelled
Automatisch CI / start-backend-worker (pull_request) Has been cancelled
Automatisch CI / build-web (pull_request) Has been cancelled

This commit is contained in:
Linden Crandall 2025-02-08 06:46:37 +09:00
parent bb979ac003
commit a38151b776
4 changed files with 27 additions and 16 deletions

View File

@ -31,8 +31,8 @@ services:
- ./certbot/conf:/etc/letsencrypt
- ./certbot/www:/var/www/certbot
ports:
- ${PORT}:${PORT}
- ${PORT}:443
- ${NGINX_HTTP_PORT}:${MAIN_HTTP_PORT}
- ${NGINX_HTTPS_PORT}:443
certbot:
image: certbot/certbot:latest
@ -46,7 +46,7 @@ services:
dockerfile: Dockerfile.compose
entrypoint: /compose-entrypoint.sh
ports:
- '${PORT}:${PORT}'
- '${MAIN_HTTP_PORT}:${MAIN_HTTP_PORT}'
depends_on:
postgres:
condition: service_healthy
@ -55,7 +55,7 @@ services:
environment:
- HOST=${HOST}
- PROTOCOL=${PROTOCOL}
- PORT=${PORT}
- PORT=${MAIN_HTTP_PORT}
- APP_ENV=${APP_ENV}
- REDIS_HOST=${REDIS_HOST}
- POSTGRES_HOST=${POSTGRES_HOST}

View File

@ -8,12 +8,16 @@ events {
http {
server {
listen 7757;
listen [::]:7757;
# nonstandard nginx http port
listen 7758;
listen [::]:7758;
server_name <HOSTNAME>;
location / {
proxy_pass http://<HOSTNAME>:7757;
# Forward to Automatisch site which is running on port 7757
proxy_pass http://main:7757;
}
location ~ /.well-known/acme-challenge/ {

View File

@ -8,12 +8,16 @@ events {
http {
server {
listen 7757;
listen [::]:7757;
# nonstandard nginx http port
listen 7758;
listen [::]:7758;
server_name <HOSTNAME>;
location / {
proxy_pass http://<HOSTNAME>:7757;
# Forward to Automatisch site which is running on port 7757
proxy_pass http://main:7757;
}
location ~ /.well-known/acme-challenge/ {

View File

@ -9,9 +9,9 @@ http {
server {
listen 7757;
listen [::]:7757;
# nonstandard nginx http port
listen 7758;
listen [::]:7758;
server_name <HOSTNAME>;
location ~ /.well-known/acme-challenge/ {
@ -23,8 +23,9 @@ http {
server {
listen 7757 ssl http2;
listen [::]:7757 ssl http2;
# nonstandard nginx https port
listen 7759 ssl http2;
listen [::]:7759 ssl http2;
# use ssl letsencrypt certs
ssl_certificate /etc/letsencrypt/live/<HOSTNAME>/fullchain.pem;
@ -33,7 +34,9 @@ http {
location / {
proxy_pass http://<HOSTNAME>:7757/;
# Forward to Automatisch site which is running on port 7757
proxy_pass http://main:7757/;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;