Answer the question
In order to leave comments, you need to log in
Ansible. Copy folder from remote windows machine?
Hello! I need to collect data from remote Windows machines to the server, tell me what I'm doing wrong?
Is this a problem because I'm trying to work with Windows?
---
- name: Copy server file version control
synchronize:
src: '/TEMP'
dest: 'D:/ansibleMQ/version_control'
mode: pull
when: "((ansible_os_family == 'Windows'))"
fatal: [host .IRUS.ESB.GW1]: FAILED! => {"changed": false, "msg": "synchronize uses rsync to function. rsync needs to connect to the remote host via ssh, docker client or a direct filesystem copy. This remote host is being accessed via winrm instead so it cannot work."}
fatal: [host.IRUS.ESB.GW2]: FAILED! => {"changed": false, "msg": "synchronize uses rsync to function. rsync needs to connect to the remote host via ssh, docker client or a direct filesystem copy. This remote host is being accessed via winrm instead so it cannot work."}
Answer the question
In order to leave comments, you need to log in
Try using fetch
https://docs.ansible.com/ansible/2.5/modules/fetch...
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question