brought back use of 'local_facts' variable to make use of local, control node user running plays for path completion

This commit is contained in:
2026-06-10 14:08:01 -04:00
parent 9942fd94f8
commit f455483d66

View File

@@ -6,7 +6,7 @@
delegate_facts: true
delegate_to: localhost
ansible.builtin.find:
paths: "{{ local_facts['user_dir'] }}/.ssh" # @TODO define 'cnode_homedir' in playbook
paths: "{{ local_facts['user_dir'] | default(lookup('env', 'HOME')) }}/.ssh" # @TODO define 'cnode_homedir' in playbook
patterns: "{{ ['^'] | product(ssh_keys) | map('join') | list }}"
file_type: file
use_regex: true