help-cfengine
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: copy:?


From: Tod Oace
Subject: Re: copy:?
Date: Wed, 5 May 2004 14:50:55 -0700

You could implement a method to do this!

Er... <light bulb>
Ah! Very cool! So instead of using cfrun I would just have the master call a method on the slaves that update their copies of /var/cfengine/cvsexport/. Nice and clean. I'll give it a try. Thanks!
-Tod


M

On  4 May, Tod Oace wrote:
On May 4, 2004, at 08:42, Mike wrote:

My site has many shell scripts that I want preserved
in CVS. My first thought was to do a 'cvs co' on each
server prior to running cfagent, then copy files to
the proper locations as necessary.

I have a cfengine master and several cfengine slaves. My master does
"cvs co" into /var/cfengine/cvsexport/ and my slaves copy: that.
Clients copy: from the slaves.

Now I'm wondering
about using cfservd with cfagent to get the files
directly from the cvshost.

Seems like it would be cool if cfengine knew how to copy out of CVS
repositories directly. It seems like it would help with rolling out new
versions of things out in a controlled manner. On the other hand,
having the separate checkout directory is simple and is working fine
for me.

I guess I need to do a
'cvs co' from cron with some frequency to keep the
repository for cfservd current, or is there another
way?

My master updates its own cvs workspace every time its cfagent runs. I
also have CVS run cfagent every time a change is checked in. And I use
cfrun to have the slaves update whenever the master updates. I have
cron run cfexecd every half hour. There are quirks here and there, but
overall it's working out very nicely.

My update.conf includes the following. I would love to see any ideas
for improvement!

control:
         cvs_dir         = ( /var/cfengine/cvsexport )


shellcommands:
         master::
                 "/usr/bin/cvs -d /var/cvsroot -q checkout ."
chdir=${cvs_dir}
                 "/usr/local/sbin/cfrun -S -T -- --silent -- slave
/dev/null"

copy:
         slave::
                 ${cvs_dir}
                         dest=${cvs_dir}
                         server=${server}
                         recurse=inf
                         trustkey=on
                         purge=on
                         backup=false
                         timestamps=preserve
                         inform=on


Mike




~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Work: +47 22453272            Email:  Mark.Burgess@iu.hio.no
Fax : +47 22453205            WWW  :  http://www.iu.hio.no/~mark
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


--
Tod Oace, Intel Corporation <tod@intel.com>





reply via email to

[Prev in Thread] Current Thread [Next in Thread]