Skip to content

Commit

Permalink
Changed local var name to a less common one
Browse files Browse the repository at this point in the history
"users" is a common var name. This local register overwrite the user's input, effectively breaking roles like weareinteractive.users. Since the "users" var name is more meaningful for a end user usage let's rename the register output to a more technical value.
  • Loading branch information
rgarrigue authored Oct 2, 2019
1 parent 66e066f commit a20e3c2
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions tasks/rhosts.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@
command: "awk -F: '{print $1}' /etc/passwd"
changed_when: False
check_mode: False
register: users
register: users_accounts

- name: delete rhosts-files from system | os-09
file:
dest: '~{{ item }}/.rhosts'
state: 'absent'
with_flattened: '{{ users.stdout_lines | default([]) }}'
with_flattened: '{{ users_accounts.stdout_lines | default([]) }}'

- name: delete hosts.equiv from system | os-01
file:
Expand All @@ -20,4 +20,4 @@
file:
dest: '~{{ item }}/.netrc'
state: 'absent'
with_flattened: '{{ users.stdout_lines | default([]) }}'
with_flattened: '{{ users_accounts.stdout_lines | default([]) }}'

0 comments on commit a20e3c2

Please sign in to comment.