CFEngine Help: Thoughts about some cfengine design decisions?

2011-12-14 Thread no-reply
Forum: CFEngine Help Subject: Thoughts about some cfengine design decisions? Author: lauwersw Link to topic: https://cfengine.com/forum/read.php?3,24285,24285#msg-24285 I'm working for about a year with cfengine community now and I have implemented some pretty complex stuff in it. While I do like

Is this the idiom for if...else?

2011-12-14 Thread Mark Dixon
Hi, I'm a newbie trying to figure out if I can migrate from some in-house scripts to cfengine3 for configuration management. As such, I'm struggling a little to think in the "cfengine3 way". What is the idiomatic way of doing if...else statements in cfengine3? Is it inventing a default class,

Re: Is this the idiom for if...else?

2011-12-14 Thread Mark Dixon
On Wed, 14 Dec 2011, Mark Burgess wrote: > > Mark, see this doc: > > http://www.cfengine.com/manuals/st-devops.html#Getting-used-to-declarative-expression > > M Thanks Mark, much appreciated: I had missed the link to the special topics guides. However, it wasn't the "if" bit I was fuzzy about,

Re: CFEngine Help: Thoughts about some cfengine design decisions?

2011-12-14 Thread Marco Marongiu
Hi I can't be as specific as lauwersw. I've been a cfengine2 user for some time, but my experience with cfengine3 is still too small. 1) So, on a general note, and resuming what I already said in other threads, simple file editing is sometimes too hard. E.g.: placing pieces of text in a very well

Re: CFEngine Help: Thoughts about some cfengine design decisions?

2011-12-14 Thread Mark Burgess
Thanks for good feedback. Can you elaborate at all on what topics you would like to see in a better tutorial? M On 12/14/2011 11:28 AM, Marco Marongiu wrote: > Hi > > I can't be as specific as lauwersw. I've been a cfengine2 user for some > time, but my experience with cfengine3 is still too sm

Re: CFEngine Help: Thoughts about some cfengine design decisions?

2011-12-14 Thread Marco Marongiu
On 14/12/11 11:30, Mark Burgess wrote: > Thanks for good feedback. Can you elaborate at all on what topics you > would like to see in a better tutorial? I can try. The current tutorial talks a lot about a lot of things, but concrete examples don't have even a single, full section. A few trivial

CFEngine Help: Re: Thoughts about some cfengine design decisions?

2011-12-14 Thread no-reply
Forum: CFEngine Help Subject: Re: Thoughts about some cfengine design decisions? Author: Beto Link to topic: https://cfengine.com/forum/read.php?3,24285,24291#msg-24291 I couldn't agree more on items 1) and 2). These kinds of purely arbitrary design decisions (I haven''t seen a single post sugge

Re: CFEngine Help: Thoughts about some cfengine design decisions?

2011-12-14 Thread Jim Wildman
I'd add one more. Make sure all the tutorials work. Hand them to a random sysadmin and have him do them verbatim. Last I checked (about a year ago) I could not find a single tutorial on the cfengine site that would work as written on a generic install. The new bootstrap code is a nice start, but

Re: Is this the idiom for if...else?

2011-12-14 Thread Ted Zlatanov
On Wed, 14 Dec 2011 10:08:22 + (GMT) Mark Dixon wrote: MD> However, it wasn't the "if" bit I was fuzzy about, it was how people use MD> the language to do the job of an "if..elif..else" construct in the MD> clearest and least fragile way. MD> Extending the example on the devops page naiv

Re: CFEngine Help: Thoughts about some cfengine design decisions?

2011-12-14 Thread Ted Zlatanov
While we're discussing fundamentals... :) Some small ideas I think may be useful to the cfengine users: 1) allow passing body parameters as JSON, not just positional parameters. Take the standard file permissions promise: "$(crond)/cfrun" perms => mo("644","root"); it instead become

Re: CFEngine Help: Thoughts about some cfengine design decisions?

2011-12-14 Thread Nick Anderson
On 12/14/2011 07:58 AM, Ted Zlatanov wrote: > 1) allow passing body parameters as JSON, not just positional > parameters. Take the standard file permissions promise: > > "$(crond)/cfrun" > perms => mo("644","root"); > > it instead becomes: > > "$(crond)/cfrun" > perms =>

Re: Is this the idiom for if...else?

2011-12-14 Thread Mark Dixon
On Wed, 14 Dec 2011, Ted Zlatanov wrote: ... > I try to stay away from inverting classes. Rather, I'll define > something global and then override it for each class that needs it > different. But I've done inversion too, when it's very clear: > > bundle common g > { > classes: > "file_exists"

Re: Is this the idiom for if...else?

2011-12-14 Thread Ted Zlatanov
On Wed, 14 Dec 2011 14:54:02 + (GMT) Mark Dixon wrote: MD> How would you cleanly do an if..elif..else ? The example you give MD> appears to be an if..else. cfengine doesn't have that. It has a switch statement, really, but it will spin through the switch until it's settled (up to 3 passes

Re: Is this the idiom for if...else?

2011-12-14 Thread Mark Dixon
On Wed, 14 Dec 2011, Ted Zlatanov wrote: ... > > MD> What I'm trying to avoid is the situation, like in the example below, > MD> where the "no_file_exists" class expression has to be rewritten > MD> everytime I need to test for another file: > > I understand. Try this, I think it will do what you

CFEngine Help: Re: CFEngine Help: Thoughts about some cfengine design decisions?

2011-12-14 Thread no-reply
Forum: CFEngine Help Subject: Re: CFEngine Help: Thoughts about some cfengine design decisions? Author: rbcarleton Link to topic: https://cfengine.com/forum/read.php?3,24288,24299#msg-24299 I started a bare bones configuration for getting new installations started. It basically just runs an upda

Re: CFEngine Help: Re: CFEngine Help: Thoughts about some cfengine design decisions?

2011-12-14 Thread Jim Wildman
Ditto... http://www.rossberry.com/cfengine/linkindex.php?/cfengine/cfengine_rpms.txt (I see I need to update that to the latest release.) Jim On Wed, 14 Dec 2011, no-re...@cfengine.com wrote: > Forum: CFEngine Help > Subject: Re: CFEngine Help: Thoughts about some cfengine design decisions? >

CFEngine Help: Re: Is this the idiom for if...else?

2011-12-14 Thread no-reply
Forum: CFEngine Help Subject: Re: Is this the idiom for if...else? Author: lauwersw Link to topic: https://cfengine.com/forum/read.php?3,24286,24301#msg-24301 Yes, you can always rely on the order inside one type of actions. ___ Help-cfengine mailing li

CFEngine Help: Policy Servers

2011-12-14 Thread no-reply
Forum: CFEngine Help Subject: Policy Servers Author: tjavo87 Link to topic: https://cfengine.com/forum/read.php?3,24302,24302#msg-24302 Hi All, We would like to have multiple policy servers in our environment to be redundant. I've already read the topic "Multiple Policy Servers" but it doesn't