I'm trying to set up nginx. When serving a file I get the following error:
[crit] 64347#0: *4 stat() "/home/zmbq/web/static/index.html" failed (13: Permission denied)
I've set the proper permissions to the file and all its parent directories, restart nginx and the error persists.
Running sudo -u nginx cat /home/zmbq/web/static/index.html
displays the file's content. stat
ing the same file also works.
Permissions down the path:
[zmbq@csm-web var]$ ll /
drwxr-xr-x. 3 root root 18 Aug 30 09:25 home
[zmbq@csm-web var]$ ll /home
drwxr-xr-x. 13 zmbq zmbq 4096 Aug 30 12:17 zmbq
[zmbq@csm-web var]$ ll /home/zmbq
drwxrwxr-x. 8 zmbq zmbq 77 Aug 30 11:53 web
[zmbq@csm-web var]$ ll /home/zmbq/web
drwxrwxr-x. 4 zmbq nginx 4096 Aug 30 11:46 static
[zmbq@csm-web var]$ ll /home/zmbq/web/static
-rw-rw-r--. 1 zmbq nginx 683 Aug 30 11:46 index.html