Add cors stuff
This commit is contained in:
parent
560c974bf3
commit
9363f643f0
10 changed files with 116 additions and 49 deletions
21
README.md
21
README.md
|
|
@ -83,16 +83,35 @@ If you want to run the frontend in development mode with hot-reloading:
|
|||
```
|
||||
The frontend will be available at `http://localhost:5173`.
|
||||
|
||||
### Mobile/Network Access
|
||||
|
||||
To access the dev server from other devices (phones, tablets):
|
||||
|
||||
1. **Run setup script** - it auto-detects your IP:
|
||||
```bash
|
||||
./scripts/setup.sh
|
||||
```
|
||||
|
||||
2. **Update Authentik redirect URIs** to include your IP (e.g., `http://192.168.1.100:5173/callback`)
|
||||
|
||||
3. **Start dev server with host binding**:
|
||||
```bash
|
||||
npm run dev -- --host
|
||||
```
|
||||
|
||||
4. **Access from mobile** via `http://<your-ip>:5173`
|
||||
|
||||
## Configuration
|
||||
|
||||
Kaboot uses environment variables for configuration. Refer to `.env.example` for a complete list.
|
||||
|
||||
| Variable | Description | Default |
|
||||
|----------|-------------|---------|
|
||||
| `KABOOT_HOST` | Host IP/domain for network access | `localhost` |
|
||||
| `KABOOT_FRONTEND_PORT` | Port for the frontend dev server | `5173` |
|
||||
| `KABOOT_BACKEND_PORT` | Port for the Express backend | `3001` |
|
||||
| `AUTHENTIK_PORT_HTTP` | Port for Authentik web interface | `9000` |
|
||||
| `GEMINI_API_KEY` | Your Google Gemini API key | (Required) |
|
||||
| `CORS_ORIGIN` | Allowed origin for API requests | `http://localhost:5173` |
|
||||
| `PG_PASS` | PostgreSQL password for Authentik | (Generated) |
|
||||
| `AUTHENTIK_SECRET_KEY` | Secret key for Authentik | (Generated) |
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue