We have a current setup that works using Ansible v2.0.0 in which we specify ansible_ssh_user in inventory exactly as follows.
ansible_ssh_user: user@realm
When running playbooks we use kinit to get a kerberos ticket using real credentials (
myrea...@myrealdomain.com) and everything works.
That is ansible uses the kerberos ticket for
myrea...@myrealdomain.com and we can successfully connect to Windows servers.
However, behavior in Ansible 2.1 and 2.2 is different. When using the newer versions, Ansible tries to connect with the fake user@realm username, ignoring our kerberos ticket and hence failing to connect.
- changing ansible_ssh_user to ansible_user makes no difference
- specifying the
myrea...@myrealdomain.com with the -u option on the command line makes no difference
What does work is setting ansible_user to
myrea...@myrealdomain.com in the inventory. However, this is problematic as we have several users and don't want to have to constantly change our inventory depending on which user is actually running playbooks.
Am I missing something or did something change in regards to behavior? Is there some way to get the old behavior?
Thanks.