diff --git a/wind/docker/esphome.sh b/wind/docker/esphome.sh new file mode 100755 index 0000000..edf32f3 --- /dev/null +++ b/wind/docker/esphome.sh @@ -0,0 +1,31 @@ +#!/bin/bash + +set -e + +up () { + docker network create pew-net || true + + # Exposed on port 6052 on pew-net + docker run \ + --detach \ + --name esphome \ + --restart unless-stopped \ + --env ESPHOME_DASHBOARD_USE_PING=true \ + --env USERNAME=paul \ + --env PASSWORD=paulwalko \ + --volume /bigdata/ha/esphome/config:/config:rw \ + --volume /etc/localtime:/etc/localtime:ro \ + --network pew-net \ + ghcr.io/esphome/esphome:stable +} + +down () { + docker stop esphome || true + docker rm esphome || true +} + +logs () { + docker logs --follow esphome +} + +$@ diff --git a/wind/docker/grafana.sh b/wind/docker/grafana.sh new file mode 100755 index 0000000..1507c27 --- /dev/null +++ b/wind/docker/grafana.sh @@ -0,0 +1,28 @@ +#!/bin/bash + +set -e + +up () { + docker network create pew-net || true + + # Exposed on port 3000 on pew-net + docker run \ + --detach \ + --name grafana \ + --restart unless-stopped \ + --user 1000 \ + --volume /bigdata/ha/grafana:/var/lib/grafana:rw \ + --network pew-net \ + grafana/grafana-oss:latest +} + +down () { + docker stop grafana || true + docker rm grafana || true +} + +logs () { + docker logs --follow grafana +} + +$@ diff --git a/wind/docker/ha.sh b/wind/docker/ha.sh new file mode 100755 index 0000000..36f27cb --- /dev/null +++ b/wind/docker/ha.sh @@ -0,0 +1,30 @@ +#!/bin/bash + +set -e + +up () { + docker network create pew-net || true + + # Exposed on port 8123 on pew-net + docker run \ + --detach \ + --name ha \ + --restart unless-stopped \ + --env TZ=America/New_York \ + --volume /bigdata/ha/config:/config:rw \ + --volume /run/dbus:/run/dbus:ro \ + --device /dev/serial/by-id/usb-ITEAD_SONOFF_Zigbee_3.0_USB_Dongle_Plus_V2_20231220080742-if00 \ + --network pew-net \ + ghcr.io/home-assistant/home-assistant:stable +} + +down () { + docker stop ha || true + docker rm ha || true +} + +logs () { + docker logs --follow ha +} + +$@ diff --git a/wind/docker/prometheus.sh b/wind/docker/prometheus.sh new file mode 100755 index 0000000..7305aac --- /dev/null +++ b/wind/docker/prometheus.sh @@ -0,0 +1,29 @@ +#!/bin/bash + +set -e + +up () { + docker network create pew-net || true + + # Exposed on port 9090 on pew-net + docker run \ + --detach \ + --name prometheus \ + --restart unless-stopped \ + --user 1000 \ + --volume /bigdata/ha/prometheus/prometheus.yml:/etc/prometheus/prometheus.yml:ro \ + --volume /bigdata/ha/prometheus/data:/prometheus:rw \ + --network pew-net \ + prom/prometheus:latest --config.file /etc/prometheus/prometheus.yml --storage.tsdb.path /prometheus --storage.tsdb.retention.time=1y +} + +down () { + docker stop prometheus || true + docker rm prometheus || true +} + +logs () { + docker logs --follow prometheus +} + +$@ diff --git a/wind/docker/zwavejs.sh b/wind/docker/zwavejs.sh new file mode 100755 index 0000000..ef66b36 --- /dev/null +++ b/wind/docker/zwavejs.sh @@ -0,0 +1,28 @@ +#!/bin/bash + +set -e + +up () { + docker network create pew-net || true + + # Exposed on port 8091 on pew-net + docker run \ + --detach \ + --name zwavejs \ + --restart unless-stopped \ + --volume /bigdata/ha/zwavejs/store:/usr/src/app/store:rw \ + --device /dev/serial/by-id/usb-Zooz_800_Z-Wave_Stick_533D004242-if00 \ + --network pew-net \ + zwavejs/zwave-js-ui:latest +} + +down () { + docker stop zwavejs || true + docker rm zwavejs || true +} + +logs () { + docker logs --follow zwavejs +} + +$@