I’m trying to configure access to HA on my local network at home.myhouse.local. I’m following the instructions outlined in the post Reverse Proxy with Apache, and I’m not having any luck connecting at all. When I complete the setup in per the article, I get a DNS_PROBE_FINISHED_NXDOMAIN
error.
My environment: I’m running HA Supervised with Ubuntu I also haven’t configured SSL yet; it’s on my to-do list, but for now I’m just trying to get up and running through a port 80 proxy. I’m using avahi to publish my server’s domain name on my local network.
Here’s what I’ve done so far; I’ll quote the article as needed:
So you already have a working Apache server available at
example.org
. Your Home Assistant is correctly working on this webserver and available athttp://localhost:8123
Done. I can access both the default Apache page at http://myhouse.local
, and my HA instance at http://192.168.x.x:8123
Enable mod_proxy_wstunnel
Done. I’ve got the following Apache mods enabled in addition to mod_proxy_wstunnel:
access_compat.load | env.load |
alias.load | filter.load |
auth_basic.load | mime.load |
authn_core.load | mpm_event.load |
authn_file.load | negotiation.load |
authz_core.load | proxy.load |
authz_host.load | proxy_wstunnel.load |
authz_user.load | reqtimeout.load |
autoindex.load | rewrite.load |
deflate.load | setenvif.load |
dir.load | status.load |
Add the following to
hass.conf
…
Done. Here’s my hass.conf
file. Note that I’ve changed the instructions from the original port 443 to port 80, and updated the ServerName with my own. After saving the file, I ran sudo a2enmod hass
and then sudo systemctl restart apache2
which returned no errors.
Note that I’ve tried this config with both disablereuse=on
and without this text, and I still have the same results
# Home Assistant reverse proxy
# See https://community.home-assistant.io/t/reverse-proxy-with-apache/196942
<VirtualHost *:80>
ServerName home.myhouse.local
ProxyPreserveHost On
ProxyRequests off
ProxyPass /api/websocket ws://localhost:8123/api/websocket disablereuse=on
ProxyPassReverse /api/websocket ws://localhost:8123/api/websocket disablereuse=on
ProxyPass / http://localhost:8123/
ProxyPassReverse / http://localhost:8123/
RewriteEngine on
RewriteCond %{HTTP:Upgrade} =websocket [NC]
RewriteRule /(.*) ws://localhost:8123/$1 [P,L]
RewriteCond %{HTTP:Upgrade} !=websocket [NC]
RewriteRule /(.*) http://localhost:8123/$1 [P,L]
</VirtualHost>
When I try to browse to the site, I get a DNS_PROBE_FINISHED_NXDOMAIN
error.