Skip to content

Commit

Permalink
add route for signalling server
Browse files Browse the repository at this point in the history
  • Loading branch information
Williangalvani committed Jul 17, 2024
1 parent 0ced5d1 commit 0c94b1e
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions core/tools/nginx/nginx.conf
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,20 @@ http {
rewrite ^/mavlink2rest$ /mavlink2rest/ redirect;
rewrite ^/mavlink2rest/(.*)$ /$1 break;
proxy_pass http://127.0.0.1:6040;
proxy_http_version 1.1;
# next two lines are required for websockets
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "Upgrade";
}

location /webrtc {
# Hide the header from the upstream application
proxy_hide_header Access-Control-Allow-Origin;

include cors.conf;
rewrite ^/webrtc$ /webrtc/ redirect;
rewrite ^/webrtc/(.*)$ /$1 break;
proxy_pass http://127.0.0.1:6021;
# next two lines are required for websockets
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "Upgrade";
Expand Down

0 comments on commit 0c94b1e

Please sign in to comment.