Welcome! Log In Create A New Profile

Advanced

Re: Understanding location blocks and try files

Valentin V. Bartenev
January 22, 2014 04:32PM
On Wednesday 22 January 2014 21:07:13 Jonathan Matthews wrote:
[..]
> ... and its this last step which isn't working as expected. I don't
> quite have the explanation or docs to hand to say why this won't work,
> but this SO page seems to have an interestingly un-up-voted answer at
> the bottom of the page:
> http://stackoverflow.com/questions/13138318/nginx-try-files-outside-location
>
> "You are probably under the delusion that try_files on server level
> must work for every request. Not at all. Quite the contrary, it works
> only for requests that match no location blocks."
>
> I'd be really interested to get confirmation that that statement is
> unequivocally true!
>

Well, actually I wrote this answer. So, I can confirm. =)

You may also find confirmations by Igor and Maxim by searching
through the mailing list.

There is a bit of history:
http://mailman.nginx.org/pipermail/nginx/2009-March/010749.html
http://mailman.nginx.org/pipermail/nginx/2011-June/027502.html
http://mailman.nginx.org/pipermail/nginx/2012-June/034389.html

Changes with nginx 0.7.44 23 Mar 2009

*) Feature: the "try_files" directive is now allowed on the server block
level.

but, personally I think it was a bad decision that eventually resulted to a
lot of confusion around.


wbr, Valentin V. Bartenev


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

Understanding location blocks and try files

AD7six January 22, 2014 01:31PM

Re: Understanding location blocks and try files

Jonathan Matthews January 22, 2014 02:04PM

Re: Understanding location blocks and try files

AD7six January 22, 2014 02:54PM

Re: Understanding location blocks and try files

Francis Daly January 22, 2014 03:38PM

Re: Understanding location blocks and try files

Jonathan Matthews January 22, 2014 04:08PM

Re: Understanding location blocks and try files

Valentin V. Bartenev January 22, 2014 04:32PM

Re: Understanding location blocks and try files

Francis Daly January 22, 2014 05:20PM

Re: Understanding location blocks and try files

AD7six January 23, 2014 06:54AM

Re: Understanding location blocks and try files

Francis Daly January 23, 2014 08:44PM

Re: Understanding location blocks and try files

AD7six January 24, 2014 11:17AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

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