bozo-backend/main.py

21 lines
479 B
Python
Raw Normal View History

2023-06-03 10:50:05 -04:00
import flask
import database
2023-06-09 09:22:50 -04:00
import config
import home, login, panel, register, logout
2023-06-03 10:50:05 -04:00
app = flask.Flask(__name__)
2023-06-09 09:22:50 -04:00
app.secret_key = config.secret
2023-06-03 10:50:05 -04:00
2023-06-09 10:27:12 -04:00
@app.errorhandler(404)
def not_found(e):
return (flask.redirect("/"))
2023-06-03 10:50:05 -04:00
if (__name__ == "__main__"):
app.register_blueprint(home.page)
app.register_blueprint(login.page)
app.register_blueprint(panel.page)
app.register_blueprint(register.page)
2023-06-09 09:22:50 -04:00
app.register_blueprint(logout.page)
2023-06-04 06:56:04 -04:00
app.run(host="0.0.0.0")
2023-06-03 10:50:05 -04:00