from flask import Flask
from routes.face_routes import face_bp
import os

def create_app():
    app = Flask(__name__)
    app.register_blueprint(face_bp)
    return app

if __name__ == "__main__":
    debug_mode = os.getenv("DEBUG", "True").lower() == "true"
    app = create_app()
    app.run(host="0.0.0.0", port=5006, debug=debug_mode)
