Commit 00fb74d8 authored by Sylvain Thenault's avatar Sylvain Thenault Committed by Philippe Pepiot
Browse files

Add option telling gunicorn to detect forwarded protocol whatever the proxy's ip

parent ac349948
{% from "saemref/map.jinja" import saemref with context -%}
[program:saemref]
{% if saemref.instance.wsgi -%}
command=/home/{{ saemref.instance.user }}/venv/bin/gunicorn 'cubicweb.pyramid:wsgi_application()' --threads {{ saemref.instance.wsgi_threads }} --workers {{ saemref.instance.wsgi_workers }} --bind 0.0.0.0:{{ saemref.instance.port }}
command=/home/{{ saemref.instance.user }}/venv/bin/gunicorn 'cubicweb.pyramid:wsgi_application()' --forwarded-allow-ips * --threads {{ saemref.instance.wsgi_threads }} --workers {{ saemref.instance.wsgi_workers }} --bind 0.0.0.0:{{ saemref.instance.port }}
{% else -%}
command=/home/{{ saemref.instance.user }}/venv/bin/cubicweb-ctl pyramid -D {{ saemref.instance.name }}
{% endif -%}
......@@ -14,7 +14,7 @@ startsecs=10
[program:saemref-oai]
{% if saemref.instance.wsgi -%}
command=/home/{{ saemref.instance.user }}/venv/bin/gunicorn 'cubicweb.pyramid:wsgi_application()' --threads {{ saemref.instance.oai_threads }} --workers 1 --bind 0.0.0.0:{{ saemref.instance.oai_port }}
command=/home/{{ saemref.instance.user }}/venv/bin/gunicorn 'cubicweb.pyramid:wsgi_application()' --forwarded-allow-ips * --threads {{ saemref.instance.oai_threads }} --workers 1 --bind 0.0.0.0:{{ saemref.instance.oai_port }}
{% else -%}
command=/home/{{ saemref.instance.user }}/venv/bin/cubicweb-ctl pyramid -D {{ saemref.instance.name }}
{% endif -%}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment