修复开发容器启动并加固部署配置

This commit is contained in:
Cheng Zhou
2026-06-22 15:35:00 +08:00
parent 360a2ba2b1
commit 6056c8364a
8 changed files with 88 additions and 8 deletions
+6
View File
@@ -52,6 +52,12 @@ http {
add_header Cache-Control "public, max-age=31536000, immutable" always;
}
location ~* (^|/)(\.git|\.env($|[./_-])|wp-config\.php|config\.php|database\.yml|backup($|[._/-])) {
access_log off;
log_not_found off;
return 404;
}
location /api/ {
proxy_pass http://backend;
proxy_set_header Host $host;
+6
View File
@@ -50,6 +50,12 @@ http {
add_header Cache-Control "public, max-age=86400" always;
}
location ~* (^|/)(\.git|\.env($|[./_-])|wp-config\.php|config\.php|database\.yml|backup($|[._/-])) {
access_log off;
log_not_found off;
return 404;
}
location /api/ {
proxy_pass http://backend;
proxy_set_header Host $host;