remote1 ->fetch-> control machine ->copy-> remote2

Hello!

I have 2 remote hosts and 1 master node with my playbooks. I want that file with name “.env” was copy with module “Fetch” to Master node and then, with module “copy” will copy to Remote host 2

hosts:

[jitsi]
185.139.68.189

[VideoBridge2]
46.17.104.103

[Jitsi_Stack]
185.139.68.189
46.17.104.103

[jitsi:vars]
ansible_python_interpreter=/usr/bin/python3

[VideoBridge2:vars]
ansible_python_interpreter=/usr/bin/python3

My playbook:

The issue is that it cannot find the files as it’s expecting a single file which name is “.env”
If you want to copy all files with that extension you may need a different solution. Have a look here: https://stackoverflow.com/questions/54152051/ansible-fetch-a-collection-of-files-to-the-destination-without-copying-remote