diff --git a/ssh_router.sh b/ssh_router.sh index e0efab7..b2245bf 100755 --- a/ssh_router.sh +++ b/ssh_router.sh @@ -12,6 +12,12 @@ log() { echo "[$(date '+%Y-%m-%d %H:%M:%S')] $*" >>"$LOG_FILE" } +if [[ ! -t 0 ]]; then + log "❌ No TTY allocated — refusing to run tmux without an interactive terminal" + echo "Error: No TTY. Use 'ssh -t'" >&2 + exit 1 +fi + # log "🧩 IMAGE = '$IMAGE'" # log "🧩 WORKSPACE = '$WORKSPACE'" # log "🧩 PERSON = '$PERSON'"