1
0
mirror of https://gitlab.com/MoonTestUse1/AdministrationItDepartmens.git synced 2025-08-14 00:25:46 +02:00

add admin in vue

This commit is contained in:
1
2024-12-25 13:23:06 +06:00
parent 434bcc4b52
commit ec177c9cce

View File

@@ -5,23 +5,17 @@ server {
root /usr/share/nginx/html; root /usr/share/nginx/html;
index index.html; index index.html;
# Добавляем заголовки для SPA # Основной маршрут для статических файлов
add_header X-Frame-Options "SAMEORIGIN";
add_header X-XSS-Protection "1; mode=block";
add_header X-Content-Type-Options "nosniff";
# Обработка всех маршрутов фронтенда
location / { location / {
try_files $uri $uri/ /index.html; try_files $uri $uri/ /index.html;
expires -1; add_header Cache-Control "no-cache, no-store, must-revalidate";
add_header Cache-Control "no-store, no-cache, must-revalidate";
} }
# Явно указываем маршрут для админки # Маршрут для админ-панели
location /admin { location /admin {
alias /usr/share/nginx/html;
try_files $uri $uri/ /index.html; try_files $uri $uri/ /index.html;
expires -1; add_header Cache-Control "no-cache, no-store, must-revalidate";
add_header Cache-Control "no-store, no-cache, must-revalidate";
} }
# API прокси # API прокси
@@ -39,8 +33,4 @@ server {
# Обработка ошибок # Обработка ошибок
error_page 404 /index.html; error_page 404 /index.html;
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root /usr/share/nginx/html;
}
} }