Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
fuckwit12184y@kescherRant does not matter if the auth location in on top because the auth route is most specific route and nginx will not try the other one.
-
fuckwit12184y@kescherRant out of nginx docs:
nginx first searches for the most specific prefix location given by literal strings regardless of the listed order. In the configuration above the only prefix location is “/” and since it matches any request it will be used as a last resort. Then nginx checks locations given by regular expression in the order listed in the configuration file. -
fuckwit12184y@kescherRant happens. I had the same idea at first and later read that this did not matter for me
Related Rants
Damn you nginx...
Let's say you have a simple location directive like:
location / {
auth_reques /auth;
index index.html;
}
location = /auth {
internal;
proxy_pass <...>;
}
Now guess how often nginx makes a subrequest to /auth.
Thats correct TWO times... "why?" you ask?
Well isn't it obvious that nginx hits the auth request, then rewrites the request to the index file, hits the auth request again because it's technically a different request now and then proceeds to hand out the file?
Thanks for documenting this. NOT
rant
random
nginx