server { listen 80; # Przekieruj /odoo (bez slash) na /odoo/ (z slash) location = /odoo { return 301 /odoo/; } # Serwowanie plików Vue pod /odoo/ location /odoo/ { alias /usr/share/nginx/html/; index index.html; try_files $uri $uri/ /odoo/index.html; } # Proxy do backendu (niewidoczny z zewnątrz) location /odoo/api/ { proxy_pass http://backend:8000/; 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; } }