LINBIT / csync2

file synchronization tool using librsync and current state databases
GNU General Public License v2.0
145 stars 39 forks source link

exclude wildcard/partial path patterns #28

Open alchemyconsulting opened 4 years ago

alchemyconsulting commented 4 years ago

Hi, I'm trying to sync three nodes of a web cluster with lots of files/directories. There are many instances of the same kind of directory tree (lots of similar vhosts) where we want to exclude certain common directories eg. cache directories.

I've tried using exclude patterns eg: files/cache files/cache/ /files/cache/* /files/cache/

But these directories aren't being excluded. Sample full paths would be something like: /srv/www/vhosts/<domain-name>/<site-name>/html/application/files/cache/... where and change between each vhost directory.

Is this possible with csync2?

rabin-io commented 3 years ago

Never tried it my self, but can you try and use this pattern

/srv/www/vhosts/*/html/application/files/cache/
alchemyconsulting commented 3 years ago

I tried this, as well as **, no luck.