I’ve been trying to set up my magento2 on nginx server but when i tried to access the page via url, it said 404 page not found.
I followed this instruction on magento website:
https://experienceleague.adobe.com/en/docs/commerce-operations/installation-guide/prerequisites/web-server/nginx#install-and-configure-mysql-1
I did almost everything like this instruction except the last step to Configure SELinux and Firewalld
as I read that enabling SeLinux is very risky.
An answer and solution to fix this problem
2
Answers
It’s way better to install magento in a custom url. You can do this by editing hosts file and adding custom domain to nginx configuration. Using folder might be the issue here.
If you’re encountering a 404 Not Found error on Magento 2 with Nginx on Ubuntu, the issue is typically related to Nginx configuration, file permissions, or Magento settings.