[ansible-project] Re: Copy files from windows machine to linux machine using ansible

2018-03-14 Thread Jordan Borean
If you can share the error we may be able to help, my thoughts are the 
delegate_to isn't needed and the src path is inavlid but without any more 
info we can't really help.

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ansible-project+unsubscr...@googlegroups.com.
To post to this group, send email to ansible-project@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/ff63bea2-104d-4bfd-90f8-22f92f3c7be5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[ansible-project] Re: Copy files from windows machine to linux machine using ansible

2018-03-13 Thread Ricky V.
But this won't run and there's no error,

--- 
- hosts: windows
  tasks:
 - name: copy file back to ansible machine from windows
   fetch: 
  src: \path\to\file\on\windows\machine
  dest: /destination/directory/on/ansible/controller
  flat: yes
   delegate_to: ansible_hostname

Any idea if you want to get the data from multiple windows server?

On Wednesday, November 9, 2016 at 12:44:14 PM UTC-5, J Hawkesworth wrote:
>
> This ought to do it (not tested).
>
> Jon
> --- 
> - hosts: windows
>   tasks:
>  - name: copy file back to ansible machine from windows
>fetch: 
>   src: \path\to\file\on\windows\machine
>   dest: /destination/directory/on/ansible/controller
>   flat: yes
>delegate_to: a_windows_host
>
>
>
>
> On Wednesday, November 9, 2016 at 1:25:34 PM UTC, Vigneshwar V wrote:
>>
>> Can you tell me what are the changes you made
>>
>> On Tuesday, 26 April 2016 09:43:06 UTC+5:30, Mick st john wrote:
>>>
>>> I did some changes and it worked. But, the whole directory is getting 
>>> created on the linux machine which has the desired file. 
>>>
>>>
>>> On Tuesday, April 26, 2016 at 9:34:12 AM UTC+5:30, Mick st john wrote:

 I tried the following playbook:

 --- 
 - hosts: windows
   tasks:
  - name: copy file
fetch: src=\path\to\file\on\windows\machine 
 dest=/destination/directory

 But, somehow it failed. Am I doing it the wrong way?

 On Monday, April 25, 2016 at 8:24:58 PM UTC+5:30, J Hawkesworth wrote:
>
> Fetch can also fetch from windows machines back to your ansible 
> controller machine.
>
> If you are fetching from > 1 windows box don't forget to fetch to a 
> directory, or use something like {{ inventory_hostname_short }} when 
> generating the file name.
>
> Hope this helps,
>
> Jon
>
>
> On Monday, April 25, 2016 at 3:06:04 PM UTC+1, Mick st john wrote:
>>
>> I trying to copy files from a remote windows machine to my local 
>> machine(linux machine) using ansible. As fetch module works for linux to 
>> linux file transfer, is there anything similar that could enable me to 
>> fetch files from windows machine to linux machine?
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ansible-project+unsubscr...@googlegroups.com.
To post to this group, send email to ansible-project@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/21e939b7-846a-4d09-a47e-cd9371554af1%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[ansible-project] Re: Copy files from windows machine to linux machine using ansible

2016-11-09 Thread 'J Hawkesworth' via Ansible Project
This ought to do it (not tested).

Jon
--- 
- hosts: windows
  tasks:
 - name: copy file back to ansible machine from windows
   fetch: 
  src: \path\to\file\on\windows\machine
  dest: /destination/directory/on/ansible/controller
  flat: yes
   delegate_to: a_windows_host




On Wednesday, November 9, 2016 at 1:25:34 PM UTC, Vigneshwar V wrote:
>
> Can you tell me what are the changes you made
>
> On Tuesday, 26 April 2016 09:43:06 UTC+5:30, Mick st john wrote:
>>
>> I did some changes and it worked. But, the whole directory is getting 
>> created on the linux machine which has the desired file. 
>>
>>
>> On Tuesday, April 26, 2016 at 9:34:12 AM UTC+5:30, Mick st john wrote:
>>>
>>> I tried the following playbook:
>>>
>>> --- 
>>> - hosts: windows
>>>   tasks:
>>>  - name: copy file
>>>fetch: src=\path\to\file\on\windows\machine 
>>> dest=/destination/directory
>>>
>>> But, somehow it failed. Am I doing it the wrong way?
>>>
>>> On Monday, April 25, 2016 at 8:24:58 PM UTC+5:30, J Hawkesworth wrote:

 Fetch can also fetch from windows machines back to your ansible 
 controller machine.

 If you are fetching from > 1 windows box don't forget to fetch to a 
 directory, or use something like {{ inventory_hostname_short }} when 
 generating the file name.

 Hope this helps,

 Jon


 On Monday, April 25, 2016 at 3:06:04 PM UTC+1, Mick st john wrote:
