From dd88985f7609f5514a404af524ae33bec2320b59 Mon Sep 17 00:00:00 2001 From: Steven 'Xaroth' Noorbergen Date: Thu, 18 Feb 2021 09:35:58 +0100 Subject: [PATCH] Update documentation to reflect the new env vars. --- docs/docker-swarm.md | 1 + docs/environment-variables.md | 3 +++ 2 files changed, 4 insertions(+) diff --git a/docs/docker-swarm.md b/docs/docker-swarm.md index 39b53369..0adc3eac 100644 --- a/docs/docker-swarm.md +++ b/docs/docker-swarm.md @@ -142,6 +142,7 @@ services: erpnext-nginx: image: frappe/erpnext-nginx:${ERPNEXT_VERSION?Variable ERPNEXT_VERSION not set} environment: + - UPSTREAM_REAL_IP_ADDRESS=10.0.0.0/8 - FRAPPE_PY=erpnext-python - FRAPPE_PY_PORT=8000 - FRAPPE_SOCKETIO=frappe-socketio diff --git a/docs/environment-variables.md b/docs/environment-variables.md index 3aa2e7cc..a1c105aa 100644 --- a/docs/environment-variables.md +++ b/docs/environment-variables.md @@ -20,6 +20,9 @@ These variables are set on every container start. Change in these variables will - `FRAPPE_SOCKETIO`: SocketIO host to reverse proxy. Default: 0.0.0.0 - `SOCKETIO_PORT`: SocketIO port to reverse proxy. Default: 9000 - `HTTP_TIMEOUT`: Nginx http timeout. Default: 120 +- `UPSTREAM_REAL_IP_ADDRESS `: The trusted address (or ip range) of upstream proxy servers. If set, this will tell nginx to trust the X-Forwarded-For header from these proxy servers in determining the real IP address of connecting clients. Default: 127.0.0.1 +- `UPSTREAM_REAL_IP_RECURSIVE`: When set to `on`, this will tell nginx to not just look to the last upstream proxy server in determining the real IP address. Default: off +- `UPSTREAM_REAL_IP_HEADER`: Set this to the header name sent by your upstream proxy server to indicate the real IP of connecting clients. Default: X-Forwarded-For ### frappe-socketio