Skip to content

Commit

Permalink
Use uvicorn as the web server
Browse files Browse the repository at this point in the history
  • Loading branch information
jacebrowning committed Sep 12, 2020
1 parent 6bf4f05 commit 2e4e016
Show file tree
Hide file tree
Showing 5 changed files with 77 additions and 45 deletions.
4 changes: 4 additions & 0 deletions Makefile
Expand Up @@ -93,6 +93,10 @@ watch: install
###############################################################################
# Delivery Tasks

.PHONY: run-production
run-production: install
PORT=5000 poetry run heroku local

.PHONY: promote
promote: install
SITE=https://staging-api.memegen.link poetry run pytest scripts --verbose --no-cov
Expand Down
2 changes: 1 addition & 1 deletion Procfile
@@ -1 +1 @@
web: python app/views.py
web: uvicorn app.views:app --port=${PORT} --no-access-log
103 changes: 64 additions & 39 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions pyproject.toml
Expand Up @@ -26,6 +26,7 @@ spongemock = "~0.3.4"

# Production
bugsnag = "*"
uvicorn = "~0.11.8"

[tool.poetry.dev-dependencies]

Expand Down
12 changes: 7 additions & 5 deletions requirements.txt
Expand Up @@ -7,18 +7,19 @@ cached-property==1.5.1
certifi==2020.6.20
chardet==3.0.4
classproperties==0.1.3
click==7.1.2
datafiles==0.11b4
h11==0.9.0
h2==3.2.0
hpack==3.0.0
hstspreload==2020.9.2
hstspreload==2020.9.9
httptools==0.1.1
httpx==0.11.1
hyperframe==5.2.0
idna==2.10
minilog==2.0b2
minilog==2.0
multidict==4.7.6
parse==1.17.0
parse==1.18.0
pillow==7.2.0
pyperclip==1.8.0
pyyaml==5.3.1
Expand All @@ -34,9 +35,10 @@ sniffio==1.1.0
spongemock==0.3.4
tomlkit==0.5.11
typing-extensions==3.7.4.3
ujson==3.1.0; sys_platform != "win32" and implementation_name == "cpython"
ujson==3.2.0; sys_platform != "win32" and implementation_name == "cpython"
urllib3==1.25.10
uvloop==0.14.0; sys_platform != "win32" and implementation_name == "cpython"
uvicorn==0.11.8
uvloop==0.14.0; sys_platform != "win32" and implementation_name == "cpython" or sys_platform != "win32" and sys_platform != "cygwin" and platform_python_implementation != "PyPy"
webob==1.8.6
websockets==8.1
yarl==1.5.1

0 comments on commit 2e4e016

Please sign in to comment.