Welcome! Log In Create A New Profile

Advanced

Re: root and alias with php5-fpm

Francis Daly
September 07, 2015 05:26PM
On Mon, Sep 07, 2015 at 11:23:32AM -0500, Kristofer Pettijohn wrote:

Hi there,

> I just want each location in each
> server to see /apps/grant/ as the root, and for try_files to process
> the index.php file in the base of that location last.

If I've understood you correctly, what you describe is not what your
current configuration does.

Assume that files called "yes" do exist on your filesystem, and files
called "no" do not exist.

What response do you want for requests for each of:

/grant/one/yes.txt
/grant/one/no.txt
/grant/one/yes.php
/grant/one/no.php

And do you get that response in each case? If not, does the difference
matter?

> Can someone provide some guidance?

I suggest using a named location for handling the "not there" fallback
-- either as the final argument to try_files, or perhaps as "error_page
404 = @fallback".

Then

location @fallback {
fastcgi_param SCRIPT_FILENAME /apps/grant/index.php;
include fastcgi_params;
fastcgi_pass unix:/local/sockets/grant.sock;
}

Test what order of the first two directives work in your fasctcgi server.

f
--
Francis Daly francis@daoine.org

_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

root and alias with php5-fpm

Kristofer Pettijohn September 07, 2015 12:24PM

Re: root and alias with php5-fpm

Kristofer Pettijohn September 07, 2015 12:50PM

Re: root and alias with php5-fpm

Francis Daly September 07, 2015 05:26PM

Re: root and alias with php5-fpm

Kristofer Pettijohn September 07, 2015 07:50PM

Re: root and alias with php5-fpm

Francis Daly September 08, 2015 03:46AM

Re: root and alias with php5-fpm

Kristofer Pettijohn September 08, 2015 10:24AM

Re: root and alias with php5-fpm

Francis Daly September 09, 2015 03:46AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 172
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