InvoicePlane setup 404error (nginx/ubuntu)

I have extracted all the files to a subdirectory on my domain and now when i try to access sub_directory/setup it throws 404error. .htaccess is not the problem as i am using nginx. also i tried the virtualhost conf solution provided here, but it didn’t work either. Have any idea what must be causing this?

here is my .conf

    server {
        server_name www.mydomain.com;
        return 301 $scheme://mydomain.com$request_uri;
}

server {
listen 80;
root /var/www/mydomain.com;
index index.php index.html index.htm; 
server_name mydomain.com;


location / {
        try_files $uri $uri/ /index.php?q=$uri&$args;
    }

    location ~ \.php$ {
        try_files $uri =404;
        fastcgi_pass unix:/var/run/php5-fpm.sock;
        fastcgi_index index.php;
        include fastcgi_params;
    }

    location = /favicon.ico {
        log_not_found off;
        access_log off;
    }

    location = /robots.txt {
        allow all;
        log_not_found off;
        access_log off;
    }

    location ~ /\. {
        deny all;
    }

    location ~* /(?:uploads|files)/.*\.php$ {
        deny all;
    }
}

Try this:

root /var/www/mydomain.com/sub_directory;

Thanks!! It worked.

This topic was automatically closed after 24 hours. New replies are no longer allowed.