try new procfile
This commit is contained in:
parent
e0942fe459
commit
2f146c96f6
2 changed files with 9 additions and 19 deletions
2
Procfile
2
Procfile
|
@ -1,2 +1,2 @@
|
|||
web: gunicorn server:run
|
||||
web: gunicorn --worker-class socketio.sgunicorn.GeventSocketIOWorker --log-file=- server:app
|
||||
release: python manage.py db upgrade
|
26
server.py
26
server.py
|
@ -19,24 +19,14 @@ def api_home():
|
|||
response = {"message": "hello world"}
|
||||
return jsonify(response)
|
||||
|
||||
app = create_app()
|
||||
register_api_endpoints(app)
|
||||
app.register_blueprint(server)
|
||||
migrate = Migrate(app, db)
|
||||
# added 10/14
|
||||
DATABASE_URL = os.environ['DATABASE_URL']
|
||||
conn = psycopg2.connect(DATABASE_URL, sslmode='require')
|
||||
|
||||
if __name__ == '__main__':
|
||||
app = create_app()
|
||||
register_api_endpoints(app)
|
||||
app.register_blueprint(server)
|
||||
migrate = Migrate(app, db)
|
||||
# added 10/14
|
||||
DATABASE_URL = os.environ['DATABASE_URL']
|
||||
conn = psycopg2.connect(DATABASE_URL, sslmode='require')
|
||||
|
||||
socketio.run(app, debug=False)
|
||||
|
||||
def run:
|
||||
app = create_app()
|
||||
register_api_endpoints(app)
|
||||
app.register_blueprint(server)
|
||||
migrate = Migrate(app, db)
|
||||
# added 10/14
|
||||
DATABASE_URL = os.environ['DATABASE_URL']
|
||||
conn = psycopg2.connect(DATABASE_URL, sslmode='require')
|
||||
|
||||
socketio.run(app, debug=False)
|
||||
|
|
Loading…
Reference in a new issue