mirror of
https://github.com/GSA/notifications-api.git
synced 2025-12-09 14:42:24 -05:00
Initial code added for models and services not functional yet. Bootstrap and migrations added for db.
This commit is contained in:
@@ -5,14 +5,18 @@ from __future__ import print_function
|
||||
import os
|
||||
|
||||
from flask.ext.script import Manager, Server
|
||||
from flask.ext.migrate import Migrate, MigrateCommand
|
||||
|
||||
from app import create_app
|
||||
from app import create_app, db
|
||||
|
||||
application = create_app(os.getenv('NOTIFY_API_ENVIRONMENT') or 'development')
|
||||
manager = Manager(application)
|
||||
port = int(os.environ.get('PORT', 6011))
|
||||
manager.add_command("runserver", Server(host='0.0.0.0', port=port))
|
||||
|
||||
migrate = Migrate(application, db)
|
||||
manager.add_command('db', MigrateCommand)
|
||||
|
||||
|
||||
@manager.command
|
||||
def list_routes():
|
||||
|
||||
Reference in New Issue
Block a user