Arrange custom scripts for running applications.
This commit is contained in:
parent
0f76d1acad
commit
5c56aeca09
6
Pipfile
6
Pipfile
@ -29,5 +29,7 @@ pytest = "*"
|
|||||||
tox = "*"
|
tox = "*"
|
||||||
|
|
||||||
[scripts]
|
[scripts]
|
||||||
dev = "python dev.py"
|
devserver = "bash -c 'FLASK_APP=scripts/devserver.py flask run'"
|
||||||
prod = "gunicorn --worker-class eventlet -w 1 wsgi:app"
|
devshell = "bash -c 'FLASK_APP=scripts/devshell.py flask shell'"
|
||||||
|
prodserver = "gunicorn --worker-class eventlet -w 1 wsgi:app"
|
||||||
|
prodshell = "bash -c 'FLASK_APP=wsgi.py flask shell'"
|
||||||
|
0
scripts/__init__.py
Normal file
0
scripts/__init__.py
Normal file
@ -1,7 +1,7 @@
|
|||||||
"""Expose a development application."""
|
"""Run a development application."""
|
||||||
|
|
||||||
from xppl.app import create_app
|
|
||||||
from xppl.socketio import socketio
|
from xppl.socketio import socketio
|
||||||
|
from xppl.app import create_app
|
||||||
|
|
||||||
app = create_app('xppl.config.Development')
|
app = create_app('xppl.config.Development')
|
||||||
|
|
5
scripts/devshell.py
Normal file
5
scripts/devshell.py
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
"""Run a development shell."""
|
||||||
|
|
||||||
|
from xppl.app import create_app
|
||||||
|
|
||||||
|
app = create_app('xppl.config.Development')
|
Loading…
Reference in New Issue
Block a user