Currently, agent-rdp automate run '$PSVersionTable' --wait is hard-coded to use powershell.exe:
|
$startInfo = New-Object System.Diagnostics.ProcessStartInfo |
|
$startInfo.FileName = "powershell.exe" |
|
$startInfo.Arguments = "-NoProfile -Command `"$command $commandArgs`"" |
That artificially limits what can be executed.
Can we instead run any command? For example, I want to use pwsh.exe instead of powershell.exe.
If that's welcomed, I can try to create a PR.
Currently,
agent-rdp automate run '$PSVersionTable' --waitis hard-coded to usepowershell.exe:agent-rdp/crates/agent-rdp-daemon/src/automation/scripts/lib/actions.ps1
Lines 542 to 544 in e4c45f9
That artificially limits what can be executed.
Can we instead run any command? For example, I want to use
pwsh.exeinstead ofpowershell.exe.If that's welcomed, I can try to create a PR.