Addon Bundle with Docker

I’ve had issues on one of my installations with intermittent internet connectivity. I believe that causes some issues during startup with the docker pieces as it can’t go grab the addons properly. When running on a non-docker install I used to just do apt install openhab-addons and it would fix this. Is there a mechanism to do this on the docker side so that the addons kar is pulled down and saved locally when I update the container?

You can mount a volume to /etc/cont-init.d inside the container and all the scripts you put there will run before anything else. You can install the add-ons that way. But keep in mind that the openHAB inside the container uses a manual install, not an apt install, so your script will need to download and place the kar file into the addons folder.

You could also just mount a volume to /openhab/addons and just download and drop the kar file there, but you’ll have to remember to download and replace that every time you upgrade.

I hadn’t even thought to go that route. I already have addons inside the userdata mount, I’ll just pull the kar and drop it in there. Thanks!

Are the UIs included in the addons kar?

Yes. Marketplace is not though, only official add-ons. But all official add-ons are in the add-ons kar file.

Perfect, thank you.