Minimal configuration

B.R. reallfqq-nginx at yahoo.fr
Mon Feb 17 13:13:14 UTC 2014


Sorry for my fluffy terminology.
What I called 'error handler' was the final argument of the try_files
directive, the one used if any other one fails to detect a valid
file/directory.

We ended concluding that:
try_files $uri $uri/; was invalid, looping internally for an infinite
amount of time
try_files $uri $uri/ /; was valid

I still don't get why the first case is invalid, with all the input you
provided me with:
The request URI was '/', so $uri = /, thus the first agument of try_files
should match the root directory and process it further (finding the index
file, etc.).
Why hasn't it been the case?

Otherwise stated: defaulting to '/' in the valid syntax means that both
'$uri' and '$uri/' values (both equalling '/' after cleanup of redundant
slashes) don't point towards a valid directory. This is obviously wrong,
since the root directory exists (and is processed when the fallback to the
'/' argument happens).

Considering all that, one could wonder why the 1st syntax is invalid.

I hope I clarified my question... It seems simple from my point of view :o\
---
*B. R.*
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.nginx.org/pipermail/nginx/attachments/20140217/0f12d0a0/attachment.html>


More information about the nginx mailing list