--
You received this message because you are subscribed to the Google Groups "Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/a63e58f0-1da9-40ef-bb4c-b5e99f3b0365%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
On 05/15/2014 09:25 PM, Ugo Bellavance wrote:
> Hi,
>
> I wrote my first puppet module and it is for lsyncd. I know that there
> is already a module for that but I think it was written to manage lsyncd
> and csync2 syncs and I don't really understand everything it it so I
> can't really use it or learn from it. I have been able to create a
> simple module, below is the code from init.pp (I know, I should
> modularize it so that init.pp calls ::install and ::config, but I'll do
> that once the module works as I want). It is actually working, but only
> allows for one sync to be configured. I'd like it to be able to
> configure more than one sync, but since all the configs for lsyncd is in
> one file, I wouldn't know how to do it unless I add some variables
> like $method, $source2, $dest2, $desthost2, $append2 and $method,
> $source3, $dest3, $desthost3, $append3, $method, $sourcex, $destx,
> $desthostx, $appendx. I think someone here would know how to do it.
>
I would suggest you to take a look at concat module.
You have declarer lsyncd class without parameters
class lsyncd {
Regards,
--
You received this message because you are subscribed to the Google Groups "Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/c18e50c3-c978-48ba-9fb9-268d0652747d%40googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/5375265A.6070702%40quake.fr.
I wrote my first puppet module and it is for lsyncd.
Am 15.05.2014 21:25, schrieb Ugo Bellavance:
I wrote my first puppet module and it is for lsyncd.
Just looked into lsyncd and what it can achieve. While I like rsync and use it quite often, there's a better way to mirror directories to multiple destinations: BitTorrent Sync (btsync). btsync uses the BitTorrent algorithm to distribute the contents of a directory to an arbitrary number of other machines, where every other machine starts participating in the distribution process as soon as they have some chunks of the added file(s) available locally, thus producing less load on the originating machine.
I have finally been able to get what I wanted. I open a issue (https://github.com/axkibe/lsyncd/issues/275) on the github project website and the main developper of lsyncd gave me a few lines of code to put in my main config file to have any file in a given directory to be imported in the main config file. Then I created a module, based on a simple apache vhost module that was given as a sample in the "Pro Puppet" book. It works for now, I have to test it more and implement it. If someone would like to have the module I can provide the code, but it may not be good-looking or fully compliant with the highest standards...Thanks for all your help.