# synchronize module and delegate\_to: seems to not respect become\_user ansible 2.3.1.0

**URL:** <https://forum.ansible.com/t/synchronize-module-and-delegate-to-seems-to-not-respect-become-user-ansible-2-3-1-0/25201>\
**Category:** Ansible Project\
**Created:** [August 8, 2017, 7:06am UTC](https://forum.ansible.com/t/synchronize-module-and-delegate-to-seems-to-not-respect-become-user-ansible-2-3-1-0/25201 "2017-08-08T07:06:48Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Gary\_Hawker](https://avatars.discourse-cdn.com/v4/letter/g/aca169/32.png) [@Gary\_Hawker](https://forum.ansible.com/u/Gary_Hawker)\
**Post date:** [August 8, 2017, 7:06am UTC](https://forum.ansible.com/t/synchronize-module-and-delegate-to-seems-to-not-respect-become-user-ansible-2-3-1-0/25201/1 "2017-08-08T07:06:48Z")

</div>

Hi All

ansible 2.3.1.0

seems to not respect the become\_user in the following play.

#note that this below jams up because it expects accounts and ssh keys as it uses rsync underwater. Figure that out then remove this comment

- name: copy dump to remote  
become: false  
become\_user: fresh-dbs  
synchronize:  
mode: push  
src: “{{ hostvars[‘192.168.56.100’].dbdump.stat.path }}”  
dest: /tmp/restore.sql  
delegate\_to: 192.168.56.100  
tags: rsync  
My expectation on the above is that on the delegate host, the rsync job should trigger as the user ‘fresh-dbs’ (which is created and key’d earlier in the play  
and can login to the target.

What really happens is that it just runs as my ansible control user and fails out.

Anyone know how to elegantly deal with this? I want to copy a file from one host to another without using the control machine.

---

<div class="post-metadata">

**Author:** ![Kai\_Stian\_Olstad](https://avatars.discourse-cdn.com/v4/letter/k/e19adc/32.png) [@Kai\_Stian\_Olstad](https://forum.ansible.com/u/Kai_Stian_Olstad)\
**Post date:** [August 8, 2017, 12:56pm UTC](https://forum.ansible.com/t/synchronize-module-and-delegate-to-seems-to-not-respect-become-user-ansible-2-3-1-0/25201/2 "2017-08-08T12:56:45Z")

</div>

To use become\_user you need to set become: true

---

<div class="post-metadata">

**Author:** ![Gary\_Hawker](https://avatars.discourse-cdn.com/v4/letter/g/aca169/32.png) [@Gary\_Hawker](https://forum.ansible.com/u/Gary_Hawker)\
**Post date:** [August 9, 2017, 7:52am UTC](https://forum.ansible.com/t/synchronize-module-and-delegate-to-seems-to-not-respect-become-user-ansible-2-3-1-0/25201/3 "2017-08-09T07:52:28Z")

</div>

Ah, bad paste job on that one I've been experimenting with every different combination. Become is set to try and the result is the same. Doesn't work
