help-cfengine
[Top][All Lists]
Advanced

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

Re: Puzzler: Can cfengine replace make?


From: Mark . Burgess
Subject: Re: Puzzler: Can cfengine replace make?
Date: Wed, 7 Nov 2001 09:27:00 +0100 (MET)

On  6 Nov, Steve Traugott wrote:
> On Tue, Nov 06, 2001 at 11:22:17AM -0800, Marion Hakanson wrote:
>> Steve Traugott wrote:
>> 
>> > (Cc'ing to both help-cfengine@gnu.org and infrastructures@terraluna.org).
>> > 
>> > Many of us commonly use 'make' as a state engine for tracking
>> > long-term dependencies over the life of a machine.  For instance,
>> > here's a fragment of a real-world makefile, used in a AIX environment,
>> > . . .
>> > Now, here's the question:  Can anyone see a way to do this once-only
>> > type of action cleanly in cfengine?  I've tried several different ways
>> > over the years, but I've never been satisfied with the results.  
>> > 
>> > Steve
>> 
>> Folks,
>> 
>> We've also been frustrated here with cfengine's apparently not having a
>> way to represent make-like semantics ("update this item only if it's older
>> than the source").  A former colleague came up with a trick for dealing
>> with this issue in the "editfiles:" section of a cfengine file, basically
>> by embedding a timestamp within the file being edited.  Here's an excerpt:
> 
> Here's something interesting -- the usage we're making of 'make' is
> explicitly *not* the "update if older" feature; we've always done a
> 'touch *' in the stamps directory before kicking off 'make'.  With
> most packaging tools you don't want to try to re-install things that
> are already installed.  Really all I'm looking for is a binary state
> engine -- similar to cfengine's classes but with persistent memory.

CFengine 2 effectively has persistent memory, but it depends a little
what you mean.

> What I've wound up doing sometimes, for instance, is driving multiple
> cfengine (and other) scripts from 'make'.  Each script has it's own
> special purpose, like managing the install of a particular app, which
> keeps things modularized, while 'make' takes care of stamping and
> lifetime ordering.
> 
> Steve

That, at least, takes care of the convergence problem. Then
the main difference in using make is a conceptual one.

Several issues to do with scheduling and dependency are
much more powerful in cfengine 2. This is one of the areas
that I wanted to address. Some of the new features are
documented in the seatchable index dox, but only superficially.

Mark


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





reply via email to

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