# pylint: disable=multiple-statements,wrong-import-position,wrong-import-order from gevent.monkey import patch_all; patch_all() from gevent.pywsgi import WSGIServer import configparser from app import Application from routes import routes instance = Application.get_instance() app = instance.app api = instance.api api.register_blueprint(routes) config = configparser.ConfigParser() config.read('config/config.ini') port = int(config['server']['port']) or 5000 if __name__ == '__main__': http_Server = WSGIServer(("127.0.0.1", port), app) try: print(f"Server available on http://127.0.0.1:{port}/") print(f"View docs on http://127.0.0.1:{port}/swagger") http_Server.serve_forever() except KeyboardInterrupt: print("Keyboard interrupt received, stopping...")