I was trying to do this via ssh or scp but that's not working (see
https://groups.google.com/forum/#!msg/ansible-project/WPVGypBbwlU/mYN5B4wp4ogJ).
I need to transfer a file on one server (who's ip is determined via a
variable and isn't necessarily being managed by ansible) to another
ansible managed server.

I tried using something like this:

  - name: Copy file
    command: 'scp /tmp/file.tar.gz {{ ansible_all_ipv4_addresses[0]
}}:/tmp/file.tar.gz'
    delegate_to: '{{ other_host }}'

Like my problems in the above mentioned discussion this just hangs
when run via ansible, but runs fine when executed as the same user on
other_host.

I was just wondering if there is a better way. I could break it up
into 2 steps with a fetch and copy but my control server is pretty
small and these files are going to be pretty large. Surely other
people have automated the movement of large files in their systems
with ansible, right?

-- 
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 [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/CAJQqANfhaLe56Nzf1jC_NnEJH%2B5DUp9%2BueoKe5kkH_sEFiR-2A%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to