From 65e0a06be83cdfac8eda2afe4b93cd154c9770c4 Mon Sep 17 00:00:00 2001 From: toir-bot Date: Sat, 25 Apr 2026 13:35:13 +0000 Subject: [PATCH] chore: initial project scaffold: frontend/nginx.conf --- frontend/nginx.conf | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 frontend/nginx.conf diff --git a/frontend/nginx.conf b/frontend/nginx.conf new file mode 100644 index 0000000..d845ee0 --- /dev/null +++ b/frontend/nginx.conf @@ -0,0 +1,20 @@ +server { + listen 80; + root /usr/share/nginx/html; + index index.html; + + # Static build assets. Must exist — if missing, return 404 instead of + # falling through to index.html (which would confuse the browser with a + # "text/html MIME for JS module" error). + location /assets/ { + try_files $uri =404; + expires 1y; + access_log off; + add_header Cache-Control "public, immutable"; + } + + # SPA routing: serve index.html for any client-side route. + location / { + try_files $uri $uri/ /index.html; + } +}