mirror of
https://github.com/YunoHost/tartiflette.git
synced 2024-09-03 20:06:08 +02:00
16 lines
346 B
Python
16 lines
346 B
Python
from flask import Flask
|
|
from flask_sqlalchemy import SQLAlchemy
|
|
|
|
db = SQLAlchemy()
|
|
|
|
def create_app():
|
|
|
|
from .app import app
|
|
|
|
SQLALCHEMY_DATABASE_URI = 'sqlite:///./db.sqlite'
|
|
app.config['SQLALCHEMY_DATABASE_URI'] = SQLALCHEMY_DATABASE_URI
|
|
app.config['SQLALCHEMY_TRACK_MODIFICATIONS'] = False
|
|
db.init_app(app)
|
|
|
|
return app
|
|
|