Attempt to set up gunicorn
Signed-off-by: Patrick Uiterwijk <patrick@puiterwijk.org>
This commit is contained in:
parent
ab15105711
commit
f81afda358
2 changed files with 18 additions and 1 deletions
|
@ -80,6 +80,20 @@ data:
|
||||||
</Directory>
|
</Directory>
|
||||||
app_start.sh: |-
|
app_start.sh: |-
|
||||||
set -xe
|
set -xe
|
||||||
|
python /etc/fas/app_gunicorn.py --bind :8000 --chdir /app app
|
||||||
|
app_gunicorn.py: |-
|
||||||
|
# We need a custom gunicorn script because we need to inject various requires
|
||||||
|
import __main__
|
||||||
|
__main__.__requires__ = []
|
||||||
|
__main__.__requires__.append('SQLAlchemy >= 0.5, <= 0.6')
|
||||||
|
__main__.__requires__.append('TurboGears[future]')
|
||||||
|
__main__.__requires__.append('gunicorn==18.0')
|
||||||
|
import sys
|
||||||
|
from pkg_resources import load_entry_point
|
||||||
|
if __name__ == '__main__':
|
||||||
|
sys.exit(
|
||||||
|
load_entry_point('gunicorn==18.0', 'console_scripts', 'gunicorn')()
|
||||||
|
)
|
||||||
fas_sync_cert.pem: |-
|
fas_sync_cert.pem: |-
|
||||||
{{ lookup('file', '{{ roles_path }}/fas_server/files/ipa.{{env}}.pem') | indent() }}
|
{{ lookup('file', '{{ roles_path }}/fas_server/files/ipa.{{env}}.pem') | indent() }}
|
||||||
fas-log.cfg: |-
|
fas-log.cfg: |-
|
||||||
|
|
|
@ -34,9 +34,12 @@ spec:
|
||||||
rm -f /usr/lib/python2.6/site-packages/fas/config/log.cfg && \
|
rm -f /usr/lib/python2.6/site-packages/fas/config/log.cfg && \
|
||||||
ln -sf /etc/fas/krb5.conf /etc/krb5.conf && \
|
ln -sf /etc/fas/krb5.conf /etc/krb5.conf && \
|
||||||
ln -sf /etc/fas/fas.cfg /etc/fas.cfg && \
|
ln -sf /etc/fas/fas.cfg /etc/fas.cfg && \
|
||||||
ln -sf /etc/fas/fas-log.cfg /usr/lib/python2.6/site-packages/fas/config/log.cfg
|
ln -sf /etc/fas/fas-log.cfg /usr/lib/python2.6/site-packages/fas/config/log.cfg && \
|
||||||
|
mkdir -p /app && \
|
||||||
|
ln -sf /usr/sbin/fas.wsgi /app/app.py
|
||||||
|
|
||||||
EXPOSE 8080
|
EXPOSE 8080
|
||||||
|
EXPOSE 8000
|
||||||
ENTRYPOINT bash
|
ENTRYPOINT bash
|
||||||
type: Dockerfile
|
type: Dockerfile
|
||||||
strategy:
|
strategy:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue