Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add support for the SSH ControlPath connection sharing option
OpenSSH multiplexing needs 3 configuration items: * ControlPath * ControlMaster * ControlPersist Testinfra just uses the last two and this causes that multiplexing is not used: ``` DEBUG testinfra:base.py:288 RUN CommandResult(command=b'ssh -o ControlMaster=auto -o ControlPersist=1200 -o ServerAliveInterval=180 -o StrictHostKeyChecking=no -o User=<reducted> -i \'~/.ssh/<reducted>\' -o ConnectTimeout=10 <reducted> \'sudo /bin/sh -c \'"\'"\'<reducted>\'"\'"\'\'', exit_status=0, stdout=b'<reducted>', stderr=None) ``` In comparison, Ansible uses all 3 parameters: ``` SSH: EXEC ssh -o ControlMaster=auto -o ControlPersist=1200 -o ServerAliveInterval=180 -o StrictHostKeyChecking=no -o StrictHostKeyChecking=no -o 'IdentityFile="<reducted>"' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o 'User="<reducted>"' -o ConnectTimeout=10 -o 'ControlPath="<reducted>/.ansible/cp/%C"' <reducted> ``` With this change the third option to control connection sharing is introduced.
- Loading branch information