Welcome! Log In Create A New Profile

Advanced

403 Forbidden

May 23, 2018 10:31AM
403 Forbidden
nginx/1.12.1 (Ubuntu)

Distributor ID: Ubuntu
Description: Ubuntu 17.10
Release: 17.10
Codename: artful

I have many virtual sites running on my server identical to this one, but for some reason I have run into the 403 wall.

Permissions for my virtual website dir
sudo chown -R www-data:www-data /var/www/html/C1/
sudo chmod -R 755 /var/www/html/C1/
results
drwxrwxrwx 3 www-data www-data 4096 May 23 12:37 C1

The virtual directory is as follows.. and is linked to.
sudo ln -s /etc/nginx/sites-available/c1 /etc/nginx/sites-enabled/

server {
listen 80;
listen [::]:80;
root /var/www/html/C1;
index index.html index.php index.htm;
server_name c1inventory.xxxxxxx.com;

location / {
try_files $uri $uri/ /index.php?$query_string;
}


location ~ \.php$ {
try_files $uri =404;
fastcgi_split_path_info ^(.+\.php)(/.+)$;
fastcgi_index index.php;
fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;
include fastcgi_params;
fastcgi_param PATH_INFO $fastcgi_path_info;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
}

}

Dump from the nginx error log.

2018/05/23 14:15:49 [error] 1530#1530: *1 directory index of "/var/www/html/C1/" is forbidden, client: 67.127.276.257, server: c1inventory.xxxxxx.com, request: "GET / HTTP/1.1", host: "c1inventory.xxxxxx.com"

Any help is greatly appreciated.

Thanks.
Subject Author Posted

403 Forbidden

mdm100 May 23, 2018 10:31AM

Re: 403 Forbidden

pratyush May 23, 2018 11:36AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 154
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready