Hello everybody,
first of all I apologize if my question has been answered already, I searched but couldn’t find anything that solved.
I’m running HA on a RPI3, not HASSIO but normal HA, as some of the stuff I’m using is still not ok in HASSIO.
I implemented several functions, including Dashboards via Appdaemon, and everithing was running smoothly. I decided then to open the access from outside via DuckDNS and Letsencrypt, and this also is now running smoothly. The only thing I had to do was changing the default 8123 port of HA to another one, because my router wasn’t able to open port over 5060 (don’t ask me why!) Anyway everithing goes well.
Of course Dashboard stopped, so I edited appdaemon.yaml and changed the line
ha_url: http://“internal IP”:“port number”
to
ha_url: https://“internal IP”:“port number”
but Appdaemon is unable to start. Log reports:
2018-01-09 12:56:10.422136 WARNING Unable to connect to Home Assistant, retrying in 5 seconds
I checked passwords, IP’s, port numbers, anything I could immagine, but nothing happen.
Does anyone can help, please?
Thanks in advance.
This might occur because the dashboard app does not trust HA anymore. Letsencrypt generates certificates with the hostname, so when you try to connect via the IP address, the certificate does not match. A simple way to find out if that’s the case is to use your full hostname (as specified for Letsencrypt) in the dashboard configuration.
If you connect to your HASS instance through its internal IP with https, the client won’t trust the server because the SSL certificate was generated for your DuckDNS domain. This can be bypassed in most browsers, but some programs that are configured to only transmit data over secure connections may simply refuse to connect. Try configuring AppDaemon so that it will use your DuckDNS domain instead of an internal IP to connect.
Thanks very much to everybody for your kind answer, it worked!
How silly I was not to consider the connection between the name and the certificates!
The only problem now is that, going outside to duckdns and then back inside, makes the dashboard really slow. Also, one of the main point in HA is being an “Insite system” that is most of it can work without Internet connection. In this case the dashboard couldn’t work without accessing the internet, which is a shame.
I also looked at the “Apache solution”, using Apache to create a subdomain that forward to the main one but without SSL, but this is quite complicate and not well explained, so I can’t get to a point.
Someone says that I should double the HA installation and create another user on another port, just for internal use, but this seems to me quite heavy, and also prone to mistakes in developing the two versions separately!
Anyone has some idea? Otherwise I’m afraid I will have to quit using dashboard, which is a huge shame!
Thanks in advance, cheers.
Luca
My approach is to use Apache in a reverse proxy configuration with Letsencrypt only when accessing it from outside my home. HA itself is configured using the plain HTTP connector, so that Apache and HADashboard connect to HA via HTTP on the same server.
installing NGINX isnt that hard and configuration from it to use HA trough NGINX is documented on the forum.
i use it also that way.
Ok, it seems that the right path could be either Apache, but I’m not very good in handling it and HA tutorials are quite confusing on that, or NGINX, that seems to be more documented in HA community.
I guess I’ll try the second and let you know. If I fall in troubles you’ll surely know btw!
Thx a lot!!!
your welcome.
i was afraid from it too, for a long time, but it wasnt that hard to do.
the config file is the hardest but there is a lot on the forum, or just call and ill paste it here
Thx a lot Rene, I’m 55 and on the net from 1993, but it’s always nice to find someone kind!
I’ll crash my (old) head against NIGINX tomorrow, and I’ll let you know.
Goodnight to all.
im almost 51 and almost the same amount of time online.
i love to helpout if i can, and i thank you for the compliment.
dont worry you get it right. i just did a new install on a new machine and its about the same amount of work as installing appdaemon itself.