Hi,
I’ve noticed that Ansible isn’t using ControlMaster in my local setup, making it slower than it needs to be.
This is Ansible 1.6.1, running on OS X 10.9.3 and connecting to remote hosts running CentOS 6.
If I connect to the remote host and tail -f /var/log/secure I can see tell-tale Accepted publickey for ec2-user entries getting added over and over again during Ansible runs.
I tried overriding the ssh_connection ssh_args setting to specify a specific ControlMaster path as suggested in the docs, but the only thing that works is setting up a specific entry in ~/.ssh/config for the hosts I’m connecting to with (something like):
Host *
ControlMaster auto
ControlPath ~/.ssh/%r@%h:%p
ControlPersist 240
Any ideas why not this explicit set-up in ansible.cfg has any effect?
[ssh_connection]
ssh_args = -vvvv -o ControlMaster=auto -o ControlPersist=60s
control_path = %(directory)s/%%h-%%r