Hassio: login not working from custom domain with SSL

Hi
I have Hassio installed on my Synology. Synology acts as a reverse proxy with SSL (Let’s Encrypt).

I can login from my local IP-adres, but not from the custom domain with SSL.

Any ideas?

Regards
Djiest

can you connect to anything at your https://yoursite.com

I would verify port forward and that proxy is setup properly.

Thanks for your reply. My question was failing necessary info.
https://myha.customdomain.com is working, but when I try to login I get an error ‘Unable to connect to Home Assistant.’

I think it has to do with this statement ‘I have also configured the firewall to allow the Hassio network container.’ here Hass.io on Synology DSM (native package), looks like I’m missing that. However I’m not sure WHAT to configure.

My guess is proxy is problem

Synology has some log and I you should be able to check that and possibly get info.

this mean you open port?
so maybe you need https://yoursite.com:port
it is true reverse proxy or more like open port on server and add the ssl for port. maybe this also mean port only open in synology but not forwarding port from WAN to HA port.

sorry but long time since I use synololgy and I only use the docker so not using the built in packages much.

Some debugging gave the following error
‘Error during WebSocket handshake: Unexpected response code: 400’

This may be similar to problem that occur when you try make www.yoursite.com/ha point to HA.
This never work for some reason explained in the thread below

This should not be issue if your subdomain only point to ha at /
If this is reverse proxy you may need ensure config is proper to support websocket

That’s not the problem I think, I have ha.customdomain.dom, not my.customdomain.dom/ha

I’m closing this thread and will create a new one which better describes the issue
see Websocket error on custom domain with SSL (Synology)

I was thinking more that Synology is not properly passing url back from HA

Duhh!?
thats what I said
simple as this:

you cannot redirect URIs to home assistant.

I presume you do understand what a URL, URI , Domain and Subdomain is - are?? If not then that might explain your comment "! If not then let me educate:

You cannot redirect the URI (i,e, /ha bit).
You can redirect a subdomain on a registered domain. So, if you own the domain mysite.com for example, then you can use a subdomain, say homeassistant. So in your domain registrar company, you would create a subdomain homeassistant.mysite.com and point this to your nginx reverse proxy, then use the reverse proxy to forward (proxy_pass as its called) traffic to your homeassistant server.

The reason URIs cannot be used is because the homeassistant codebase has hardcoded URIs from the / root , so for example it might want to file called somescritpt.js in the local webspace directories but this is anchored to the / URI so that it resolves to some.site.com/somescript.js . Of course, if you add a URI such as some.site.com/myhomeassistant then these hard coded links will mean homeassistant goes looking for some.site.com/myhomeassistant/somescript.js on the local homeassistant server , which of course doesnt exist. A heck of a lot of code needs changing to fix this so dont hold your breath. It was never intended to run like that anyway.

@ninjadog thanks. Yes I understand URL,URI and (subdomains). As stated in my previous comment, I do have https://homeassistant.mysite.com, so that should not be the problem. Please see my followup topic from my comment, marked as ‘Solution’