mirror of
https://github.com/GSA/notifications-admin.git
synced 2025-12-10 15:13:40 -05:00
remove wsgi.py - always serve with whitenoise
We're now running our app as a wsgi app locally, so don't need to distinguish between the two processes by having wsgi and application.py whitenoise just serves static files nicely - we don't lose anything by doing that locally.
This commit is contained in:
@@ -1,6 +1,15 @@
|
||||
import os
|
||||
|
||||
from flask import Flask
|
||||
from whitenoise import WhiteNoise
|
||||
|
||||
from app import create_app
|
||||
|
||||
PROJECT_ROOT = os.path.dirname(os.path.abspath(__file__))
|
||||
STATIC_ROOT = os.path.join(PROJECT_ROOT, 'app', 'static')
|
||||
STATIC_URL = 'static/'
|
||||
|
||||
app = Flask('app')
|
||||
|
||||
create_app(app)
|
||||
application = WhiteNoise(app, STATIC_ROOT, STATIC_URL)
|
||||
|
||||
Reference in New Issue
Block a user