feat: initial Vite/React frontend service template
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
commit
9fd6fd1d26
32 changed files with 5218 additions and 0 deletions
32
nginx/default.conf
Normal file
32
nginx/default.conf
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
server {
|
||||
listen 8080;
|
||||
server_name _;
|
||||
root /usr/share/nginx/html;
|
||||
|
||||
# Liveness/readiness for k8s probes.
|
||||
location = /healthz {
|
||||
access_log off;
|
||||
default_type text/plain;
|
||||
return 200 "ok\n";
|
||||
}
|
||||
|
||||
# Runtime config, written at container start; never cache.
|
||||
location = /config.js {
|
||||
add_header Cache-Control "no-store" always;
|
||||
}
|
||||
|
||||
# Hashed build assets: cache forever; a missing asset is a real 404.
|
||||
location /assets/ {
|
||||
add_header Cache-Control "public, max-age=31536000, immutable" always;
|
||||
try_files $uri =404;
|
||||
}
|
||||
|
||||
location = /index.html {
|
||||
add_header Cache-Control "no-cache" always;
|
||||
}
|
||||
|
||||
# SPA fallback: unknown paths get index.html; the router handles them.
|
||||
location / {
|
||||
try_files $uri /index.html;
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue