MVP: add dashboard and Home Assistant add-on
This commit is contained in:
19
addon/Dockerfile
Normal file
19
addon/Dockerfile
Normal file
@@ -0,0 +1,19 @@
|
||||
FROM python:3.13-slim
|
||||
|
||||
ENV PYTHONDONTWRITEBYTECODE=1 \
|
||||
PYTHONUNBUFFERED=1 \
|
||||
PIP_NO_CACHE_DIR=1
|
||||
|
||||
RUN apt-get update \
|
||||
&& apt-get install -y --no-install-recommends git \
|
||||
&& git clone --depth 1 --branch main \
|
||||
http://192.168.6.31:3000/pino/sillyhome-next.git /app \
|
||||
&& python -m pip install --upgrade pip \
|
||||
&& python -m pip install /app \
|
||||
&& rm -rf /var/lib/apt/lists/* /app/.git
|
||||
|
||||
COPY run.sh /run.sh
|
||||
RUN chmod 0755 /run.sh
|
||||
|
||||
EXPOSE 8000
|
||||
CMD ["/run.sh"]
|
||||
21
addon/config.yaml
Normal file
21
addon/config.yaml
Normal file
@@ -0,0 +1,21 @@
|
||||
name: SillyHome Next
|
||||
version: "0.3.0"
|
||||
slug: sillyhome_next
|
||||
description: Lokale HA-Analyse, Vorhersagen und sichere Automation-Entwürfe
|
||||
url: http://192.168.6.31:3000/pino/sillyhome-next
|
||||
arch:
|
||||
- amd64
|
||||
startup: application
|
||||
boot: auto
|
||||
init: false
|
||||
ingress: true
|
||||
ingress_port: 8000
|
||||
panel_icon: mdi:home-analytics
|
||||
homeassistant_api: true
|
||||
hassio_api: false
|
||||
auth_api: false
|
||||
options: {}
|
||||
schema: {}
|
||||
map:
|
||||
- type: addon_config
|
||||
read_only: false
|
||||
11
addon/run.sh
Normal file
11
addon/run.sh
Normal file
@@ -0,0 +1,11 @@
|
||||
#!/bin/sh
|
||||
set -eu
|
||||
|
||||
export SILLYHOME_HA_URL="${SILLYHOME_HA_URL:-http://supervisor/core}"
|
||||
export SILLYHOME_HA_TOKEN="${SILLYHOME_HA_TOKEN:-${SUPERVISOR_TOKEN:-}}"
|
||||
export SILLYHOME_MODEL_STORE=/data/models
|
||||
export SILLYHOME_AUTOMATION_STORE=/data/automations
|
||||
|
||||
mkdir -p "$SILLYHOME_MODEL_STORE" "$SILLYHOME_AUTOMATION_STORE"
|
||||
exec uvicorn app.main:app --app-dir /app --host 0.0.0.0 --port 8000 \
|
||||
--proxy-headers --forwarded-allow-ips='*'
|
||||
Reference in New Issue
Block a user