错误信息:
2023/01/10 17:00:44 [crit] 3002719#0: *20444 stat() "/home/fanbook-mgr/fanbook-mgr.web/dist/index.html" failed (13: Permission denied), client: 60.182.104.237, server: fanbook-mgr.starlight.work, request: "GET / HTTP/2.0", host: "fanbook-mgr.starlight.work"
2023/01/10 17:00:44 [error] 3002719#0: *20444 rewrite or internal redirection cycle while internally redirecting to "/index.html", client: 60.182.104.237, server: fanbook-mgr.starlight.work, request: "GET / HTTP/2.0", host: "fanbook-mgr.starlight.work"
站点配置:
server {
listen 80;
listen 443 ssl http2;
server_name fanbook-mgr.starlight.work;
root /home/fanbook-mgr/fanbook-mgr.web/dist;
#SSL-START SSL相关配置,请勿删除或修改下一行带注释的404规则
#error_page 404/404.html;
#HTTP_TO_HTTPS_START
if ($server_port !~ 443){
rewrite ^(/.*)$ https://$host$1 permanent;
}
#HTTP_TO_HTTPS_END
ssl_certificate /www/server/panel/vhost/cert/fanbook-mgr.starlight.work/fullchain.pem;
ssl_certificate_key /www/server/panel/vhost/cert/fanbook-mgr.starlight.work/privkey.pem;
ssl_protocols TLSv1.1 TLSv1.2 TLSv1.3;
ssl_ciphers EECDH+CHACHA20:EECDH+CHACHA20-draft:EECDH+AES128:RSA+AES128:EECDH+AES256:RSA+AES256:EECDH+3DES:RSA+3DES:!MD5;
ssl_prefer_server_ciphers on;
ssl_session_cache shared:SSL:10m;
ssl_session_timeout 10m;
add_header Strict-Transport-Security "max-age=31536000";
error_page 497 https://$host$request_uri;
#SSL-END
location / {
error_page 403 /403;
error_page 404 /404;
error_page 500 /500;
index index.html;
try_files $uri $uri/ /index.html;
}
access_log /www/wwwlogs/fanbook-mgr.starlight.work.log;
error_log /www/wwwlogs/fanbook-mgr.starlight.work.error.log;
}
运行用户是 www
,与 fanbook-mgr
用户属于同一个组 web
,权限是 750
,照道理应该有权限访问?