>
> I trying to copy files from a remote windows machine to my local 
> machine(linux machine) using ansible. As fetch module works for linux to 
> linux file transfer, is there anything similar that could enable me to 
> fetch files from windows machine to linux machine?
>


-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ansible-project+unsubscr...@googlegroups.com.
To post to this group, send email to ansible-project@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/3659cb2e-a379-488d-85f1-cc281b8316a0%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[ansible-project] Re: Copy files from windows machine to linux machine using ansible

2016-11-09 Thread Vigneshwar V
Can you tell me what are the changes you made

On Tuesday, 26 April 2016 09:43:06 UTC+5:30, Mick st john wrote:
>
> I did some changes and it worked. But, the whole directory is getting 
> created on the linux machine which has the desired file. 
>
>
> On Tuesday, April 26, 2016 at 9:34:12 AM UTC+5:30, Mick st john wrote:
>>
>> I tried the following playbook:
>>
>> --- 
>> - hosts: windows
>>   tasks:
>>  - name: copy file
>>fetch: src=\path\to\file\on\windows\machine 
>> dest=/destination/directory
>>
>> But, somehow it failed. Am I doing it the wrong way?
>>
>> On Monday, April 25, 2016 at 8:24:58 PM UTC+5:30, J Hawkesworth wrote:
>>>
>>> Fetch can also fetch from windows machines back to your ansible 
>>> controller machine.
>>>
>>> If you are fetching from > 1 windows box don't forget to fetch to a 
>>> directory, or use something like {{ inventory_hostname_short }} when 
>>> generating the file name.
>>>
>>> Hope this helps,
>>>
>>> Jon
>>>
>>>
>>> On Monday, April 25, 2016 at 3:06:04 PM UTC+1, Mick st john wrote:

 I trying to copy files from a remote windows machine to my local 
 machine(linux machine) using ansible. As fetch module works for linux to 
 linux file transfer, is there anything similar that could enable me to 
 fetch files from windows machine to linux machine?

>>>

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ansible-project+unsubscr...@googlegroups.com.
To post to this group, send email to ansible-project@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/8f07e822-e163-4f7e-8e77-6faddd1626df%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[ansible-project] Re: Copy files from windows machine to linux machine using ansible

2016-04-25 Thread Mick st john
 I used flat=yes and the issue is now resolved. Thank you!

On Tuesday, April 26, 2016 at 9:43:06 AM UTC+5:30, Mick st john wrote:
>
> I did some changes and it worked. But, the whole directory is getting 
> created on the linux machine which has the desired file. 
>
>
> On Tuesday, April 26, 2016 at 9:34:12 AM UTC+5:30, Mick st john wrote:
>>
>> I tried the following playbook:
>>
>> --- 
>> - hosts: windows
>>   tasks:
>>  - name: copy file
>>fetch: src=\path\to\file\on\windows\machine 
>> dest=/destination/directory
>>
>> But, somehow it failed. Am I doing it the wrong way?
>>
>> On Monday, April 25, 2016 at 8:24:58 PM UTC+5:30, J Hawkesworth wrote:
>>>
>>> Fetch can also fetch from windows machines back to your ansible 
>>> controller machine.
>>>
>>> If you are fetching from > 1 windows box don't forget to fetch to a 
>>> directory, or use something like {{ inventory_hostname_short }} when 
>>> generating the file name.
>>>
>>> Hope this helps,
>>>
>>> Jon
>>>
>>>
>>> On Monday, April 25, 2016 at 3:06:04 PM UTC+1, Mick st john wrote:

 I trying to copy files from a remote windows machine to my local 
 machine(linux machine) using ansible. As fetch module works for linux to 
 linux file transfer, is there anything similar that could enable me to 
 fetch files from windows machine to linux machine?

