Created
December 6, 2013 22:36
-
-
Save ndobbs/7833333 to your computer and use it in GitHub Desktop.
Ansible 'lookup' function
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ansible_code: | |
- name: Pushing Authorized Keys to remote server(s) | |
action: authorized_key user={{ item }} key="{{ lookup('file', "{{ item }}/id_rsa.pub") }}" | |
with_items: | |
- '{{ admins }}' | |
output: | |
fatal: [54.201.43.177] => /Users/ndobbs/src/hc1dev/ansible/roles/common/files/{{item}}/id_rsa.pub does not exist |
drybjed
commented
Dec 6, 2013
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment