# HEOS panel behind Apache, at /heos # # sudo a2enmod proxy proxy_http headers # sudo cp /var/www/html/heos/deploy/heos.conf /etc/apache2/conf-available/heos.conf # sudo a2enconf heos # sudo apachectl configtest && sudo systemctl reload apache2 # # Apache reaches the panel on port 5005 (WEB_PORT in config.py). If you # want it reachable ONLY through Apache, start it with --host 127.0.0.1; # by default it also answers directly on the LAN at :5005. # This block also takes /heos away from the filesystem, so the source in # /var/www/html/heos stops being reachable as static files. # The panel controls the speakers, and it hangs off a vhost with a # public certificate. Keep it to the house unless you mean otherwise: # delete this RequireAny block to let it answer from anywhere. Require ip 192.168.0.0/24 Require ip 127.0.0.1 Require ip ::1 # Tells the app it is mounted on a sub-path, so every link, icon and # fetch it generates is /heos/... rather than /... Without this the # page loads and nothing on it works. RequestHeader set X-Forwarded-Prefix /heos ProxyPass http://127.0.0.1:5005 ProxyPassReverse http://127.0.0.1:5005