Skip to content

Commit e7b5537

Browse files
authored
Add websocket paths including relay to nginx template (#4573)
1 parent 95794f5 commit e7b5537

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed

infrastructure_files/nginx.tmpl.conf

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,10 @@ upstream management {
2020
# insert the grpc+http port of your management container here
2121
server 127.0.0.1:8012;
2222
}
23+
upstream relay {
24+
# insert the port of your relay container here
25+
server 127.0.0.1:33080;
26+
}
2327

2428
server {
2529
# HTTP server config
@@ -55,6 +59,10 @@ server {
5559
# Proxy Signal wsproxy endpoint
5660
location /ws-proxy/signal {
5761
proxy_pass http://signal;
62+
proxy_http_version 1.1;
63+
proxy_set_header Upgrade $http_upgrade;
64+
proxy_set_header Connection "Upgrade";
65+
proxy_set_header Host $host;
5866
}
5967
# Proxy Signal
6068
location /signalexchange.SignalExchange/ {
@@ -71,6 +79,10 @@ server {
7179
# Proxy Management wsproxy endpoint
7280
location /ws-proxy/management {
7381
proxy_pass http://management;
82+
proxy_http_version 1.1;
83+
proxy_set_header Upgrade $http_upgrade;
84+
proxy_set_header Connection "Upgrade";
85+
proxy_set_header Host $host;
7486
}
7587
# Proxy Management grpc endpoint
7688
location /management.ManagementService/ {
@@ -80,6 +92,14 @@ server {
8092
grpc_send_timeout 1d;
8193
grpc_socket_keepalive on;
8294
}
95+
# Proxy Relay
96+
location /relay {
97+
proxy_pass http://relay;
98+
proxy_http_version 1.1;
99+
proxy_set_header Upgrade $http_upgrade;
100+
proxy_set_header Connection "Upgrade";
101+
proxy_set_header Host $host;
102+
}
83103

84104
ssl_certificate /etc/ssl/certs/ssl-cert-snakeoil.pem;
85105
ssl_certificate_key /etc/ssl/certs/ssl-cert-snakeoil.pem;

0 commit comments

Comments
 (0)