WebAdminPanel/app.py

22 lines
459 B
Python
Raw Normal View History

2022-08-29 12:10:44 -04:00
from flask import Flask
2022-11-26 12:22:25 -05:00
import logging
2022-08-29 12:10:44 -04:00
2022-11-26 12:22:25 -05:00
from apps.admin import admin as blueprint_admin
from apps.auth import auth as blueprint_auth
2022-08-29 12:10:44 -04:00
2022-11-26 12:22:25 -05:00
from config import secret_key
2022-08-29 12:10:44 -04:00
app = Flask(__name__)
2022-11-26 12:22:25 -05:00
app.secret_key = secret_key
2022-08-29 12:10:44 -04:00
app.register_blueprint(blueprint_auth)
app.register_blueprint(blueprint_admin)
if __name__ == '__main__':
2022-11-26 12:22:25 -05:00
from database import build_database
build_database()
2022-08-29 12:10:44 -04:00
logging.info("Build database models")
2022-12-02 16:12:00 -05:00
2022-08-29 12:10:44 -04:00
app.run(host="0.0.0.0")