[Csync2] Using variables in configuration file
Lars Ellenberg
lars.ellenberg at linbit.com
Wed Jul 15 23:53:08 CEST 2015
On Tue, Jul 14, 2015 at 10:29:08AM -0700, David Winslow wrote:
> Is it possible to use variables in the csync2 configuration file.
>
> I want to synchronize files in a user’s home directory.
>
> Example configuration below. I want to run this as root so as to not have a configuration/db for every user.
>
> group home_dir_files {
>
> host rnd11 (rnd10);
>
> key /etc/csync-group.key
>
> include /home/$USER/cluster_configuration_file.txt
>
> }
>
> So as user, myuser, I would run
>
> sudo /usr/sbin/csync2 -xvG home_dir_files
>
> This is not working for me. Should it work?
No.
And I don't see any sane way to implement something like that for csync2.
But you can use wildcards. Something like that: /home/*/**
> For now, I’ve created a
> group for each user since I only have two users right now. Obviously,
> this alternative is not a scalable solution.
--
: Lars Ellenberg
: http://www.LINBIT.com | Your Way to High Availability
: DRBD, Linux-HA and Pacemaker support and consulting
DRBD® and LINBIT® are registered trademarks of LINBIT, Austria.
More information about the Csync2
mailing list