From 74246ab6222cffb7bb2827ab9a3b26e9920b217a Mon Sep 17 00:00:00 2001 From: kkaris Date: Tue, 30 Apr 2024 15:06:20 -0700 Subject: [PATCH] MWE for how to set up app to be runnable with gunicorn --- gilda/app/app.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/gilda/app/app.py b/gilda/app/app.py index ba16192..323fac6 100644 --- a/gilda/app/app.py +++ b/gilda/app/app.py @@ -298,3 +298,10 @@ def _mount_home_redirect(app): def home_redirect(): """Redirect the home url to the API documentation.""" return redirect("/apidocs") + + +if __name__ == '__main__': + app = get_app() + app.run() +else: + gunicorn_app = get_app()