From e5b2e4c1acac3cf95751ebcaa32c9e9e6b15746b Mon Sep 17 00:00:00 2001 From: Pilou Date: Wed, 29 May 2019 16:15:45 +0000 Subject: [PATCH] tower_credential: ssh_key_data isn't a path anymore (#57113) --- .../web_infrastructure/ansible_tower/tower_credential.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ansible/modules/web_infrastructure/ansible_tower/tower_credential.py b/lib/ansible/modules/web_infrastructure/ansible_tower/tower_credential.py index a8bdd1e5b5..32c9cf817f 100644 --- a/lib/ansible/modules/web_infrastructure/ansible_tower/tower_credential.py +++ b/lib/ansible/modules/web_infrastructure/ansible_tower/tower_credential.py @@ -168,7 +168,7 @@ EXAMPLES = ''' - name: Add Credential Into Tower tower_credential: name: Workshop Credential - ssh_key_data: "/home/{{ansible_user}}/.ssh/aws-private.pem" + ssh_key_data: "{{ lookup('file', '/home/' ~ {{ansible_user}} ~ '/.ssh/aws-private.pem') }}" kind: ssh organization: Default tower_username: admin