>>>

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ansible-project+unsubscr...@googlegroups.com.
To post to this group, send email to ansible-project@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/f2e44c3f-72f6-4cb3-9aeb-59f85d312a85%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[ansible-project] Re: Copy files from windows machine to linux machine using ansible

2016-04-25 Thread Mick st john
I did some changes and it worked. But, the whole directory is getting 
created on the linux machine which has the desired file. 


On Tuesday, April 26, 2016 at 9:34:12 AM UTC+5:30, Mick st john wrote:
>
> I tried the following playbook:
>
> --- 
> - hosts: windows
>   tasks:
>  - name: copy file
>fetch: src=\path\to\file\on\windows\machine 
> dest=/destination/directory
>
> But, somehow it failed. Am I doing it the wrong way?
>
> On Monday, April 25, 2016 at 8:24:58 PM UTC+5:30, J Hawkesworth wrote:
>>
>> Fetch can also fetch from windows machines back to your ansible 
>> controller machine.
>>
>> If you are fetching from > 1 windows box don't forget to fetch to a 
>> directory, or use something like {{ inventory_hostname_short }} when 
>> generating the file name.
>>
>> Hope this helps,
>>
>> Jon
>>
>>
>> On Monday, April 25, 2016 at 3:06:04 PM UTC+1, Mick st john wrote:
>>>
>>> I trying to copy files from a remote windows machine to my local 
>>> machine(linux machine) using ansible. As fetch module works for linux to 
>>> linux file transfer, is there anything similar that could enable me to 
>>> fetch files from windows machine to linux machine?
>>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ansible-project+unsubscr...@googlegroups.com.
To post to this group, send email to ansible-project@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/aacc5b42-2888-41da-b5f0-18b41f329ff9%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[ansible-project] Re: Copy files from windows machine to linux machine using ansible

2016-04-25 Thread Mick st john
I tried the following playbook:

--- 
- hosts: windows
  tasks:
 - name: copy file
   fetch: src=\path\to\file\on\windows\machine 
dest=/destination/directory

But, somehow it failed. Am I doing it the wrong way?

On Monday, April 25, 2016 at 8:24:58 PM UTC+5:30, J Hawkesworth wrote:
>
> Fetch can also fetch from windows machines back to your ansible controller 
> machine.
>
> If you are fetching from > 1 windows box don't forget to fetch to a 
> directory, or use something like {{ inventory_hostname_short }} when 
> generating the file name.
>
> Hope this helps,
>
> Jon
>
>
> On Monday, April 25, 2016 at 3:06:04 PM UTC+1, Mick st john wrote:
>>
>> I trying to copy files from a remote windows machine to my local 
>> machine(linux machine) using ansible. As fetch module works for linux to 
>> linux file transfer, is there anything similar that could enable me to 
>> fetch files from windows machine to linux machine?
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ansible-project+unsubscr...@googlegroups.com.
To post to this group, send email to ansible-project@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/9ba7a339-d176-4707-81ba-1eb4d8d3b4ea%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[ansible-project] Re: Copy files from windows machine to linux machine using ansible

2016-04-25 Thread 'J Hawkesworth' via Ansible Project
Fetch can also fetch from windows machines back to your ansible controller 
machine.

If you are fetching from > 1 windows box don't forget to fetch to a 
directory, or use something like {{ inventory_hostname_short }} when 
generating the file name.

Hope this helps,

Jon


On Monday, April 25, 2016 at 3:06:04 PM UTC+1, Mick st john wrote:
>
> I trying to copy files from a remote windows machine to my local 
> machine(linux machine) using ansible. As fetch module works for linux to 
> linux file transfer, is there anything similar that could enable me to 
> fetch files from windows machine to linux machine?
>

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ansible-project+unsubscr...@googlegroups.com.
To post to this group, send email to ansible-project@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/d679c2e6-8656-4685-a3a7-40cc6d7b8b96%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.