From 3581e63ca8bbb390f68cf5d3a45b195db1e83a7f Mon Sep 17 00:00:00 2001 From: Jordan Borean Date: Wed, 24 Jul 2019 10:12:34 +1000 Subject: [PATCH] psexec - update example for for delegation example (#59475) --- lib/ansible/modules/commands/psexec.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ansible/modules/commands/psexec.py b/lib/ansible/modules/commands/psexec.py index ebe50730e5a..61e02642a6e 100644 --- a/lib/ansible/modules/commands/psexec.py +++ b/lib/ansible/modules/commands/psexec.py @@ -281,7 +281,7 @@ EXAMPLES = r''' - name: Download and run ConfigureRemotingForAnsible.ps1 to setup WinRM psexec: - hostname: '{{ ansible_host }}' + hostname: '{{ hostvars[inventory_hostname]["ansible_host"] | default(inventory_hostname) }}' connection_username: '{{ ansible_user }}' connection_password: '{{ ansible_password }}' encrypt: yes