added deployment files

This commit is contained in:
tusuii
2026-02-19 18:34:10 +05:30
parent 8f4cf07ec0
commit 27ad50f574
8 changed files with 201 additions and 0 deletions

31
nginx.conf Normal file
View File

@@ -0,0 +1,31 @@
server {
listen 80;
server_name _;
root /usr/share/nginx/html;
index index.html;
# Gzip compression
gzip on;
gzip_types text/plain text/css application/json application/javascript text/xml application/xml application/xml+rss text/javascript;
gzip_min_length 1024;
# Cache static assets aggressively
location ~* \.(js|css|png|jpg|jpeg|gif|ico|svg|avif|webp|woff|woff2|ttf|eot)$ {
expires 1y;
add_header Cache-Control "public, immutable";
try_files $uri =404;
}
# SPA fallback: send all unmatched routes to index.html
location / {
try_files $uri $uri/ /index.html;
}
# Disable access logs for health probes (optional)
location /healthz {
access_log off;
return 200 "ok";
add_header Content-Type text/plain;
}
}