I just want to know about how to check the file exists or not any directory via ansible code. I have tried with stat module with path "*.test" already but it did not working.
Below is my trying:
- name: Check license file exist or not
stat:
path: /var/www/vb_backup/vb/*.test
register: license
becuase path in stat module needs specific file or directory. I want everyone to help me on this.
Thank you in advance.
Ansible version: ansible 2.8.7