Install VPN Hub
This source-install path is useful before the first tagged release. For a public release, prefer the checksum-verified release recipe when it becomes available.
Prerequisites
Заголовок раздела «Prerequisites»- A host that satisfies Requirements.
- A clean checkout on the operator workstation.
- SSH root access in
HUB_HOST; the example address is from RFC 5737.
Build and stage
Заголовок раздела «Build and stage»export HUB_HOST=192.0.2.10make build-linuxssh root@"$HUB_HOST" 'install -d -m 0700 /run/vpn-hub-stage/systemd'scp bin/linux/hubctl bin/linux/vpn-hub-agent bin/linux/vpn-hub-bot \ deploy/install.sh root@"$HUB_HOST":/run/vpn-hub-stage/scp deploy/systemd/vpn-hub-agent.service deploy/systemd/vpn-hub-bot.service \ root@"$HUB_HOST":/run/vpn-hub-stage/systemd/ssh root@"$HUB_HOST" 'sh /run/vpn-hub-stage/install.sh'Expected result: /usr/local/bin contains all three executables. The agent starts; the bot starts only when /etc/vpn-hub/telegram.yaml exists.
Roll back
Заголовок раздела «Roll back»Keep the previous verified artifact before replacing binaries. Restage that artifact and run the same deploy/install.sh. To undo a first install before configuration exists:
ssh root@"$HUB_HOST" 'set -eusystemctl disable --now vpn-hub-bot vpn-hub-agentrm -f /usr/local/bin/hubctl /usr/local/bin/vpn-hub-agent /usr/local/bin/vpn-hub-botrm -f /etc/systemd/system/vpn-hub-agent.service /etc/systemd/system/vpn-hub-bot.servicesystemctl daemon-reload'Do not remove /etc/vpn-hub or /var/lib/vpn-hub after real use until their secrets and recovery state have been backed up or deliberately destroyed.
Create the first hub configuration.