52 lines
1.6 KiB
Plaintext
52 lines
1.6 KiB
Plaintext
server {
|
|
listen 80;
|
|
|
|
# --- TRANSCRIPTION AUDIO (STT) ---
|
|
# Doit être AVANT location / pour avoir la priorité
|
|
location /api/v1/audio/transcriptions {
|
|
proxy_pass http://audio-api:7860/v1/audio/transcriptions;
|
|
proxy_set_header Host $host;
|
|
proxy_set_header X-Real-IP $remote_addr;
|
|
proxy_http_version 1.1;
|
|
proxy_buffering off;
|
|
proxy_read_timeout 600s;
|
|
proxy_send_timeout 600s;
|
|
client_max_body_size 25M;
|
|
}
|
|
|
|
# --- API AUDIO (accès direct Gradio/FastAPI) ---
|
|
location /audio/ {
|
|
proxy_pass http://audio-api:7860/;
|
|
proxy_http_version 1.1;
|
|
proxy_set_header Upgrade $http_upgrade;
|
|
proxy_set_header Connection "upgrade";
|
|
proxy_set_header Host $host;
|
|
proxy_buffering off;
|
|
proxy_read_timeout 600s;
|
|
client_max_body_size 25M;
|
|
}
|
|
|
|
# --- INTERFACE PRINCIPALE & FLUX OLLAMA ---
|
|
location / {
|
|
proxy_pass http://open-webui:8080;
|
|
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;
|
|
|
|
# INDISPENSABLE POUR LES WEBSOCKETS
|
|
proxy_http_version 1.1;
|
|
proxy_set_header Upgrade $http_upgrade;
|
|
proxy_set_header Connection "upgrade";
|
|
|
|
# DÉSACTIVATION TOTALE DU CACHE ET DU BUFFER
|
|
proxy_buffering off;
|
|
proxy_cache off;
|
|
chunked_transfer_encoding on;
|
|
|
|
# Temps d'attente rallongé pour les gros modèles
|
|
proxy_read_timeout 600s;
|
|
proxy_send_timeout 600s;
|
|
client_max_body_size 25M;
|
|
}
|
|
} |