Hi,
My ssh.config
Host bastion
User ansible
HostName bastion-server
ProxyCommand none
IdentityFile ~/.ssh/id_rsa
BatchMode yes
PasswordAuthentication no
Host *
ServerAliveInterval 60
TCPKeepAlive yes
ProxyCommand ssh -q -A root@bastion nc %h %p
ControlMaster auto
ControlPath ~/.ssh/mux-%r@%h:%p
ControlPersist 8h
User root
StrictHostKeyChecking no
My ansible.cfg
[default]
hash_behaviour=merge
transport=ssh
[ssh_connection]
ssh_args = -o ControlPersist=15m -F ssh.config -q
scp_if_ssh = True
control_path = ~/.ssh/mux-%%r@%%h:%%p
When I run ssh bastion -F ssh.config I can connect with success.
When I run ansible -i ./ meta_Pool_wearezoneeu -m setup -vvvv it gives following error:
ERROR! ERROR! ./ssh.config:1: Expected key=value host variable assignment, got: bastion
No idea why this happens. Anyone experienced a similar thing or can point me into the right direction?