Advanced
Manual server agent install (no sudo)
Prefer not to run the one-line install command? Follow these steps to download, inspect, and run the Go agent without elevated privileges.
1) Generate a registration token
- Open Dashboard → Server agents and click Install agent.
- Copy the generated install command (you will not run it).
- Extract the install URL and token from the command. Example:
https://xuptimemonitor.com/api/server/agents/install-go?token=TOKEN_VALUEThe registration token expires; generate a fresh one if the install takes too long.
2) Download and inspect the installer script
Download the installer to a file so you can review it. It contains the prebuilt Go binaries plus the configuration template.
curl -fsSL "INSTALL_URL" -o install-server-agent-go.sh
chmod +x install-server-agent-go.sh
less install-server-agent-go.sh Replace INSTALL_URL with the URL you extracted in step 1.
3) Install without systemd
Run the installer in a local directory and skip systemd setup. This keeps the files in your home directory and avoids sudo.
INSTALL_DIR="$HOME/uptime-agent" SKIP_SYSTEMD=1 ./install-server-agent-go.sh The agent configuration is written to data/agent-config.json under the install directory.
4) Run the agent
Start the agent from the install directory:
cd "$HOME/uptime-agent"
./server-agent-go To disable auto-updates, set UPTIME_AGENT_AUTO_UPDATE=false in your environment or in a wrapper script.
5) (Optional) Run as a user service
If you want the agent to survive reboots without sudo, set up a systemd user service:
mkdir -p ~/.config/systemd/user
cat > ~/.config/systemd/user/uptime-server-agent-go.service <<'EOF'
[Unit]
Description=Uptime Server Agent (Go)
After=network.target
[Service]
Type=simple
WorkingDirectory=%h/uptime-agent
ExecStart=%h/uptime-agent/server-agent-go
Restart=always
RestartSec=5
Environment=NODE_ENV=production
[Install]
WantedBy=default.target
EOF
systemctl --user daemon-reload
systemctl --user enable --now uptime-server-agent-go.serviceIf your system doesn’t allow user services, run the agent in a screen/tmux session instead.
6) Verify in the dashboard
- Return to Server agents and confirm the agent is online.
- Check last heartbeat and CPU/memory metrics.
- If it’s still offline, confirm outbound HTTPS access to the base URL in your config.