ProjectProgressTracker/nginx-ppt24.conf

22 lines
585 B
Plaintext

server {
listen 80;
server_name ppt24.com www.ppt24.com;
root /var/www/ppt24.com/frontend/build;
index index.html;
# Redirect requests for non-existent files to index.html (SPA support)
location / {
try_files $uri $uri/ /index.html;
}
# API requests proxy to backend
location /api {
proxy_pass http://localhost:5000;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade';
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
}
}