When configuration virtual host in nginx with below configuration file.

[caption id=“attachment_101” align=“aligncenter” width=“522”]virtual host configuration for php.sandbox virtual host configuration for php.sandbox[/caption]

Might be, you will have trouble with 403 forbidden error:

[caption id=“attachment_99” align=“aligncenter” width=“1020”]nginx virtual host 403 nginx virtual host 403[/caption]

it could be caused by selinux, just check selinux audit logs with the command:

sudo ausearch -m avc –start recent | grep httpd or sudo ausearch -m avc –start recent | grep httpd or sudo ausearch -m avc –start recent | grep nginx sudo ausearch -m avc –start recent | grep nginx

[caption id=“attachment_98” align=“alignnone” width=“1912”]selinux audit for nginx user selinux audit for nginx user[/caption]

The solution is that let selinux allow httpd user to read user content by the command

Good luck ;)