I already have an Apache web server that manages the communication between the different services and websites as a reverse proxy.
The Apache web server also handles the SSL certificates and resolves them to an unencrypted connection within the LAN.
The configuration file is used:
httpd-vhosts.conf
Here the relevant section.
# ---------------------------
# home.mydomain.com
# ---------------------------
<virtualhost *:80>
servername home.mydomain.com
redirect permanent / https://home.mydomain.com/
</virtualhost>
<virtualhost *:443>
servername home.mydomain.com
rewriteengine on
rewriterule ^/(.*) http://10.1.254.12:8123/$1 [p,l]
sslengine on
sslcertificatefile "conf/ssl/mydomain.com/prim_interm.crt"
sslcertificatekeyfile "conf/ssl/mydomain.com/private.key"
# not in use because of url rewrite
documentroot "w:/www/home"
</virtualhost>
Similar sections are currently in use to reverse proxy to different LAN servers and on different ports and there everything works fine.
However accessing HA over the internet will lead to an error
400: Bad request
I also entered the public domain to
HA → Settings → System → Network → Home Assistant URL
set it to:
https://home.mydomain.com
Any ideas what is going on?
Thanks!