fix(backups): forward per-backup timeout to the ssh timeout wrapper

instant_remote_process() applied its timeout only to Process::timeout(), while the shell-level timeout wrapper around ssh always used the global 3600s default, killing long backups and scheduled tasks at 1h with ssh exit code 255. Also applies the backup timeout to the S3 upload step and makes the default configurable via SSH_COMMAND_TIMEOUT.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
Himanshu Ahuja
2026-08-10 18:28:27 -04:00
co-authored by Claude Fable 5
parent 32bf1860d4
commit 419106696a
4 changed files with 106 additions and 3 deletions
+1 -1
View File
@@ -177,7 +177,7 @@ function instant_remote_process(Collection|array $command, Server $server, bool
return SshRetryHandler::retry(
function () use ($server, $command_string, $effectiveTimeout, $disableMultiplexing) {
$sshCommand = SshMultiplexingHelper::generateSshCommand($server, $command_string, $disableMultiplexing);
$sshCommand = SshMultiplexingHelper::generateSshCommand($server, $command_string, $disableMultiplexing, (int) $effectiveTimeout);
$process = Process::timeout($effectiveTimeout)->run($sshCommand);
$output = trim($process->output());