-
-
Notifications
You must be signed in to change notification settings - Fork 881
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
use_default_location behavior is undocumented and confusing/counterintuitive #544
Comments
I totally agree! At the least, the module should give a more correct (and useful) warning in cases where this causes problems. Or maybe there's a way to see if a '/' location exists for the vhost and suppress the default if so? |
btw, we're hoping to start work on documenting the main class in #941 |
I just hit this too. The lack of documentation isn't great. I am very happy to write a PR for the documentation, but I'm not clear on why you would want the behaviour of |
@beezly I think the idea is for the module to work "out of the box" with minimal configuration (by setting up that default location). |
At best, its current default configuration seems a bad default to set - per nginx best practices, you should generally have your document root defined in the "server" stanza rather than the "location" stanza. One should be able to reasonably assume that to be the default behavior. reference
I couldn't find any documentation on this, even at the top of the file, and had to dig into the code to determine why root wasn't being set in the server stanza.
While the default behavior seems counterintuitive to me, it would be acceptable if there were more (any) documentation around the behaviors of this parameter, and how/when to work around them.
The text was updated successfully, but these errors were encountered: