Fix env substitute issue in websocket docker setup (#3296)

* fix websocket connection issue in docker makeplane/plane#3195

* fix websocket connection issue for local env with removing from the prod nginx conf template makeplane/plane#319

* fix env substitution issue  of proxy_set_header makeplane/plane#3196

* review fixes

---------

Co-authored-by: Manish Gupta <manish@mgupta.me>
This commit is contained in:
AbId KhAn 2024-01-10 14:05:24 +06:00 committed by GitHub
parent 2580e66d4b
commit a70f551d17
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 3 additions and 4 deletions

View File

@ -44,9 +44,6 @@ services:
env_file:
- .env
environment:
POSTGRES_USER: ${PGUSER}
POSTGRES_DB: ${PGDATABASE}
POSTGRES_PASSWORD: ${PGPASSWORD}
PGDATA: /var/lib/postgresql/data
web:

View File

@ -1,4 +1,6 @@
#!/bin/sh
export dollar="$"
export http_upgrade="http_upgrade"
envsubst < /etc/nginx/nginx.conf.template > /etc/nginx/nginx.conf
exec nginx -g 'daemon off;'

View File

@ -19,7 +19,7 @@ http {
location / {
proxy_pass http://web:3000/;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Upgrade ${dollar}http_upgrade;
proxy_set_header Connection "upgrade";
}