Skip to content

Node-based terminal manager for AI coding agents — tmux-backed terminals and parallel agent sessions as draggable nodes on an infinite pan/zoom canvas. macOS, Linux, and a browser Server Edition.

fix(server): resolve HOME in install-server.sh when systemd runs it without one

enes72197e5b32fe
diff --git a/scripts/install-server.sh b/scripts/install-server.sh
index a60c3e549..abf65a178 100755
--- a/scripts/install-server.sh
+++ b/scripts/install-server.sh
@@ -13,6 +13,13 @@
# Idempotent: re-run it any time to pull the latest code, rebuild, and restart the service.
set -euo pipefail
+# systemd SYSTEM units run with no HOME in their environment — the nightly auto-update oneshot
+# re-execs this script exactly that way, and `set -u` turned the bare $HOME below into a hard
+# stop (the pull succeeded but the rebuild/restart never ran, leaving the service on a stale
+# build). Resolve it from the passwd db when absent; npm/git below need it exported too.
+HOME="${HOME:-$(getent passwd "$(id -u)" | cut -d: -f6)}"
+export HOME
+
REPO_URL="${NODETERM_REPO_URL:-https://github.com/eneskirca/nodeterm}"
APP_DIR="${NODETERM_APP_DIR:-$HOME/.nodeterm-server-app}"
# Where the running server keeps its state (auth, sessions, workspace, scrollback). Matches the