diff --git a/doc/tls-proxy.md b/doc/tls-proxy.md index 7034e03..2041251 100644 --- a/doc/tls-proxy.md +++ b/doc/tls-proxy.md @@ -6,6 +6,12 @@ Run `bin/init --tls` to initialise local configuration with NGINX proxy configur A default config for NGINX is provided in `config/nginx/nginx.conf` which may be customised to your requirements. The path to the config file can be changed with the `NGINX_CONFIG_PATH` variable. +In order for Overleaf to run correctly behind the proxy, the following variables should be uncommented in `config/variables.env` +``` +SHARELATEX_BEHIND_PROXY=true +SHARELATEX_SECURE_COOKIE=true +``` + When the [SHARELATEX_PORT](overleaf-rc.md#sharelatex_port) variable is set, the port in the `proxy_pass` statement in `nginx.conf` needs to be changed to match. By default the https web interface will be available on `https://localhost:443`. The port can be changed via the `TLS_PORT` variable. \ No newline at end of file diff --git a/lib/config-seed/variables.env b/lib/config-seed/variables.env index 51e9218..2dc8541 100644 --- a/lib/config-seed/variables.env +++ b/lib/config-seed/variables.env @@ -16,8 +16,10 @@ TEXMFVAR=/var/lib/sharelatex/tmp/texmf-var # NGINX_WORKER_PROCESSES=4 # NGINX_WORKER_CONNECTIONS=768 -## Set for SSL via nginx-proxy -#VIRTUAL_HOST=103.112.212.22 +## Set for TLS via nginx-proxy +# SHARELATEX_BEHIND_PROXY=true +# SHARELATEX_SECURE_COOKIE=true +# VIRTUAL_HOST=103.112.212.22 # SHARELATEX_SITE_URL=http://overleaf.example.com # SHARELATEX_NAV_TITLE=Our Overleaf Instance