We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent e54ed8e commit 7451611Copy full SHA for 7451611
1 file changed
mpssh
@@ -83,7 +83,7 @@ async def ssh_connect_and_run_command(
83
) -> SSHResult:
84
try:
85
escaped_command = escape_shell_command(command)
86
- ssh_command = f"ssh -o ConnectTimeout={timeout} {host} '{escaped_command}'"
+ ssh_command = f"ssh -o ConnectTimeout={timeout} {host} 'exec \"$SHELL\" -l -c \"{escaped_command}\"'"
87
88
process = await asyncio.create_subprocess_shell(
89
ssh_command,
0 commit comments