Welcome! Log In Create A New Profile

Advanced

Re: Already loaded NGINX modules

Maxim Dounin
February 12, 2016 08:02PM
Hello!

On Fri, Feb 12, 2016 at 08:50:25AM -0800, Yichun Zhang (agentzh) wrote:

> Hello!
>
> On Fri, Feb 12, 2016 at 3:42 AM, Maxim Dounin wrote:
> > If there is no need to load a module - there should be no
> > load_module directive in the configuration. Everything else is
> > likely to cause confusion.
>
> The problem is that when we prepare nginx configurations for others,
> we may have no idea how about how a particular set of modules are
> built on the user side.

As already pointed out, to properly write a configuration in many
cases you have to know not only a set of modules, but also
particular module versions. I don't think that what you are
trying to do can be solved by introducing some "tolerant loading".
Instead, you'll introduce confusion for normal users - and you'll
still have the same problem with "configurations for others".

> > This is very similar to duplicate directives in configuration -
> > and duplicate directives are rejected by nginx, for the same
> > reasons.
>
> Not really similar because the nginx configuration writer definitely
> knows if he uses duplicate directives in his own nginx.conf but he can
> hardly know how the nginx binary on the user side is built since
> nginx.conf has no such information nor has a way to detect it in
> nginx.conf itself.

The question here is where you draw a line. If you assum that the
administrator controls full nginx.conf configuration, but has no
idea about modules loaded into nginx installed - well, it's may be
not very similar. But if you'll assume that the administrator
uses some pre-defined configuration snippets he cannot change -
this case becomes exactly the same.

--
Maxim Dounin
http://nginx.org/

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

Re: Already loaded NGINX modules

Maxim Dounin 1263 February 12, 2016 06:44AM

Re: Already loaded NGINX modules

Yichun Zhang (agentzh) 312 February 12, 2016 11:52AM

Re: Already loaded NGINX modules

Maxim Dounin 323 February 12, 2016 08:02PM



Sorry, you do not have permission to post/reply in this forum.

Online Users

Guests: 153
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 500 on July 15, 2024
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready