arut / nginx-python-module

Nginx Python Module
BSD 2-Clause "Simplified" License
136 stars 36 forks source link

per-server python* directives #3

Closed msva closed 7 years ago

msva commented 7 years ago

it would be nice to allow python* directives on per-server{}-block level (incl. keeping variables and functions available only in that server-block context namespace, to not mixup with another server{}s).

arut commented 7 years ago

Some python* directives are available at the server{} level. Particularly those which make sense at this level. As for variables and functions, they are all global. This is like a single big python script operating in the same namespace. This approach is very straightforward.