realms-wiki/manage.py
Matthew Scragg 86f0549e44 WIP
2014-08-30 10:06:12 -05:00

19 lines
439 B
Python

from gevent import wsgi
from realms import config, app, manager
from flask.ext.script import Server
manager.add_command("runserver", Server(host="0.0.0.0", port=config.PORT))
@manager.command
def run():
"""
Run production ready server
"""
print "Server started. Env: %s Port: %s" % (config.ENV, config.PORT)
wsgi.WSGIServer(('', int(config.PORT)), app).serve_forever()
if __name__ == '__main__':
manager.run()