0

I have a nginx server running with a wordpress and Ajenti setup working like a champ. As well as gitlab and owncloud which both work, just not used.

But when I try to access a new setup, opencart, it gives me a 403 forbidden error.

I have the root folder in the same place as my other folders, and have even chmod777 the actual folder to attempt to get it to work with no success.

Error :

2015/06/12 07:59:48 [error] 19784#0: *4 directory index of "/var/www/opencart/" is forbidden, client: 76.164.165.4, server: adminpanelz.us.to, request: "GET / HTTP/1.1", host: "adminpanelz.us.to:9000"
2015/06/12 07:59:48 [error] 19784#0: *4 directory index of "/var/www/opencart/" is forbidden, client: 76.164.165.4, server: adminpanelz.us.to, request: "GET / HTTP/1.1", host: "adminpanelz.us.to:9000"
2015/06/12 07:59:49 [error] 19784#0: *4 directory index of "/var/www/opencart/" is forbidden, client: 76.164.165.4, server: adminpanelz.us.to, request: "GET / HTTP/1.1", host: "adminpanelz.us.to:9000"
2015/06/12 07:59:49 [error] 19784#0: *4 directory index of "/var/www/opencart/" is forbidden, client: 76.164.165.4, server: adminpanelz.us.to, request: "GET / HTTP/1.1", host: "adminpanelz.us.to:9000"

The setup I was following was here : http://www.minvolai.com/blog/2015/01/How-to-setup-Opencart-with-Nginx-and-MySql/How-to-setup-opencart-with-nginx-and-mysql/

4
  • Is there anything inside the /var/www/opencart folder? Like e.g. a file index.php? Otherwise, the server will try to serve a directory listing, which it isn't allowed, so it issues a 403 instead.
    – Jos
    Jun 12, 2015 at 12:52
  • Yes, there is a single info.php file, as i was just following the tutorial Jun 12, 2015 at 12:54
  • 1
    Can you retrieve the file info.php by name? As in: example.com/info.php?
    – Jos
    Jun 12, 2015 at 12:58
  • Jos.. i feel so stupid now.. thank you If you want to answer the question ill do the little answered thingy so you can get the credit :P Jun 12, 2015 at 13:06

1 Answer 1

1

If your browser requests a URL from the server that is not really a file but a directory, like http://example.com, the server looks in the directory for a file like index.htm, index.html, index.php and maybe others. If it can't find such a file, it may serve a "directory listing" instead, if you allow it. Otherwise, it will issue a 403 error.

info.php is not one of the files that can be served as default. So if you want to retrieve info.php you will have to call that by its full name.

1
  • Haha, thankies. I've had so many issues recently since I'm trying to install so much stuff on one server I just assumed that it was something that broke Jun 12, 2015 at 13:26

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .