fix: point RPi management at current address (192.168.81.147)
This commit is contained in:
@@ -1,7 +1,7 @@
|
|||||||
# rpi-zigbee-stack — Docker Compose stack management for RPi 3B+
|
# rpi-zigbee-stack — Docker Compose stack management for RPi 3B+
|
||||||
|
|
||||||
set export
|
set export
|
||||||
RPI := "root@192.168.9.147"
|
RPI := "root@192.168.81.147"
|
||||||
COMPOSE := "/root/compose.yaml"
|
COMPOSE := "/root/compose.yaml"
|
||||||
|
|
||||||
# Default: show stack status
|
# Default: show stack status
|
||||||
@@ -66,21 +66,35 @@ zb-devices:
|
|||||||
|
|
||||||
# Open Node-RED editor
|
# Open Node-RED editor
|
||||||
nr-editor:
|
nr-editor:
|
||||||
xdg-open http://192.168.9.147:1880 2>/dev/null || open http://192.168.9.147:1880 2>/dev/null
|
xdg-open http://192.168.81.147:1880 2>/dev/null || open http://192.168.81.147:1880 2>/dev/null
|
||||||
|
|
||||||
# Open Node-RED dashboard
|
# Open Node-RED dashboard
|
||||||
nr-dashboard:
|
nr-dashboard:
|
||||||
xdg-open http://192.168.9.147:1880/ui 2>/dev/null || open http://192.168.9.147:1880/ui 2>/dev/null
|
xdg-open http://192.168.81.147:1880/ui 2>/dev/null || open http://192.168.81.147:1880/ui 2>/dev/null
|
||||||
|
|
||||||
# ---- Maintenance ----
|
# ---- Maintenance ----
|
||||||
|
|
||||||
# Sync compose.yaml and configs to RPi
|
# Sync compose.yaml and configs to RPi (backs up live files first)
|
||||||
sync:
|
sync:
|
||||||
|
ssh {{RPI}} "cp /root/compose.yaml /root/compose.yaml.bak.$$(date +%s) 2>/dev/null || true"
|
||||||
|
ssh {{RPI}} "cp /root/mosquitto/config/mosquitto.conf /root/mosquitto/config/mosquitto.conf.bak.$$(date +%s) 2>/dev/null || true"
|
||||||
|
ssh {{RPI}} "cp /root/zigbee2mqtt/configuration.yaml /root/zigbee2mqtt/configuration.yaml.bak.$$(date +%s) 2>/dev/null || true"
|
||||||
scp compose.yaml {{RPI}}:/root/compose.yaml
|
scp compose.yaml {{RPI}}:/root/compose.yaml
|
||||||
scp mosquitto.conf {{RPI}}:/root/mosquitto/config/mosquitto.conf
|
scp mosquitto.conf {{RPI}}:/root/mosquitto/config/mosquitto.conf
|
||||||
scp zigbee2mqtt.yaml {{RPI}}:/root/zigbee2mqtt/configuration.yaml
|
scp zigbee2mqtt.yaml {{RPI}}:/root/zigbee2mqtt/configuration.yaml
|
||||||
@echo "Configs synced to RPi. Run 'just restart' to apply."
|
@echo "Configs synced to RPi. Run 'just restart' to apply."
|
||||||
|
|
||||||
|
# Apply boot-resilience hardening (fsck auto-repair, watchdog, stack autostart)
|
||||||
|
harden:
|
||||||
|
ssh {{RPI}} "cp /root/harden-boot.sh /root/harden-boot.sh.bak.$$(date +%s) 2>/dev/null || true"
|
||||||
|
scp scripts/harden-boot.sh {{RPI}}:/root/harden-boot.sh
|
||||||
|
scp scripts/kuma-online.sh {{RPI}}:/root/kuma-online.sh
|
||||||
|
ssh {{RPI}} "bash /root/harden-boot.sh"
|
||||||
|
|
||||||
|
# Push an immediate "online" heartbeat to Kuma from the RPi
|
||||||
|
online:
|
||||||
|
ssh {{RPI}} "bash /usr/local/sbin/kuma-online.sh"
|
||||||
|
|
||||||
# Full redeploy: sync configs + restart
|
# Full redeploy: sync configs + restart
|
||||||
redeploy: sync restart
|
redeploy: sync restart
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user