knowledge/technology/tools/Ansible/tests/ansible.builtin.exists.md
2023-12-04 11:02:23 +01:00

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') }}"