respect API_HOST & API_PORT env vars for dev

Using Vite's proxy option allows us to avoid CORS issues when the host
for Uvicorn doesn't match the host for Vite, e.g. localhost vs. 127.0.0.1.
This commit is contained in:
ducklet 2023-11-26 19:43:56 +01:00
parent 1f42538481
commit c63bee072f
4 changed files with 34 additions and 6 deletions

View file

@ -11,4 +11,5 @@ export UNWIND_PORT
exec uvicorn \
--host 0.0.0.0 \
--port "$UNWIND_PORT" \
--factory unwind:create_app
--factory \
unwind:create_app