1
0
Fork 0
Commit Graph

80 Commits (2cb65e3b71d917b7f3c41a251a171de34476360f)

Author SHA1 Message Date
bot ca80663c29 zwavejs2mqtt: Update to 9.17.0 2024-08-26 15:22:17 +00:00
bot d16cca534a zigbee2mqtt: Update to 1.39.1 2024-08-26 15:22:17 +00:00
bot d78f17f529 piper: Update to 1.5.0 2024-08-26 15:22:17 +00:00
bot 5a33f55d38 whisper: Update to 2.1.0 2024-08-26 15:22:16 +00:00
bot 39c576a6eb home-assistant: Update to 2024.8.3 2024-08-26 15:22:16 +00:00
Dustin 94b7168b1e home-assistant: Add restart MQTTMarionette script
There's obviously a bug or something in `mqttmarionette` because it
occasionally gets "stuck" in a state where it is running but does
not reconnect to the MQTT broker.  In such situations, it has to be
restarted (and even then it doesn't shut down correctly but has to
be killed with SIGKILL, usually).  I have been doing this manually, but
with this shell script and a corresponding "shell command" integration
in Home Assistant, it can be done automatically.  This is similar to
how Home Assistant restarts Mopidy on the living room stereo when it
gets into the same kind of state.
2024-08-23 09:24:46 -05:00
Dustin 5b34547730 h-a: Config Zigbee2MQTT w/ env vars
Zigbee2MQTT commits the cardinal sin of storing state in its
configuration file.  This means the file has to be writable and thus
stored in persistent storage rather than in a ConfigMap.  As a
consequence, making changes to the configuration when the application is
not running is rather difficult.  Case in point: when I added the
internal alias for _mqtt.pyrocufflink.blue_ pointing to the in-cluster
service, Zigbee2MQTT became unable to connect to the broker because it
was using the node port instead of the internal port.  Since it could
not connect to the broker, it refused to start, and thus the container
would not stay running long enough to fix the configuration to point
to the correct port.

Fortunately, Zigbee2MQTT also allows configuring settings via
environment variables, which can be managed with a ConfigMap.  Luckily,
the values read from environment variables override those from the
configuration file, so pointing to the correct broker port with the
environment variable was sufficient to allow the application to start.
2024-08-01 09:27:52 -05:00
Dustin 71ca910ef7 home-assistant: Add Tabitha's HLC calendar 2024-07-11 22:15:56 -05:00
Dustin 215b2c6975 home-assistant: Use external PostgreSQL server
Home Assistant uses PostgreSQL for recording the history of entity
states.  Since we had been using the in-cluster database server for
this, the data were migrated to the new external PostgreSQL server
automatically when the backup from the former was restored on the
latter.  It follows, then, that we can point Home Assistant to the
new server as well.

Home Assistant uses SQLAlchemy, which in turn uses _libpq_ via
_psycopg_, as a client for PostgreSQL.  It doesn't expose any
configuration parameters beyond the "database URL" directly, but we
can use the standard environment variables to specify the certificate
and private key for authentication.  In fact, the empty `postgresql://`
URL is sufficient, and indicates that _all_ of the connection parameters
should be taken from environment variables.  This makes specifying the
parameters for both the `wait-for-db` init container and the main
container take the exact same environment variables, so we can use
YAML anchors to share their definitions.
2024-07-02 18:16:05 -05:00
Dustin 31345bee7b home-assistant: Add Pool Time WebDAV calendar
I've created a _Pool Time_ calendar in Nextcloud that we can use to
mark when people are expected to be in the pool.  Using this, we can
configure the "someone is in the pool" alert not to fire during times
when we know people will be in the pool.  This will make it much less
annoying on HLC pool days.
2024-07-02 18:16:05 -05:00
Dustin 21e8ad2afd home-assistant: Add commands to control photoframe
The digital photo frame in the kitchen is powered by a server service,
which exposes a minimal HTTP API.  Using this API, we can e.g. advance
or backtrack the displayed photo.  Exposing `rest_command` services
for these operations allows us to add buttons to dashboards to control
the frame.
2024-06-26 18:29:49 -05:00
Dustin a4591950ba home-assistant: Add time-to-go timer to watch view
This way I can start the "time to go" timer from my watch as soon as
Brandon says he's leaving work.
2024-05-10 09:24:34 -05:00
Dustin ab916640cb home-assistant: Re-enable 17track sensor 2024-05-10 09:24:02 -05:00
Dustin 9fff21aae1 h-a: Remove roomba_is_downstairs template sensor
This sensor is now provided by a [Threshold][0] helper.

