diff --git a/README.md b/README.md index 0f73f7f9..2e3d76c6 100644 --- a/README.md +++ b/README.md @@ -133,6 +133,7 @@ Without SSH access, Security Audit works fully, but you cannot run gateway/devic | Synology/QNAP/Unraid | Docker | [NAS Deployment](docker/DEPLOYMENT.md#2-nas-deployment-docker) | | macOS | Native (best performance) | [macOS Installation](docs/MACOS-INSTALLATION.md) | | Linux | Native (no Docker) | [Linux Native](docker/NATIVE-DEPLOYMENT.md#linux-deployment) | +| Home Assistant | Add-ons | [Home Assistant](docker/DEPLOYMENT.md#home-assistant) | Docker Desktop on macOS and Windows limits network throughput for speed testing. For accurate multi-gigabit measurements, use native deployment. diff --git a/docker/DEPLOYMENT.md b/docker/DEPLOYMENT.md index 490bd6d3..29c6be8b 100644 --- a/docker/DEPLOYMENT.md +++ b/docker/DEPLOYMENT.md @@ -12,6 +12,7 @@ Production deployment guide for Network Optimizer. | NAS + Docker | Synology, QNAP, Unraid | [NAS Deployment](#2-nas-deployment-docker) | | macOS Native | Mac servers, multi-gigabit speed testing | [macOS Installation](../docs/MACOS-INSTALLATION.md) | | Linux Native | Maximum performance, no Docker | [Native Guide](NATIVE-DEPLOYMENT.md#linux-deployment) | +| Home Assistant | Add-ons | [Home Assistant](#home-assistant) | --- @@ -47,6 +48,14 @@ For advanced configuration, troubleshooting, and manual installation see the [fu --- +### Home Assistant + +Network Optimizer can be installed as two Home Assistant add-ons. See [issue #201](https://github.com/Ozark-Connect/NetworkOptimizer/issues/201) for setup instructions and discussion. + +For the initial admin password, check the add-on's **Log** tab instead of using the `docker logs` command. + +--- + ### 1. Linux + Docker (Recommended) Deploy on any Linux server using Docker Compose. This is the recommended approach for self-built NAS, home servers, VMs, and cloud instances. diff --git a/scripts/proxmox/README.md b/scripts/proxmox/README.md index 6888c944..5e019790 100644 --- a/scripts/proxmox/README.md +++ b/scripts/proxmox/README.md @@ -18,7 +18,7 @@ bash -c "$(curl -fsSL https://raw.githubusercontent.com/Ozark-Connect/NetworkOpt The script will guide you through: 1. Container configuration (ID, hostname, resources, network) -2. Application settings (timezone, ports, optional password) +2. Application settings (timezone, ports, reverse proxy, geo location, optional password) 3. Automatic installation of Docker and Network Optimizer ## Requirements @@ -58,6 +58,7 @@ The script creates a privileged Debian LXC container (Debian 13 Trixie by defaul | iperf3 Server | Disabled | CLI-based speed testing (port 5201) | | Host Redirect | Disabled | Redirect IP access to hostname (requires local DNS) | | Reverse Proxy | None | Optional hostname for reverse proxy setup | +| Geo Location | Disabled | GPS tagging for speed tests and signal levels (requires HTTPS) | | Timezone | America/New_York | Container timezone | ## Post-Installation diff --git a/scripts/proxmox/install.sh b/scripts/proxmox/install.sh index 428a7d74..2d5c1b95 100644 --- a/scripts/proxmox/install.sh +++ b/scripts/proxmox/install.sh @@ -337,6 +337,38 @@ configure_application() { read -rp "Reverse proxy hostname (e.g., optimizer.example.com): " APP_REVERSE_PROXY_HOST APP_REVERSE_PROXY_HOST=${APP_REVERSE_PROXY_HOST:-} + # Geo location tagging + APP_GEOLOCATION="false" + APP_OPENSPEEDTEST_HOST="" + + echo -e "\n${WH}Geo Location Tagging${CL}" + echo -e "${DIM}Tag speed tests and Wi-Fi signal levels with GPS coordinates to map${CL}" + echo -e "${DIM}coverage and identify dead zones across your property.${CL}" + read -rp "Set up geo location tagging? [y/N]: " geolocation_response + if [[ "${geolocation_response,,}" =~ ^(y|yes)$ ]]; then + echo -e "\n${DIM}Geo location requires HTTPS (browser security requirement), and OpenSpeedTest${CL}" + echo -e "${DIM}needs HTTP/1.1 for accurate speed results. Set up an HTTP/1.1 reverse proxy${CL}" + echo -e "${DIM}(Caddy, nginx, etc.) pointing at the speed test server (port ${APP_SPEEDTEST_PORT}).${CL}" + echo -e "${DIM}See .env.example in /opt/network-optimizer for a sample Caddy config.${CL}" + echo "" + read -rp "Speed test HTTPS hostname (e.g., speedtest.example.com): " APP_OPENSPEEDTEST_HOST + if [[ -n "$APP_OPENSPEEDTEST_HOST" ]]; then + APP_GEOLOCATION="true" + # Mixed content check - main app also needs HTTPS + if [[ -z "$APP_REVERSE_PROXY_HOST" ]]; then + echo -e "\n${YW}The main app also needs HTTPS to avoid mixed content blocking.${CL}" + echo -e "${DIM}Speed test results won't save unless the main app is behind HTTPS too.${CL}" + read -rp "Main app HTTPS hostname (e.g., optimizer.example.com): " APP_REVERSE_PROXY_HOST + APP_REVERSE_PROXY_HOST=${APP_REVERSE_PROXY_HOST:-} + if [[ -z "$APP_REVERSE_PROXY_HOST" ]]; then + msg_warn "No main app hostname set. Speed test results may not save from HTTPS." + fi + fi + else + msg_warn "Hostname required for geo location. Skipping geo location setup." + fi + fi + # SSH access echo -e "\n${WH}SSH Access${CL}" echo -e "${DIM}Enable SSH root login for direct container access (alternative to pct enter).${CL}" @@ -399,6 +431,11 @@ confirm_settings() { else echo -e " Reverse Proxy: ${DIM}none${CL}" fi + if [[ "$APP_GEOLOCATION" == "true" ]]; then + echo -e " Geo Location: ${GN}${APP_OPENSPEEDTEST_HOST}${CL} ${DIM}(HTTPS)${CL}" + else + echo -e " Geo Location: ${DIM}disabled${CL}" + fi if [[ -n "$APP_PASSWORD" ]]; then echo -e " Password: ${GN}(set)${CL}" else @@ -684,6 +721,14 @@ IPERF3_SERVER_ENABLED=${APP_IPERF3_ENABLED}" REVERSE_PROXIED_HOST_NAME=${APP_REVERSE_PROXY_HOST}" fi + if [[ "$APP_GEOLOCATION" == "true" ]]; then + env_content="${env_content} + +# Geo location tagging (HTTPS speed test) +OPENSPEEDTEST_HTTPS=true +OPENSPEEDTEST_HOST=${APP_OPENSPEEDTEST_HOST}" + fi + if [[ -n "$APP_PASSWORD" ]]; then env_content="${env_content} @@ -758,6 +803,9 @@ show_completion() { if [[ -n "$APP_REVERSE_PROXY_HOST" ]]; then echo -e " Reverse Proxy: ${CY}https://${APP_REVERSE_PROXY_HOST}${CL}" fi + if [[ "$APP_GEOLOCATION" == "true" ]]; then + echo -e " Speed Test: ${CY}https://${APP_OPENSPEEDTEST_HOST}${CL} ${DIM}(geo location enabled)${CL}" + fi if [[ -z "$APP_PASSWORD" ]]; then echo -e "\n${BLD}Admin Password:${CL}"