Blame rundocserver.py

Pierre-Yves Chibon f8556c
#!/usr/bin/env python2
Pierre-Yves Chibon f8556c
Pierre-Yves Chibon f8556c
# These two lines are needed to run on EL6
Pierre-Yves Chibon f8556c
__requires__ = ['SQLAlchemy >= 0.8', 'jinja2 >= 2.4']
Pierre-Yves Chibon f8556c
import pkg_resources
Pierre-Yves Chibon f8556c
Pierre-Yves Chibon f8556c
import sys
Pierre-Yves Chibon f8556c
from werkzeug.contrib.profiler import ProfilerMiddleware
Pierre-Yves Chibon f8556c
Pierre-Yves Chibon f8556c
from pagure import APP
Pierre-Yves Chibon f8556c
from pagure.docs_server import APP
Pierre-Yves Chibon f8556c
APP.debug = True
Pierre-Yves Chibon f8556c
Pierre-Yves Chibon f8556c
if '--profile' in sys.argv:
Pierre-Yves Chibon f8556c
    APP.config['PROFILE'] = True
Pierre-Yves Chibon f8556c
    APP.wsgi_app = ProfilerMiddleware(APP.wsgi_app, restrictions=[30])
Pierre-Yves Chibon f8556c
Pierre-Yves Chibon f8556c
APP.run(port=5001)