from skeleton import create_app app = create_app() app.run(debug=True, host='0.0.0.0', port=5000)
# # Flask Skeleton # Copyright (c) Ryan Kadwell <*****@*****.**> # # setup wsgi application for site # # Author: Ryan Kadwell <*****@*****.**> # import sys import os BASEDIR = os.path.abspath(os.path.dirname(__file__)) # activate virtualenv activate_this = os.path.join(BASEDIR, ".virtualenv/2.7/bin/activate_this.py") execfile(activate_this, dict(__file__=activate_this)) if BASEDIR not in sys.path: sys.path.append(BASEDIR) from skeleton import create_app # set the wsgi application application = create_app()
from skeleton import create_app app = create_app() if __name__ == "__main__": app.run()
'hostname': DB_HOST, 'port': DB_PORT, 'dbname': DB_NAME, 'schema': DB_SCHEMA, }) # Explicitly specify what's a local request scheme = 'https' if USE_SSL else 'http' LOCAL_REQUEST = '%s://%s:%s/' % (scheme, CANONICAL_NAME, CANONICAL_PORT) ########NEW FILE######## __FILENAME__ = runserver from skeleton import create_app app = create_app(__name__) if app.config['DEBUG']: app.debug = True app.run(**app.config['WERKZEUG_OPTS']) ########NEW FILE######## __FILENAME__ = shell from skeleton import create_app app = create_app() ctx = app.test_request_context() ctx.push() from skeleton import db ses = db.session
from skeleton import create_app app = create_app(__name__) if app.config['DEBUG']: app.debug = True app.run(**app.config['WERKZEUG_OPTS'])