Generally speaking, thereās nothing specific to Home Assistant here.
Snapshots
Keep in mind, these are zfs snapshots proved by the zfs file system itself. This is not the same thing as snapshots you might here mentioned with Home-Assistant OS / Supervisor
I also made a blueprint for taking snapshots from Home Assistant (using TrueNAS API). Honestly, this is more proof of concept and could be greatly improved. Thereās a few steps involved so it must be created manually.
Even if you never took a snapshot or made some other backup, you config is at least separate from the jail. If the plugin failed, it can just be destroyed and recreated. After reinstalling, you simply add your mountpoint to the new plugin and configuration is restored.
Personally, I only ran the Plugin UPDATE, which to my understanding is basically the same as running pkg update && pkg upgrade
. In addition, Plugin UPDATE will also update the scripts I proved in the overlay (like the console menu). When the jail RELEASE needs upgraded, from 12.1
ā 12.2
for example, I would just re-installed the plugin.
Keep in mind TrueNAS SCALE is coming later this year. I suspect most people using this plugin will be migrating at some point in the future. Having your pluginās configuration on a separate dataset will make this much easier. In fact, Iāve already installed the latest ALPHA version of SCALE on my main server. Using docker-compose
with macvlan
, I managed to bring everything back up without a glitch. (I should mention, using docker-compose
on SCALE is not officially supported)
From inside the jail, you may find the config in the following locations
- ESPHome ā
/var/db/esphome
- Node-RED ā
/var/db/nodered
Itās basically rinse and repeat for these or any other plugins - You can make a separate dataset, copy the configuration to it, then add that dataset as a mount point back to the jail.
In my opinion, a key feature missing from the iocage plugin system, is the ability to mount an external dataset during installation.