[0]: https://www.home-assistant.io/integrations/threshold/
2024-01-25 17:31:36 -06:00
Dustin 832dea2c7d h-a: Add init container to wait for PostgreSQL
When Home Assistant starts, if PostgreSQL is unavailable, it will come
up successfully, but without the history component.  It never tries
again to connect and enable the component.  This makes it difficult to
detect the problem and thus easy to overlook the missing functionality.
To avoid having extended periods of missing state history, we'll force
Home Assistant to wait for PostgreSQL to come up before starting.
2024-01-21 19:50:54 -06:00
Dustin 50beecf0a9 h-a: Increase startup probe failure threshold
Home Assistant can sometimes tke an unexpectedly long time to start up,
but it eventually does.
2024-01-21 19:32:35 -06:00
Dustin cb39b5a547 h-a: Update mobile apps notification group
Updating the notification group for the family's new mobile devices.
2024-01-21 19:30:50 -06:00
Dustin 8c605d0f9f home-assistant: Clean up restart_diddy_mopidy
Moving the shell command to an external script allows me to update it
without having to restart Home Assistant.

Including the SSH private key in the Secret not only allows it to be
managed by Kubernetes, but also works around a permissions issue when
storing the key in the `/config` volume.  The `ssh` command refuses to
use a key file with write permission for the group or other fields, but
the Kubelet sets `g=rw` when `fsGroup` is set on the pod.
2023-12-28 17:34:25 -06:00
Dustin b9d48d0df8 home-assistant: Add (back) event-snapshot.sh
When transitioning to the ConfigMap for maintaining Home Assistant YAML
configuration, I did not bring the `event-snapshot.sh` script because I
thought it was no longer in use.  It turns out I was mistaken; it is
used by the driveway camera alerts.
2023-12-28 17:09:01 -06:00
Dustin e56526600d home-assistant: Manage YAML files with ConfigMap
Editing `configuration.yaml` et al. using `vi` via `kubectl exec` is
rather tedious, since the version of `vi` in the *home-assistant*
container image is very rudimentary.  Thus, I think it would be better
to use a ConfigMap to store the manually-edited YAML files, so I can
edit them with my regular editor on my desktop.  For this to work, the
ConfigMap has to be mounted as a directory rather than as individual
files (using `subPath`), as otherwise the pod would have to be restarted
every time one of the files is updated.
2023-12-27 15:31:30 -06:00
Dustin ba070e74a9 home-assistant: Upgrade ZWaveJS UI to 9.1.2 2023-10-14 22:26:09 -05:00
Dustin 29ec26c369 home-assistant: Upgrade Zigbee2MQTT to 1.33.1 2023-10-14 22:25:56 -05:00
Dustin 29e51e3641 home-assistant: Upgrade to 2023.10.3 2023-10-14 22:20:26 -05:00
Dustin f3fcb92066 home-assistant: Set instance label for Argo CD
Argo CD wants every resource managed by an application to have that
application's name as the value of the `app.kubernetes.io/instance`
label.
2023-10-14 07:19:28 -05:00
Dustin 84091869f1 home-assistant: Migrate to Sealed Secrets
The only Secret object in the *home-assistant* namespace is the `passwd`
file for Mosquitto.
2023-10-13 19:07:21 -05:00
Dustin ec537b0230 home-assistant: Update to 2023.8.4
Also need to update Whisper and Piper because apparently the
communication protocol has changed.
2023-08-29 09:13:15 -05:00
Dustin ce898a7590 home-assistant: Update ZWaveJS2MQTT to v8.22.3 2023-07-20 18:02:03 -05:00
Dustin 81266d4ef9 home-assistant: Use subdomain for Zigbee/Z-wave UI
Having the Z-Wave and Zigbee admin interfaces exposed as sub-paths under
*homeassistant.pyrocufflink.blue* made it difficult to use Authelia.
Since I have a Firefox container tab specifically for Home Assistant,
the login redirect would open a new tab in a different container, since
Authelia is hosted at *auth.pyrocufflink.blue*.  In order to log in, I
would have to temporarily disable "designated sites only" for the Home
Assistant tab container.  Using subdomains for the admin interfaces
avoids this issue, since I can use a different container for them, one
that does not have the "designated sites only" setting, since I am less
worried about accidentally leaking data to sites on the Internet from
them.
2023-08-02 20:13:45 -05:00
Dustin 0cbda0fd73 home-assistant: Deploy Piper and Whisper
Piper is the new text-to-speech service for Home Assistant.  Whisper is
a speech-to-text service.  Together, these services, which communicate
with Home Assistant via the Wyoming protocol, provide the speech
interface to the new Home Assistant Voice Assistant feature.
2023-08-02 20:13:45 -05:00
Dustin a7eac14d39 home-assistant: Deploy Home Assistant
This commit adds resources for deploying the Home Assistant ecosystem
inside Kubernetes.  Home Assistant itself, as well as Mosquitto, are
just normal Pods, managed by StatefulSets, that can run anywhere.
ZWaveJS2MQTT and Zigbee2MQTT, on the other hand, have to run on a
special node (a Raspberry Pi), where the respective controllers are
attached.

The Home Assistant UI is exposed externally via an Ingress resource.
The MQTT broker is also exposed externally, using the TCP proxy feature
of *ingress-nginx*.  Additionally, the Zigbee2MQTT and ZWaveJS2MQTT
control panels are exposed via Ingress resources, but these are
protected by Authelia.
2023-07-24 17:53:58 -05:00