fix: allocate PTY for agent install to work with sudo requiretty #38

Merged
rafaga21 merged 1 commits from feat/push-monitoring-agent into master 2026-06-11 18:53:20 -04:00

1 Commits

Author SHA1 Message Date
63bf125420 fix: allocate PTY for agent install to work with sudo requiretty
The remote server has 'Defaults requiretty' in sudoers, which prevents
sudo from running without a TTY. Modified SSHService::exec() to accept
an optional  parameter that allocates a pseudo-terminal, and
extracts the exit status from output when PTY is used (since phpseclib
doesn't return exit status in PTY mode).
2026-06-11 18:52:40 -04:00