Jump to content

NGINX !!!!!!!!!


elliotrodgerjr
 Share

Recommended Posts

Hi all.

I have a successfully installed and running PW site on NGINX. It all went well and easy thanks to the hints and tricks in some thread.

However even though I hits the frontpage nicely then any navigation to anything on the site returns a 404 - even the admin panel URL.

I suspects that it does not properly pass the URL to processwire but is instead trying to move to a directory. Any ideas?

 

edit: it works without subdirectories, this my config with subdirectory tryna to solve it. not work though

        root /var/www/test.test/html;

        index index.html index.php;

        server_name test.test
        access_log    /var/log/nginx/access.log;
        error_log    /var/log/nginx/error.log;
        error_page 401 403 404 /404.html;

        # -----------------------------------------------------------------------------------------------
        # This location processes all other requests. If the request is for a file or directory that
        # physically exists on the server, then load the file. Else give control to ProcessWire.
        # -----------------------------------------------------------------------------------------------

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

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


 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...