The updater component isn't working in Docker

OK now that I have your attention… :grinning:

This is the third time I’ve tried to get help with this.

I posted on this same topic a couple of weeks ago but got no replies so I figured I’d try again…

I’m running HA 0.74.0 in docker on a NUC with Debian OS. I’ve got one port open on my router as I’ve moved to using a VPN for outside access.

this is the error I get in my log:

2018-08-03 23:00:02 ERROR (MainThread) [homeassistant.components.updater] Got unexpected response: {‘errorMessage’: ‘RequestId: 7b01922b-9792-11e8-9b30-0df41a88668f Process exited before completing request’}

Can anyone help explain why the updater stopped working for me? does it need some open port to work?

And as an update to that thread that not one person replied to:

For troubleshooting purposes I installed a second instance of HA and opened the ports 443 to 443 & 80 to 80 using NGINX to forward traffic to the second HA instance. I have tested access to my second HA instance from the internet at my duckdns domain.

I’m still not getting the updater to run.

In my second HA instance (also running 0.74.0 in docker) I get the following:

2018-08-13 08:53:02 ERROR (MainThread) [homeassistant.components.updater] Got unexpected response: None

It should would be nice if someone could help me out with this.

Well I’m not going to be able to help much I’m afraid. All I can tell you is the only port I have open is 8123 for duckdns and have no problem with the updater.

I would say that it doesn’t make sense that you need any special port open to update. Its not mentioned anywhere in the docs (at least not for HASSIO). And I think plenty of people dont have any ports open and still update. Also unless you had changed your router or settings this wouldnt suddenly stop working…

I think you are maybe looking in the wrong area wrt port forwards being the issue.

When you say the updater stopped working is this the component that lets you know when a new version of HA is available? Assuming you can actually do an update manually?

Since I use a different architecture the only things I can suggest (from reading the docs) are completely removing the updater component and starting again. If you have opted for any of the additional options remove all those too.

Not really sure what else to suggest

Thanks for responding! :smile:

Yes, I can update OK.

I’m talking about the updater component that tells you when there is a new update released.

The thing is I don’t know if the updater component sends a request to the HA website to see if there is an update available or if it works some other way.

On my original non-docker set up it worked perfectly but after I switched to docker is when I noticed it was no longer working.

I don’t know if that’s a coincidence or not.

I have same issue with updater component. I’m using Hass docker on Ubuntu 18. By default updater posts some data to Hass cloud for statistics (at least Hass version). I guess that something has been changed on server side or the number of Hass users significantly increased that server is under presser of heavy load.

In the docs it says that the updater component collects information about your architecture and passes it to HA

I guess that hasn’t updated itself since you changed over. Possibly removing the component then reinstalling may mean that information is properly refreshed. However it may be stored in the database.

When you created your second instance of HA did you restore a backup?? It would be interesting to see if you started from scratch with only basic config if the updater component worked then.

same issue for me so I’ve ended up using a scrape sensor with an automation.
Scrape Sensor:

- platform: scrape
  resource: https://www.home-assistant.io
  name: ha_online_version
  select: ".current-version h1"
  value_template: '{{ value.split(":")[1] }}'

I also have this to check installed version

- platform: version

My automation runs like this: (I use docker hence the link to make sure the container has been built before I try to update):

- alias: HASS Update Available Notification
  trigger:
    platform: state
    entity_id: sensor.ha_online_version
  condition:
    - condition: template
      value_template: '{{states.sensor.ha_online_version.state != states.sensor.current_version.state }}'
  action:
    - service: notify.gmaillolo
      data_template:
        message: 'There is an update to Home-Assistant: {{states.sensor.ha_online_version.state}} (https://hub.docker.com/r/homeassistant/home-assistant/builds/)'

3 Likes

I have a similar setup. Short answer: use Traefik and Watchtower

I don’t think I like the watchtower thing. With HA having so many potential breaking changes and the changes breaking things (very different things…) I wouldn’t want to update my HA automatically. I want more control than that.

And I’m glad it just isn’t me that’s having the issue. Maybe i’ll raise an issue on github and see if it can be fixed.

I guess my ploy worked!

I posted this pretty much exact same topic three times already with a real topic title and I’ve gotten 3 times more views (including a bunch of answers) in 6 hours than I have since I posted the topic the first time a month ago.

:laughing::laughing::laughing:

Thanks! :grinning:

No it wasn’t from a backup. It was a completely new container and a bare bones config file.

Except the topic-title is not very useful for other users.

1 Like

I know! :grinning: But I at least got the info I wanted. Which I couldn’t get before using a useful title. I literally got 30 views and not one reply on two other attempts at asking the same question. Right now I have 169 views and counting! Sometimes you have to be tricky to get peoples attention. :wink:

However, I will change the title to something useful now that the question has been mostly answered.

i’m having the same issue, but i’m not running on docker so i doubt that is the issue here. (using Hassbian btw) I guess i’ll just disable the updater for now, since i don’t think i’ll need it anyway.

I’m having the same issue and updated to the latest (0.79.3). It’s inside a Python venv but I don’t see how that should be an issue.

This is working for me (running HASS in Docker):

Create automation file alert_update.yaml:

- alias: New Update Available
  trigger:
    platform: time
    hours: '/5'
    minutes: 00
    seconds: 00
  condition:
    condition: template
    value_template: '{{ states.sensor.hass_current_version.state != states.sensor.hass_installed_version.state }}'
  action:
    service: notify.telegram
    data_template:
      message: "Home Assistant v{{ states.sensor.hass_current_version.state }} is now available. Running version is: v{{ states.sensor.hass_installed_version.state }}"

Add into sensors.yaml file:

- platform: command_line
  name: HASS Current Version
  command: python3 -c "import requests; print(requests.get('https://pypi.python.org/pypi/homeassistant/json').json()['info']['version'])"

- platform: command_line
  name: HASS Installed version
  command: "head -5 /config/.HA_VERSION"