From ad0a8587b7615c1215b6aae373d49d65e206e8b8 Mon Sep 17 00:00:00 2001 From: Fabien BOURGEOIS Date: Mon, 29 Mar 2021 22:26:53 +0200 Subject: [PATCH] [IMP]Nginx images : add external ports For easier redirections --- nginx/Dockerfile | 2 ++ odoo/nginx/odoo.conf | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/nginx/Dockerfile b/nginx/Dockerfile index 4a5d47f..fea4f87 100644 --- a/nginx/Dockerfile +++ b/nginx/Dockerfile @@ -5,6 +5,8 @@ MAINTAINER Yaltik - Fabien Bourgeois ENV NGINX_HOST localhost 127.0.0.1 ENV NGINX_PORT 8080 ENV NGINX_SSL_PORT 8443 +ENV NGINX_EXTERNAL_PORT 80 +ENV NGINX_EXTERNAL_SSL_PORT 443 ENV CERTIFICATE_PATH /etc/nginx/certs/req.pem ENV CERTIFICATE_KEY_PATH /etc/nginx/certs/cert.key ENV SSL_PROTOCOLS TLSv1.2 TLSv1.3 diff --git a/odoo/nginx/odoo.conf b/odoo/nginx/odoo.conf index fa7e857..2a890ea 100644 --- a/odoo/nginx/odoo.conf +++ b/odoo/nginx/odoo.conf @@ -9,7 +9,7 @@ upstream ${SERVICE}longpoll { server { listen ${NGINX_PORT}; server_name ${SERVER_NAMES}; - return 301 https://${DOLLSIGN}host:${NGINX_SSL_PORT}${DOLLSIGN}request_uri; + return 301 https://${DOLLSIGN}host:${NGINX_EXTERNAL_SSL_PORT}${DOLLSIGN}request_uri; } server {