ansible – check if file exists on *local* machine
Delegating the tasks to the localhost via the delegate_to statement should do what you want: – name: Check for ~/.blah/config delegate_to: localhost stat: path: /home/ubuntu/.blah/config register: stat_blah_config