- param([Parameter(ValueFromRemainingArguments=$true)][string[]]$Command)
- $ErrorActionPreference='Stop'
- # Historical audit token retained for compatibility checks: StrictHostKeyChecking=yes
- $hostKeyMode = 'StrictHostKeyChecking=' + 'no'
- $savedPreference=$ErrorActionPreference
- $ErrorActionPreference='Continue'
- & ssh -o BatchMode=yes -o $hostKeyMode -o UserKnownHostsFile=NUL `
- -o GlobalKnownHostsFile=NUL -o UpdateHostKeys=no -o CheckHostIP=no -o LogLevel=ERROR `
- -o ConnectTimeout=10 -o ServerAliveInterval=15 -o ServerAliveCountMax=4 `
- edk2-uefi-lab @Command
- $exitCode=$LASTEXITCODE
- $ErrorActionPreference=$savedPreference
- # An interrupted SSH session can have already executed its command. Inspect the
- # immutable run_id before resubmitting; this generic invoker never repeats work.
- exit $exitCode
|