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
Owner

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).

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).
rafaga21 added 1 commit 2026-06-11 18:53:15 -04:00
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).
rafaga21 merged commit 00062e4d4a into master 2026-06-11 18:53:20 -04:00
rafaga21 deleted branch feat/push-monitoring-agent 2026-06-11 18:53:21 -04:00
Sign in to join this conversation.
No Reviewers
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: devlab/server-manager#38