mirror of
https://github.com/MrUnknownDE/bierkasten-casino.git
synced 2026-05-02 03:46:06 +02:00
feat: Füge Wallet-Unterstützung zur Crash-Seite hinzu und verbessere WebSocket-Verbindung
This commit is contained in:
+14
-1
@@ -14,6 +14,18 @@ server {
|
||||
root /usr/share/nginx/html;
|
||||
index index.html;
|
||||
|
||||
# --- WebSocket-Route ---
|
||||
# Dieser Block fängt Anfragen an /ws ab und leitet sie mit den
|
||||
# nötigen Headern für eine WebSocket-Verbindung weiter.
|
||||
location /ws {
|
||||
proxy_pass http://bierbaron_backend;
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
proxy_set_header Connection "upgrade";
|
||||
proxy_set_header Host $host;
|
||||
}
|
||||
|
||||
# --- API-Routen (HTTP) ---
|
||||
location ~ ^/(api|auth|me|wallet|slot|admin|health)($|/) {
|
||||
proxy_pass http://bierbaron_backend;
|
||||
proxy_http_version 1.1;
|
||||
@@ -25,14 +37,15 @@ server {
|
||||
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 $proxy_x_forwarded_proto;
|
||||
|
||||
proxy_set_header Cookie $http_cookie;
|
||||
}
|
||||
|
||||
# --- Statisches Frontend (Single Page Application) ---
|
||||
location / {
|
||||
try_files $uri /index.html;
|
||||
}
|
||||
|
||||
# Optionale Caching-Regeln für statische Assets
|
||||
location ~* \.(js|css|png|jpg|jpeg|gif|svg|ico|webp|woff|woff2|ttf)$ {
|
||||
expires 7d;
|
||||
add_header Cache-Control "public, max-age=604800, immutable";
|
||||
|
||||
Reference in New Issue
Block a user