alarno
(Albert ArnΓ³)
April 25, 2022, 2:41pm
1
Hi, I have installed HA and everything is ok. I also have installed duckdns and nginx. But when I try to log by remote xxxx.duckdns.org address, I get stuck with this: Unable to connect to Home Assistant. Retry
Please, any help will be appreciated
Albert
Tinkerer
(aka DubhAd on GitHub)
April 25, 2022, 2:48pm
2
Have you checked the NGINX logs to see if the connection is making it to NGINX?
1 Like
alarno
(Albert ArnΓ³)
April 25, 2022, 5:22pm
3
Hi Tinkerer,
Thank you very much for your help!!! This is the last lines of log, it looks everything is ok, right?
[25/Apr/2022:18:40:41 +0200] 400 - - http localhost β-β [Client 181.29.19.157] [Length 150] [Gzip -] β-β β-β
[25/Apr/2022:18:42:33 +0200] 400 - - http localhost β-β [Client 186.57.254.111] [Length 150] [Gzip -] β-β β-β
[25/Apr/2022:18:42:37 +0200] 200 - GET http 207.188.163.153 β/β [Client 103.195.103.32] [Length 1154] [Gzip -] β-β β-β
[25/Apr/2022:18:42:41 +0200] 400 - - http localhost β-β [Client 181.29.19.157] [Length 150] [Gzip -] β-β β-β
[25/Apr/2022:18:44:20 +0200] 400 - - http localhost β-β [Client 186.57.254.111] [Length 150] [Gzip -] β-β β-β
[25/Apr/2022:18:44:44 +0200] 400 - - http localhost β-β [Client 181.29.19.157] [Length 150] [Gzip -] β-β β-β
[25/Apr/2022:18:46:21 +0200] 400 - - http localhost β-β [Client 186.57.254.111] [Length 150] [Gzip -] β-β β-β
[25/Apr/2022:18:48:22 +0200] 400 - - http localhost β-β [Client 186.57.254.111] [Length 150] [Gzip -] β-β β-β
[25/Apr/2022:18:49:28 +0200] 400 - - http localhost β-β [Client 186.57.254.111] [Length 150] [Gzip -] β-β β-β
[25/Apr/2022:18:50:40 +0200] 400 - - http localhost β-β [Client 186.57.254.111] [Length 150] [Gzip -] β-β β-β
[25/Apr/2022:18:51:18 +0200] 400 - - http localhost β-β [Client 181.29.19.157] [Length 150] [Gzip -] β-β β-β
[25/Apr/2022:18:54:18 +0200] 400 - - http localhost β-β [Client 181.29.19.157] [Length 150] [Gzip -] β-β β-β
[25/Apr/2022:18:54:41 +0200] 400 - - http localhost β-β [Client 186.57.254.111] [Length 150] [Gzip -] β-β β-β
[25/Apr/2022:18:55:19 +0200] 400 - - http localhost β-β [Client 141.226.89.175] [Length 150] [Gzip -] β-β β-β
[25/Apr/2022:18:55:19 +0200] 400 - - http localhost β-β [Client 141.226.89.175] [Length 150] [Gzip -] β-β β-β
[25/Apr/2022:19:00:12 +0200] 400 - - http localhost β-β [Client 54.210.77.120] [Length 150] [Gzip -] β-β β-β
[25/Apr/2022:19:00:42 +0200] 400 - - http localhost β-β [Client 186.57.254.111] [Length 150] [Gzip -] β-β β-β
[25/Apr/2022:19:07:27 +0200] 400 - - http localhost β-β [Client 54.210.77.120] [Length 150] [Gzip -] β-β β-β
[25/Apr/2022:19:07:28 +0200] 400 - - http localhost β-β [Client 54.210.77.120] [Length 150] [Gzip -] β-β β-β
[25/Apr/2022:19:08:44 +0200] 400 - - http localhost β-β [Client 212.193.53.86] [Length 150] [Gzip -] β-β β-β
[25/Apr/2022:19:15:32 +0200] 404 - POST http 207.188.163.153 β/boaform/admin/formLoginβ [Client 179.43.167.122] [Length 118] [Gzip 1.36] βMozilla/5.0 (Windows NT 10.0; Win64; x64) Gecko/20100101 Firefox/71.0β βhttp://207.188.163.153:80/admin/login.asp β
[25/Apr/2022:19:15:32 +0200] 400 - - http localhost-nginx-proxy-manager β-β [Client 179.43.167.122] [Length 0] [Gzip -] β-β β-β
[25/Apr/2022:19:19:25 +0200] 400 - - http localhost β-β [Client 54.210.77.120] [Length 150] [Gzip -] β-β β-β
[25/Apr/2022:19:20:05 +0200] 400 - - http localhost β-β [Client 77.81.98.70] [Length 150] [Gzip -] β-β β-β
alarno
(Albert ArnΓ³)
April 25, 2022, 5:28pm
4
maybe this can help to know the issue why is not working:
2022/04/25 16:36:10 [error] 628#628: *270 SSL_do_handshake() failed (SSL: error:1408F10B:SSL routines:ssl3_get_record:wrong version number) while SSL handshaking to upstream, client: 207.188.163.xxx, server: xxx.duckdns.org , request: βGET / HTTP/2.0β, upstream: βhttps://192.168.1.xxx:8123/ β, host: βxxx.duckdns.org β, referrer: βhttp://homeassistant.local:81/ β
alarno
(Albert ArnΓ³)
April 25, 2022, 5:41pm
6
ok, let me get this right:
In nginx configuration scheme, I put https? and, when you say upstream? where??
I can pay you if you help me connecting remotely and make it work!
Tinkerer
(aka DubhAd on GitHub)
April 25, 2022, 5:56pm
7
That upstream.
Itβs going to be easier to help you fix your config if you share it
1 Like
alarno
(Albert ArnΓ³)
April 25, 2022, 7:42pm
8
Hi, Iβm sharing my configuration.yaml. But if I try to enter to https://homeassistant.local:8123 is says error, ERR_SSL_PROTOCOL_ERROR
homeassistant:
external_url: http://xxx.duckdns.org:8123
internal_url: http://homeassistant.local:8123
Tinkerer
(aka DubhAd on GitHub)
April 26, 2022, 6:18am
9
We need your NGINX configuration
1 Like
Tinkerer
(aka DubhAd on GitHub)
April 26, 2022, 8:22am
12
Images of text are horrible, youβre relying on people having the same vision as you. Please share text as textβ¦
That said your problems are likely simple:
First screenshot you havenβt enabled websockets support
Second screenshot says https
instead of http
Eventually you can fix the external URL setting in HA to use https://
2 Likes
alarno
(Albert ArnΓ³)
April 26, 2022, 3:51pm
13
Hi Tinkerer, I followed your 3 points, reboot, and nothing, I get this:
Login attempt or request with invalid authentication from 207.188.162.128 (207.188.162.128). (Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/100.0.4896.127 Safari/537.36)
Tinkerer
(aka DubhAd on GitHub)
April 26, 2022, 5:53pm
14
Well, that sounds like youβve at least got a connection?
1 Like
alarno
(Albert ArnΓ³)
April 26, 2022, 6:08pm
15
Yes Tinkerer, but how can I solve it?? Thank you very much
Johanf
(Johan)
April 26, 2022, 6:16pm
16
Did you open ports on your router?
1 Like
alarno
(Albert ArnΓ³)
April 26, 2022, 6:20pm
17
Yes, 80, 81, 443 and 8123
Johanf
(Johan)
April 26, 2022, 6:25pm
18
I personally donβt use NGINX, but I do use DuckDNS addon. Maybe you can try to disable the Nginx addon, and see if youβll get that part working first. Nginx is not necessary for for your HA dashboard to be accessed via your Duckdns address.
The DuckDNS addon documentation says the following has to be set in the addon configuration.
lets_encrypt:
accept_terms: true
certfile: fullchain.pem
keyfile: privkey.pem
token: sdfj-2131023-dslfjsd-12321
domains:
- my-domain.duckdns.org
aliases: []
seconds: 300
Did you set Accept_terms to true?
Next to that, you have to add the following to the configuration.yaml:
http:
ssl_certificate: /ssl/fullchain.pem
ssl_key: /ssl/privkey.pem
you can comment out the external_url and internal_url for this to test.
1 Like
alarno
(Albert ArnΓ³)
April 27, 2022, 7:31am
20
Hi Johanf,
I follow it, stop nginx, but, still, I went to the door using duckdns, but βUnable to connect to Home Assistant.β.
It also looks my letβs encrypt stops alone although is marked start on boot. Iβm stuck with this log:
Login attempt or request with invalid authentication from 207.188.162.xxx (207.188.162.xxx). (Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/100.0.4896.127 Safari/537.36)
I also change port forwarding, 443 to 8123 instead of 443 to 443