fixed webui

This commit is contained in:
Matthias Hinrichs
2026-01-29 22:24:24 +01:00
parent 10de822d44
commit 92a77ee944
3 changed files with 38 additions and 6 deletions
+32 -4
View File
@@ -8,10 +8,38 @@ Dies ist der Client-Teil des Home-Bro Projekts, der auf einem Raspberry Pi läuf
- Bildaufnahme (Snapshot) via Webcam
- Upload zum Brain (FastAPI)
- Audio-Wiedergabe der sarkastischen Kommentare
- Web-UI zur Konfiguration (Brain URL, Wake-Word, Picovoice Key)
## Installation
1. Repository klonen.
2. `pip install -r requirements.txt`
3. `.env` Datei basierend auf `.env.example` erstellen.
4. Starten: `python app/main.py`
1. **Repository klonen**:
```bash
git clone git@git.hnrx.net:homelab/home-bro-client.git
cd home-bro-client
```
2. **Virtuelle Umgebung erstellen & aktivieren**:
```bash
python3 -m venv venv
source venv/bin/activate
```
3. **Abhängigkeiten installieren**:
```bash
pip install -r requirements.txt
```
4. **Konfiguration**:
`.env` Datei basierend auf `.env.example` erstellen oder später über das Web-UI konfigurieren.
5. **Starten**:
```bash
python app/main.py
```
6. **Web-UI aufrufen**:
Öffne `http://<pi-ip>:8080` in deinem Browser.
+4
View File
@@ -29,6 +29,10 @@ class Config(BaseModel):
async def read_index():
return FileResponse("static/index.html")
@app.get("/favicon.ico", include_in_schema=False)
async def favicon():
return FileResponse("static/index.html") # Or just return 204
@app.get("/config")
async def get_config():
return {
+2 -2
View File
@@ -4,7 +4,7 @@
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Home-Bro Client | Satellite Config</title>
<link rel="stylesheet" href="style.css" />
<link rel="stylesheet" href="/static/style.css" />
<link rel="preconnect" href="https://fonts.googleapis.com" />
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
<link
@@ -83,6 +83,6 @@
<div id="toast" class="toast">Gespeichert!</div>
</main>
<script src="script.js"></script>
<script src="/static/script.js"></script>
</body>
</html>