From fce949603e5ad84240f94f82c465c0516653c9ee Mon Sep 17 00:00:00 2001 From: Untone Date: Thu, 25 Jan 2024 01:34:44 +0300 Subject: [PATCH] launch-fix --- Dockerfile | 2 +- main.py | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 294a211..471c5de 100644 --- a/Dockerfile +++ b/Dockerfile @@ -19,4 +19,4 @@ RUN apt-get update && apt-get install -y gcc curl && \ poetry install --no-dev # Run server.py when the container launches -CMD ["python", "main.py"] +CMD granian --interface asgi main:app diff --git a/main.py b/main.py index 2ea66a6..4af1f27 100644 --- a/main.py +++ b/main.py @@ -62,6 +62,7 @@ app.mount("/", GraphQL(schema, debug=True)) if __name__ == "__main__": Granian( target="main:app", + port=8888, interface=Interfaces.ASGI, reload=True ).serve()