# rsync file permissions

**URL:** <https://forum.ansible.com/t/rsync-file-permissions/17814>\
**Category:** Ansible Project\
**Created:** [March 23, 2015, 4:57pm UTC](https://forum.ansible.com/t/rsync-file-permissions/17814 "2015-03-23T16:57:33Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![niko.stojanovski](https://avatars.discourse-cdn.com/v4/letter/n/977dab/32.png) [@niko.stojanovski](https://forum.ansible.com/u/niko.stojanovski)\
**Post date:** [March 23, 2015, 4:57pm UTC](https://forum.ansible.com/t/rsync-file-permissions/17814/1 "2015-03-23T16:57:33Z")

</div>

I’m trying to copy over files with rsync. file creates main directory and any additional as catalogs. Owner and permission are set correctly. For now I only have a file in the catalogs directory. When synchronize kicks in it copies over the file, but changes the ownership of the directory and file to 1343414997:1778475765.

---

<div class="post-metadata">

**Author:** ![vaida.dan](https://avatars.discourse-cdn.com/v4/letter/v/5daacb/32.png) [@vaida.dan](https://forum.ansible.com/u/vaida.dan)\
**Post date:** [March 28, 2015, 5:26pm UTC](https://forum.ansible.com/t/rsync-file-permissions/17814/2 "2015-03-28T17:26:48Z")

</div>

try to set owner=no group=no in the synchronize task.

The uid & gid from your host are not reflected on your target system.  
Also, you could condense like:

file: path=/var/www/html/munki\_repo/{{ item }} state=directory owner=munki group=munki recurse=yes  
with\_items:

- catalogs
- icons
