diff --git a/README.md b/README.md index 518509b..e49820e 100644 --- a/README.md +++ b/README.md @@ -45,7 +45,7 @@ InkyPi (or anything else) already running, it stops it first -- two things can't drive the same panel at once -- but nothing is copied from or reused out of it. Safe to re-run. -Then open `http://:8080`, fill in Navidrome credentials under +Then open `http://`, fill in Navidrome credentials under **Navidrome** and a city under **Weather**. Everything saves immediately and takes effect within a few seconds -- no restart needed. diff --git a/install.sh b/install.sh index 5f6bc8c..40fd15b 100755 --- a/install.sh +++ b/install.sh @@ -94,7 +94,11 @@ install_service() { -e "s#{{PYTHON}}#$VENV_DIR/bin/python3#g" \ "$APP_DIR/paperwall.service.template" > "$SERVICE_TARGET" systemctl daemon-reload - systemctl enable --now "$SERVICE_NAME" + systemctl enable "$SERVICE_NAME" + # restart (not just enable --now) so re-running this after a unit file + # change -- e.g. the port -- actually picks it up on an already-running + # install, not just on a fresh one. + systemctl restart "$SERVICE_NAME" echo " installed and started." } @@ -104,7 +108,7 @@ show_status() { systemctl status "$SERVICE_NAME" --no-pager -l | head -15 || true ip_address=$(hostname -I | awk '{print $1}') echo - echo "Web UI: http://$ip_address:8080 (or http://$(hostname).local:8080)" + echo "Web UI: http://$ip_address (or http://$(hostname).local)" echo "Logs: journalctl -u $SERVICE_NAME -f" echo "Remove: sudo bash uninstall.sh" if grep -qE '^\s*dtoverlay=spi0-2cs' "$CONFIG_TXT" 2>/dev/null; then diff --git a/paperwall.service.template b/paperwall.service.template index 462800c..87338c1 100644 --- a/paperwall.service.template +++ b/paperwall.service.template @@ -6,7 +6,7 @@ Wants=network-online.target [Service] Type=simple # Filled in by install.sh to point at this project's own self-contained venv. -ExecStart={{PYTHON}} {{APP_DIR}}/main.py --host 0.0.0.0 --port 8080 +ExecStart={{PYTHON}} {{APP_DIR}}/main.py --host 0.0.0.0 --port 80 WorkingDirectory={{APP_DIR}} Restart=on-failure RestartSec=5