fix: switch admin to subdomain mode and fix frozen-lockfile build
- Remove /admin path prefix (using admin.protdskj.top subdomain instead) - Change pnpm install to --no-frozen-lockfile for lockfile compatibility - Simplify admin Nginx config to standard SPA serving 🤖 Generated with [Qoder][https://qoder.com]
This commit is contained in:
@@ -9,8 +9,8 @@ server {
|
||||
gzip on;
|
||||
gzip_types text/plain text/css application/json application/javascript text/xml application/xml;
|
||||
|
||||
location /admin/api/ {
|
||||
proxy_pass http://api:3000/api/;
|
||||
location /api/ {
|
||||
proxy_pass http://api:3000;
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Host $host;
|
||||
proxy_set_header X-Real-IP $remote_addr;
|
||||
@@ -18,16 +18,7 @@ server {
|
||||
proxy_set_header X-Forwarded-Proto $scheme;
|
||||
}
|
||||
|
||||
location /admin/ {
|
||||
alias /usr/share/nginx/html/;
|
||||
try_files $uri $uri/ @admin_spa;
|
||||
}
|
||||
|
||||
location @admin_spa {
|
||||
rewrite ^ /index.html break;
|
||||
}
|
||||
|
||||
location = / {
|
||||
return 301 /admin/;
|
||||
location / {
|
||||
try_files $uri $uri/ /index.html;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user