I’m looking to migrate HA from a standalone VM running HAOS under VMWare (Home Assistant 2023.8.0) to an instance installed via Docker on Ubuntu. Is this even possible? I don’t see any options on the docker instance to restore from backups made in my VM, although I’m able to make backups from within the docker instance.
You restore by opening the backup with, e.g. 7-zip:
Open “homeassistant.tar.gz”, then “homeassistant.tar” inside 7-zip.
Extract that content to the /config
inside your docker container.
Keep in mind that you lose the capability to use addons when going from HAOS to plain docker, though.
The “backup” systems are different between the two versions.
HAOS creates an entire backup of your entire HA system which I believe includes the actual version of HA that is running at the time. (I think) it also includes the HAOS Add-on configs. But it doesn’t actually backup the add-ons themselves (I think).
HA Container (which is what the version that runs in Docker is called) only backs up the contents of the configuration directory (where the configuration.yaml resides) along with all of the hidden subfolders in that directory. There are lots of things in a HAOS backup that aren’t needed to run HA Container (like all of the add-on configs and the Supervisor stuff since HA Container doesn’t have any of that). I also don’t think that the HA Container backup contains the running version of HA Core itself. It just backs up the config (I think)
HAOS allows for restoring of the backup. HA Container doesn’t have a restore option. You need to do that manually.
I personally use HA Container and have never used the backup utility since there is no easy way to restore from it and the added complexity of having to unzip a backup to copy the contents back to my configuration directory makes no sense.
I just manually copy the contents of that folder (including the hidden subfolders) to a backup location and if I need to restore I just copy them manually back to my config directory.
TLDR;
you cant restore a backup from HAOS to HA Container.
If you do copy your config over to HA Container don’t forget to copy the hidden subfolders as well.
Well, to be honest, It’s not bad for punctual backups, e.g. before an upgrade, if you are using sqlite.
Not more difficult to restore than my day-to-day backups (borg), actually.
Am I correct that the backup is zipped up when it’s created?
I also use Notepad++ to edit my config. Since that runs on my Windows PC with SCP into my system I use the search function in Notepad++ on my backup folder (which is stored on that same Windows PC) to find locations of configs I want to edit in my live system. So having access to an unzipped config directory is required for my workflow.
Targzipped, then tarred, but compressed, yes, for sure
Not sure I understand what you do, but I’m pretty sure that’s not usual for a backup
I just simply make a manual copy of my entire config directory (I use mariadb as my database so it’s not included) and store it unzipped on my windows PC (which then gets automatically backed up to the cloud via Crashplan).
Notepad++ edits my config in my config directory in HA directly via SCP.
BUT
Notepad++ doesn’t have the ability (or at least I haven’t found a way) to directly search my HA config directory for things (entity_id’s are mostly what I search for) so I use the not-zipped-up-backup of my config directory as a proxy for the live production config directory.
it may sound convoluted when trying to explain it but it’s fairly straight forward in practice.
Keyword is VsCode here
I tried VSCode for a bit and back then there were some oddities I didn’t like about it.
Notepad++ just works. Aside from the searching in my production config aspect. Which is pretty minor.