HASS running on a Synology docker not updating

Hi all,

I have a HASS instance running on docker, and seems the update procedure is not working for me.

What I do when I want to update is:

  1. Shutdown the HA docker container.
  2. “sudo docker pull homeassistant/home-assistant:latest”, which seems to work fine as shows some “Pull completes”.

admin@Synology:~$ sudo docker pull homeassistant/home-assistant:latest
latest: Pulling from homeassistant/home-assistant
55cbf04beb70: Already exists
1607093a898c: Already exists
9a8ea045c926: Already exists
d4eee24d4dac: Already exists
b59856e9f0ab: Already exists
b023afffd10b: Already exists
4d4eb448d315: Already exists
c4eb58602129: Already exists
598629fb90fc: Already exists
d864b050552d: Pull complete
0c898f5f2475: Pull complete
38e48c298eb5: Pull complete
7fa02ad78b8b: Pull complete
dc311abb0297: Pull complete
99fe97f432a6: Pull complete
Digest: sha256:45a19ffe5ab45c2e69d81f6f40e28349fe381d26e11d5268029b0c100cdfd7bc
Status: Downloaded newer image for homeassistant/home-assistant:latest

  1. Starting the container again.

After that, if I check on HA I see version is 0.75.3 instead of a newer one.

Am I doing something wrong? Can this be something related to the specific environment where I run this? (Synology, through the docker GUI interface).

Thanks a lot.

You need to remove the previous container and create a new one.

docker rm container_name

^ Removes the old container. Then create using your docker run command. An easier way is to create a docker-compose.yaml file.

Thanks for that. In case anyone is interested, this is the configuration that worked for me on a Synology:

version: ‘3’
services:
homeassistant:
container_name: home-assistant
restart: unless-stopped
image: homeassistant/home-assistant
volumes:
- /volume1/docker/homeassistant/config:/config
- /etc/localtime:/etc/localtime:ro
devices:
- /dev/ttyACM0:/dev/ttyACM0
restart: always
network_mode: host
privileged: true

From here, how should I automate the update process? With a docker-compose restart will be enough to delete and recreate the container?

I strongly advise against using latest image.

I use something similar to this in most of my docker containers:

image: homeassistant/home-assistant:0.77.2

So - define the exact version for a more controlled upgrade process. After that re-running docker-compose up will pull the version you put in the config file.

If for some reason it doesn’t work as you like it - just revert version to lower and do a docker-compose up again.

This way you will have to delete old pulled images manually, but it will be more controlled.

Thanks, I’ll do that.

I would like to combine it with an alert within HASS, to notify every time a new update is available, but seems the following setup is not working, althought was working on HASS.IO:

alias: ‘Update Available Notifications’
trigger:
platform: state
entity_id: updater.updater
action:
service: notify.notify_to_telegram
data:
message: ‘Update for Home Assistant is available.’

There is anything different in HASS compared to HASS.IO about this?

Search around forum - I am not sure if updater component works. I know there have been some issues before…

I am using Node Red to fetch current latest docker version. But no notifying yet as I do not do upgrades asap.

Could you share your Nodered automation? I’m starting with Nodered and would be very helpful t see how you defined this.

Thanks a lot.