haldis/app/passenger_wsgi.py
mcbloch d0863325a5
Restructuring the codebase!
But for real, it's a real shitstorm in there.
- Added context by making the init go through a function
  and not implicitly happen via imports
- Fixup all context and contextless function mixups
- splitup the models in sensible different files
- give the dump of view functions in views/__init__.py their own file
- add all routes via blueprints, not half of them
- move the slack notifications function and class to its own file,
    no idea what it was doing in a views file in the first place.
2019-08-28 03:46:04 +02:00

18 lines
354 B
Python

#!/usr/bin/env python
import os
import sys
from app import create_app
INTERP = os.path.expanduser("~/env/bin/python")
if sys.executable != INTERP:
os.execl(INTERP, INTERP, *sys.argv)
sys.path.append(os.getcwd())
application = create_app()
# For running on the server with passenger etc
if __name__ == "__main__":
application.run(port=8000)