v1.4 - Login fixes, etc
This commit is contained in:
@@ -16,10 +16,10 @@ Create a virtual environment, install dependencies, then run:
|
||||
```bash
|
||||
cd backend
|
||||
pip install -e .
|
||||
uvicorn app.main:app --reload
|
||||
uvicorn app.main:app --host 0.0.0.0 --port 8000 --reload
|
||||
```
|
||||
|
||||
API docs will be available at `http://localhost:8000/docs`.
|
||||
API docs will be available at `http://localhost:8000/docs` on the server itself, or `http://<server-ip>:8000/docs` from another machine on the same network.
|
||||
|
||||
Useful commands:
|
||||
|
||||
@@ -41,7 +41,19 @@ npm install
|
||||
npm run dev
|
||||
```
|
||||
|
||||
Set `PUBLIC_API_BASE_URL` if the backend is not running on `http://localhost:8000`.
|
||||
The frontend dev server now binds to `0.0.0.0`, so you can open it from another machine at `http://<server-ip>:5173`.
|
||||
|
||||
By default the browser will call the backend on the same hostname and port `8000`. For example, if you open the UI at `http://10.0.0.124:5173`, it will call `http://10.0.0.124:8000`.
|
||||
|
||||
Useful environment variables:
|
||||
|
||||
```bash
|
||||
PUBLIC_API_PORT=8000
|
||||
PUBLIC_API_BASE_URL=http://10.0.0.124:8000
|
||||
CORS_ALLOW_ORIGINS=http://10.0.0.124:5173
|
||||
```
|
||||
|
||||
Set `PUBLIC_API_BASE_URL` when the API is on a different machine or behind a different public URL. Set `CORS_ALLOW_ORIGINS` or `CORS_ALLOW_ORIGIN_REGEX` if you want to narrow backend CORS more tightly than the default private-network allowance.
|
||||
|
||||
## Delivered in this MVP
|
||||
|
||||
|
||||
Reference in New Issue
Block a user