kopia lustrzana https://github.com/piku/piku
Env UWSGI_INCLUDE_FILE to include custom uwsgi. (#93)
rodzic
57a71474bd
commit
7d4e7e2cb7
|
@ -29,6 +29,7 @@ You can configure deployment settings by placing special variables in an `ENV` f
|
|||
* `UWSGI_LOG_X_FORWARDED_FOR` (boolean): set the `log-x-forwarded-for` option.
|
||||
* `UWSGI_GEVENT`: enable the Python 2 `gevent` plugin
|
||||
* `UWSGI_ASYNCIO`: enable the Python 2/3 `asyncio` plugin
|
||||
* `UWSGI_INCLUDE_FILE`: a uwsgi config file in the app's dir to include - useful for including custom uwsgi directives.
|
||||
|
||||
## Nginx Settings
|
||||
|
||||
|
|
5
piku.py
5
piku.py
|
@ -858,7 +858,10 @@ def spawn_worker(app, kind, command, env, ordinal=1):
|
|||
for k in ['NGINX_ACL']:
|
||||
if k in env:
|
||||
del env[k]
|
||||
|
||||
|
||||
# insert user defined uwsgi settings if set
|
||||
settings += parse_settings(join(APP_ROOT, app, env.get("UWSGI_INCLUDE_FILE"))).items() if env.get("UWSGI_INCLUDE_FILE") else []
|
||||
|
||||
for k, v in env.items():
|
||||
settings.append(('env', '{k:s}={v}'.format(**locals())))
|
||||
|
||||
|
|
Ładowanie…
Reference in New Issue