Control Web Panel
WebPanel => Apache => Nginx => Topic started by: tabestmaker on September 24, 2020, 05:51:33 PM
-
hello i am trying to set up nginx only for wordpress site but keep getting 403 forbidden on homepage and 404 on all subpages
itried adding try_files $uri $uri/ /index.php$is_args$args; inside location / { } in /etc/nginx/conf.d/vhosts/.....com.conf
but nothing works
-
as usual for any other issue, you need to check the server logs as mentioned on the cwp wiki
-
i checked /var/log/nginx/
but the files were empty
-
UPDATE
here are the logs
2020/09/29 19:10:12 [error] 27863#27863: *309282 "/home/afkarla/public_html/******.com/index.php" is forbidden (13: Permission denied), client: , server: ******.com, request: "GET / HTTP/1.1", host: "*****.com"
i have tried fix permission in cwp admin but problem is still there
-
i applied
find /home/afkarla/public_html/***.com/ -type f -print0 | xargs -0 chmod 0644
and now everything works it seems fix permissions doesn't work when using multiple configuration
thanks for the help :)