Alexa cant discover Emulated Hue / Docker

Hello Community!

since a few days I am trying to connect the emulated hue with Alexa. But the Echo Dot just does not find it.
I’ve searched a while the community along for solutions, but nothing helped.

HA is installed inside a docker container and runs with the command -net=host on a QNAP NAS. The Container has the IP, so same IP as the QNAP has.

Here are my configs:

         emulated_hue_name: "sonytv"
         emulated_hue: true
   expose_by_default: false

I’ve checked the URL, the file is accessible.
The URL seems to return that everything is working fine:

{“1”: {“modelid”: “HASS123”, “name”: “sonytv”, “state”: {“bri”: 0, “on”: false, “reachable”: true}, “swversion”: “123”, “type”: “Dimmable light”, “uniqueid”: “media_player.sony_bravia_tv”}}

HA-log output about the Emulated Hue component:

17-04-05 12:17:53 WARNING (Thread-3) [homeassistant.components.emulated_hue] Listen IP address not specified, auto-detected address is
17-04-05 12:17:53 WARNING (Thread-3) [homeassistant.components.emulated_hue] When targetting Google Home, listening port has to be port 80
INFO:homeassistant.components.http:Serving /description.xml to (auth: False)

Found nothing more in the log file.

Moreover I’ve installed the official Hue App on Android and check if I can discover it with the App. Discover isn’t working, nothing found. But if I manually add the IP in the App - it works fine.

What am I missing? Hope for a solution. Thanks in advance!

It might be necessary to specify type: alexa in your emulated_hue block, I have it in mine. I do have a docker on a Pi with net=host and the discovery works as expected, thats the key difference I can see.

Yeah, per the components page:
type (Optional): The type of assistant who we are emulated for. Either alexa or google_home, defaults to google_home.

Thank you for fast answer! Didn’t recognize the default value, because of:

17-04-05 13:14:50 WARNING (Thread-10) [homeassistant.components.emulated_hue] Alexa type is deprecated and will be removed in a future version

Nevertheless nothing changed. Can’t discover :confused:

Sigh. I’ll think about it today if I’m forgetting something but as I recall I added the lines and it just worked. You don’t learn squat when things work right away :stuck_out_tongue:

I wonder then if it might be something about the QNAP? Maybe searching the web on similar behaviors on other containers with QNAP?

I would normally turn them off but maybe testing Bonjour support? That is probably a similar mechanism

@derydani Try searching for devices after restarting Home Assistant.

Restart Home Assistant > Search for devices on Echo Repeatedly while Home Assistant Start up

Yeah I think there is maybe something with QNAP or the router I miss.

Today I’ve downloaded ha-local-echo into the container, configured it and started it manually. The script is connecting sucefully to HA api, but cannot be discovered by Alexa, too.
This is the output:

Fetching Home Assistant entities…
Adding 2842824116: entity_id “media_player.sony_bravia_tv” with spoken name “SonyTV”
Using 1 entities from Home Assistant

UPNP Responder Thread started…
Starting Flask for HTTP listening on…

  • Running on (Press CTRL+C to quit)
    UPNP Responder sending response to
    UPNP Responder sending response to
    UPNP Responder sending response to
    UPNP Responder sending response to
    UPNP Responder sending response to
    UPNP Responder sending response to - - [05/Apr/2017 13:47:49] “GET /description.xml HTTP/1.1” 200 -

and so on…

By the way, on QNAP I can search for an upnp-router. In the logs the QNAP is finding HA as upnp device - but cannot find the FritzBox. So maybe I must change something in FritzBox (upnp devices is turned on)?

@jamieb This is one solution I found here on the community and I always try to discover during the restart of container - but no luck.

if i am not mistaken you must have https setup for Alexa to be able to reach HA.
i dont know if you have that, and if you can reach HA from outside your network, if not that might be your problem.

This all happens locally, this isnt a case of the Alexa service having to call in to HA directly. It’s the local Echo device calling the Hue API, and HA faking it.

Okay, after restarting QNAP and FritzBox AND after x-pushing the button for discover new devices in Alexa…It found HA.
But! After a while the component turns to offline and it can’t find other devices again :triumph:

EDIT: Put a new container with HA works immediately! I read that a switch between Alexa and HA can cause a lost of UPNP data. I got 2 adapters within QNAP. One is direclty connected to the FritzBox and the other one to a switch. So the new container isn’t used with the option -net=host, but is connected to the adapter 1. Thanks to all for helping!

Hi derydani,
I found this thread that is very similar to my problem.
I have too homeassistant installed on QNAP and I did the same things you did but no luck.
In the end you said that you put a new container with HA, what do you mean by that?
Did you remove the container from container station and then istalled a new one?
Thanks for the help

Hi fabfranz

I just exported the container and imported it again, but changed the network adapter to the one which is not connected to a switch. Took the one which goes directly from the QNAP to the router/internet.

Hope it’ll help

Thank for the help, in the end I’m not sure what exactly I did to make it work… but it’s working now!