Does "include" use the "configuration prefix" or the "path prefix"?

Maxim Dounin mdounin at
Tue Apr 12 16:05:58 UTC 2016


On Mon, Apr 11, 2016 at 07:54:58PM +0000, hroku003 at wrote:

> THank you very much for confirmation.
> Is this documented anywhere?

I don't think it's explicitly documented anywhere except in 
CHANGES for 0.6.7 (

    *) Change: now the paths specified in the "include",
       "auth_basic_user_file", "perl_modules", "ssl_certificate",
       "ssl_certificate_key", and "ssl_client_certificate" directives are
       relative to directory of nginx configuration file nginx.conf, but not
       to nginx prefix directory.

Basically, there are two types of paths in nginx configuration:

- configuration-specific paths (include, SSL certs/keys, 
  auth_basic_user_file - that is, things that naturally a part of 
  configuration), resolved relative to nginx.conf file;

- all other paths, resolved from prefix.

This should be documented somewhere, and we already have a ticket 
for a related question,

Maxim Dounin

More information about the nginx mailing list