aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorNavan Chauhan <navanchauhan@gmail.com>2021-06-05 18:55:06 +0530
committerNavan Chauhan <navanchauhan@gmail.com>2021-06-05 18:55:06 +0530
commit760437326d499427cc40ffd7db6482d65e945338 (patch)
tree767a73b15eb285211587898b9f3a42f0c9a6f34f /Makefile
parent0ece5d57c780b9c5500ae103eb036aeb83e5c87e (diff)
add uvicorn command
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile12
1 files changed, 11 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index 7c0a3bb..67475a1 100644
--- a/Makefile
+++ b/Makefile
@@ -30,4 +30,14 @@ cert-create:
.PHONY: dev-ssl
dev-ssl:
cd app && ln -sf config_dev.py config.py
- FLASK_APP=app python -m flask run --reload --debugger --cert=cert.pem --key=key.pem \ No newline at end of file
+ FLASK_APP=app python -m flask run --reload --debugger --cert=cert.pem --key=key.pem
+
+## Gunicorn Server with Uvicorn worker for FastAPI Support
+.PHONY: gunicorn
+gunicorn:
+ python -m gunicorn -w 1 api:app -k uvicorn.workers.UvicornWorker -b "0.0.0.0:8080" --reload
+
+## Uvicorn Server
+.PHONY: uvicorn
+uvicoen:
+ python -m uvicorn api:app --reload \ No newline at end of file