298 B
298 B
ansible.builtin.exists
Check if the provided path maps to an existing filesystem object on the controller (localhost).
Examples
vars:
my_etc_hosts_exists: "{{ '/etc/hosts' is exist }}"
list_of_local_files_to_copy_to_remote: "{{ list_of_all_possible_files | select('exists') }}"