How to merge hassio-installer with existing docker-compose?

I’m looking to migrated from my Rpi3 Hassio install to a Ubuntu/Docker Hassio install on my existing Plex box. I successfully ran the hassio-installer script and have the hassio-supervisor, home-assistant, and hassio-dns containers running.

I’m not clear how I can integrate the hassio docker ecosystem into my existing docker-compose file. I also need to add my zwave usb stick (aeotec) to my hassio docker image and repoint my docker hassio to my existing /config folder (located in /home/mastakebob/hassioConfig).

Adding the zwave stick and re-pointing to my config directory should be pretty straight forward once I get my docker-compose figured out, but I’m not able to find any info on how to integrate the hassio-installer setup into my docker-compose file.

Can anyone point me in the right direction?

All USB devices are passed through already. You don’t need to modify anything for it to work.

You don’t.

The services you installed on your host manage the supervisor and the supervisor manages hassio. You don’t integrate these into compose.

If you want to move the config directory, just edit the services to point to the preferred location

1 Like

Fredrike in SynoCommunity/spksrc Has done great work to bring hassio to the Synology NAS’s docker env. There’s a setup at,L38 that might hint at a docker-compose Config, I might be able to convert it for you if you’re interested. Really, per @flamingm0e , the magic is running the correct and let it manage for you.

If you (the next reader, not the OP) are running on a Synology, look at the hassio package to do the work for you :slight_smile:

Awesome, that makes things easy. Got my system migrated over, excited to retire the Rpi (required a restart every few weeks and had slow restarts).

How do I ‘edit the services’ to point to the preferred config location? Does that require re-executing the hassio-installer script and resetting up my install? Or can I redirect the location via editing some config files?

I’d like to have all my docker config folders in the same location rather than having hassio in /usr/share/hassio/homeassistant…

Yea, I’d prefer to have it all in docker-compose for future maintainability (I know I’m going to forget all of this in 6 months and then have to do major reconstruction and forget that hassio is controlled differently than the rest of docker). But I got it up and running, so I’ll be happy w/ it for now…

If you read the script, you will see it creates some service files and some scripts that start the supervisor.

Ah, K. So in /usr/sbin/hassio.supervisor, looks like I can change

DATA="$(jq --raw-output '.data // "/usr/share/hassio"' ${CONFIG_FILE})"


DATA="$(jq --raw-output '.data // "/home/mastakebob/hassioConfig"' ${CONFIG_FILE})"

and that should redirect HA to look in my hassioConfig folder for its info rather than the /usr/share/hassio/homeassistant default.

I actually did that as a test a while back to see if I could change the config location.

It worked for the general install & config stuff but when I tried to install add-ons I kept getting errors (I don’t remember the details). I’m not sure if was related to the change in config location generally or because the supervisor expected different user permissions at the different config locations or what it was. Since it was just a test of concept I didn’t spend much time on it & then uninstalled it.

I’ll tell you what tho. That supervisor service is pretty “sticky”. Every time I removed the hassio container the supervisor re-added it immediately. If I tried to remove the supervisor container the supervisor service would re-install it as well. To disable the supervisor I had to disable the supervisor service that gets started when you run the install script.

let us know how you do at re-locating the config directory. If you’re successful I may try again at some point. Or maybe I won’t and just leave a running system lie. :wink:

1 Like

Hmmm, that doesn’t bode well. I think I’ll follow your path and let a working system lie.

I’m putting a symlink in my normal container’s config folder location pointing to the /usr/share/hassio location, so hopefully that’ll be enough to jog my memory of this whenever something breaks and I have to mess around in the file system.

Actually, that was the other thing i had thought about doing just recently. I just have to remind myself how to create symlinks. :smile:

1 Like