set directive at http level
Valentin V. Bartenev
vbart at nginx.com
Wed Aug 9 21:03:23 UTC 2017
On Wednesday 09 August 2017 23:17:13 Sorin Manole wrote:
> Hello,
>
> Do you think there is a problem in making the set directive available
> at http level (right now it's only server and lower). This would allow
> the usage of variables defined (and overridden in a lower config
> level) by set in directives like "map" and "log_format".
>
> Thanks.
1. The "set" directive is an instruction of the "rewrite" module.
If you learn how it works, you will realize that "set" on the
"http" level has no sense.
Please, take a look at the "rewrite" module documentation:
http://nginx.org/en/docs/http/ngx_http_rewrite_module.html
2. There's no problem in using variables defined by a "set" directive
in "map" or "log_format" directives. That's already allowed.
wbr, Valentin V. Bartenev
More information about the nginx-devel
mailing list