From fbc695a698a01c0bfae1ccef1100f3e32751a92f Mon Sep 17 00:00:00 2001 From: "Matthew (Pilot Protocol Bot)" Date: Fri, 3 Jul 2026 16:54:16 +0000 Subject: [PATCH] fix(install): support PILOT_TRANSPORT env var for compat mode () The daemon already auto-probes UDP reachability and falls back to compat (WSS/443) transport when UDP is blocked (PR #314, commit f0c422f). This change adds PILOT_TRANSPORT env var support to install.sh for users who want to explicitly force a transport mode on systems where UDP may be unavailable. Changes: - Document PILOT_TRANSPORT=compat in Usage section + new ENVIRONMENT VARIABLES header block - Pass -transport flag to systemd unit when PILOT_TRANSPORT is set - Pass -transport to LaunchAgent plist when PILOT_TRANSPORT is set Closes PILOT-222 --- install.sh | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/install.sh b/install.sh index ccb7fcf2..2d625dc3 100755 --- a/install.sh +++ b/install.sh @@ -8,8 +8,17 @@ set -e # Usage: # Install: curl -fsSL https://pilotprotocol.network/install.sh | sh # RC build: PILOT_RC=1 curl -fsSL https://pilotprotocol.network/install.sh | sh +# Compat: PILOT_TRANSPORT=compat curl -fsSL https://pilotprotocol.network/install.sh | sh # Uninstall: curl -fsSL https://pilotprotocol.network/install.sh | sh -s uninstall # +# +# ENVIRONMENT VARIABLES: +# PILOT_TRANSPORT Set "compat" to force WSS/443 transport for UDP-blocked networks. +# PILOT_RC Set to 1 to install the latest pre-release (RC build). +# PILOT_EMAIL Skip the email prompt by providing it inline. +# PILOT_HOSTNAME Set a custom hostname for the daemon. +# PILOT_PUBLIC Set to 1 to register the daemon as a public node. +# # WHAT THIS SCRIPT DOES (read before piping to sh): # 1. Detects OS/arch (Linux/Darwin × amd64/arm64) # 2. Resolves the latest release tag from github.com/pilot-protocol/pilotprotocol/releases @@ -456,6 +465,10 @@ if [ "$OS" = "linux" ] && command -v systemctl >/dev/null 2>&1; then if [ -n "$PILOT_PUBLIC" ]; then PUBLIC_FLAG="-public" fi + TRANSPORT_FLAG="" + if [ -n "$PILOT_TRANSPORT" ]; then + TRANSPORT_FLAG="-transport $PILOT_TRANSPORT" + fi sudo tee /etc/systemd/system/pilot-daemon.service >/dev/null < "$PLIST" <