fixes lol
All checks were successful
Build and Push / build-all (push) Successful in 2m7s

This commit is contained in:
doomtube 2026-01-07 03:29:05 -05:00
parent 1a3930dd87
commit c358db55aa
6 changed files with 55 additions and 22 deletions

View file

@ -805,6 +805,27 @@ http {
proxy_send_timeout 3600s;
}
# WebRTC Signaling proxy for OvenMediaEngine
# Handles wss:// ws:// translation so OME doesn't need TLS certificates
location /webrtc/ {
# Proxy to OvenMediaEngine WebRTC signaling port
proxy_pass http://ovenmediaengine:3333/;
proxy_http_version 1.1;
proxy_buffering off;
# WebSocket upgrade headers
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection $connection_upgrade;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
# WebRTC signaling needs long timeouts
proxy_read_timeout 3600s;
proxy_send_timeout 3600s;
}
# Stream thumbnails - 3 second animated WebP generated on-demand via FFmpeg
location ~ ^/thumb/([^/]+)\.webp$ {
set $stream_key $1;
@ -867,6 +888,22 @@ http {
# Nakama Game Server WebSocket (nakama-js connects to /ws with query params)
location = /ws {
# CORS headers for WebSocket upgrade request
add_header Access-Control-Allow-Origin $cors_origin always;
add_header Access-Control-Allow-Methods "GET, POST, OPTIONS" always;
add_header Access-Control-Allow-Headers "Content-Type, Authorization, Upgrade, Connection" always;
add_header Access-Control-Allow-Credentials "true" always;
if ($request_method = 'OPTIONS') {
add_header Access-Control-Allow-Origin $cors_origin always;
add_header Access-Control-Allow-Methods "GET, POST, OPTIONS" always;
add_header Access-Control-Allow-Headers "Content-Type, Authorization, Upgrade, Connection" always;
add_header Access-Control-Allow-Credentials "true" always;
add_header Content-Length 0;
add_header Content-Type text/plain;
return 204;
}
# Runtime DNS resolution
set $nakama_backend nakama:7350;
# Must include $is_args$args when using variables - nginx won't auto-append query string