Created
March 11, 2026 19:41
-
-
Save uriel1998/fb96fd0a74beaae5f900ffdd1e0ee0d2 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #LAN IP goes here | |
| upstream jitsi_web { | |
| server 192.168.1.1:8000; | |
| } | |
| server { | |
| listen 80; | |
| server_name chat.example.com; | |
| return 301 https://$host$request_uri; | |
| } | |
| server { | |
| listen 443 ssl http2; | |
| server_name chat.example.com; | |
| #Let's Encrypt should handle this for you. | |
| ssl_certificate /etc/letsencrypt/live/chat.example.com/fullchain.pem; | |
| ssl_certificate_key /etc/letsencrypt/live/chat.example.com/privkey.pem; | |
| # helpful defaults for long-lived websocket connections | |
| proxy_read_timeout 3600s; | |
| proxy_send_timeout 3600s; | |
| # WebSockets: XMPP signaling | |
| location /xmpp-websocket { | |
| proxy_pass http://jitsi_web/xmpp-websocket; | |
| proxy_http_version 1.1; | |
| proxy_set_header Upgrade $http_upgrade; | |
| proxy_set_header Connection "upgrade"; | |
| proxy_set_header Host $host; | |
| proxy_set_header X-Forwarded-Proto https; | |
| proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | |
| } | |
| # WebSockets: Colibri (bridge channel) | |
| location /colibri-ws { | |
| proxy_pass http://jitsi_web/colibri-ws; | |
| proxy_http_version 1.1; | |
| proxy_set_header Upgrade $http_upgrade; | |
| proxy_set_header Connection "upgrade"; | |
| proxy_set_header Host $host; | |
| proxy_set_header X-Forwarded-Proto https; | |
| proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | |
| } | |
| # Everything else (web UI, config, static assets) | |
| location / { | |
| proxy_pass http://jitsi_web/; | |
| proxy_http_version 1.1; | |
| proxy_set_header Host $host; | |
| proxy_set_header X-Forwarded-Proto https; | |
| proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment