2026-09-27 08:54:48 +03:30
|
|
|
server {
|
|
|
|
|
listen 80;
|
|
|
|
|
server_name _;
|
|
|
|
|
root /usr/share/nginx/html;
|
|
|
|
|
index index.html;
|
|
|
|
|
|
2026-10-06 16:28:05 +03:30
|
|
|
location /_nuxt/ {
|
2026-09-27 08:54:48 +03:30
|
|
|
expires 1y;
|
|
|
|
|
add_header Cache-Control "public, immutable";
|
|
|
|
|
}
|
|
|
|
|
|
2026-10-06 16:28:05 +03:30
|
|
|
# mime.types پیشفرض nginx نوع webmanifest را ندارد
|
|
|
|
|
location = /manifest.webmanifest {
|
|
|
|
|
default_type application/manifest+json;
|
|
|
|
|
}
|
|
|
|
|
|
2026-09-27 09:17:53 +03:30
|
|
|
# $uri/index.html بهجای $uri/ تا دایرکتوری / ریدایرکت ۳۰۱ نسازد
|
2026-09-27 08:54:48 +03:30
|
|
|
location / {
|
2026-09-27 09:17:53 +03:30
|
|
|
try_files $uri $uri.html $uri/index.html =404;
|
2026-09-27 08:54:48 +03:30
|
|
|
}
|
|
|
|
|
|
|
|
|
|
error_page 404 /404.html;
|
|
|
|
|
|
|
|
|
|
gzip on;
|
|
|
|
|
gzip_vary on;
|
|
|
|
|
gzip_types text/css application/javascript application/json image/svg+xml text/plain;
|
|
|
|
|
}
|