Make port configurable (default 5100)

- Port now set via config.json "port" field
- Aggregator reads PORT from environment variable
- Updated all docs and scripts to use port 5100

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
2026-02-02 23:24:24 -06:00
parent 5783a52cfa
commit 3e99780e87
6 changed files with 25 additions and 17 deletions

View File

@@ -30,7 +30,7 @@ pip install -r requirements.txt
python kao.py
```
Open http://localhost:5000 on your phone (use Fully Kiosk Browser for best results).
Open http://localhost:5100 on your phone (use Fully Kiosk Browser for best results).
## Status Faces
@@ -59,7 +59,7 @@ Edit `config.json` to enable/disable detectors and set thresholds:
```json
{
"aggregator_url": "http://localhost:5000",
"aggregator_url": "http://localhost:5100",
"detectors": [
{
"name": "disk_space",
@@ -80,7 +80,7 @@ Edit `config.json` to enable/disable detectors and set thresholds:
Create your own detector by POSTing events to the aggregator:
```bash
curl -X POST http://localhost:5000/event \
curl -X POST http://localhost:5100/event \
-H "Content-Type: application/json" \
-d '{"id": "my_check", "priority": 2, "message": "Something is wrong", "ttl": 120}'
```
@@ -92,7 +92,7 @@ curl -X POST http://localhost:5000/event \
Clear an event:
```bash
curl -X POST http://localhost:5000/clear \
curl -X POST http://localhost:5100/clear \
-d '{"id": "my_check"}'
```
@@ -103,10 +103,10 @@ Add webhook commands to your Home Assistant config:
```yaml
rest_command:
sentry_sleep:
url: "http://YOUR_SERVER:5000/sleep"
url: "http://YOUR_SERVER:5100/sleep"
method: POST
sentry_wake:
url: "http://YOUR_SERVER:5000/wake"
url: "http://YOUR_SERVER:5100/wake"
method: POST
```