CFEngine Help: Re: Variable Class Names

2011-07-19 Thread no-reply
Forum: CFEngine Help Subject: Re: Variable Class Names Author: zzamboni Link to topic: https://cfengine.com/forum/read.php?3,22838,22859#msg-22859 Thanks for the tip, Ben! This is nice, since it saves the additional canonify() step. ___ Help-cfengine m

CFEngine Help: Re: Variable Class Names

2011-07-19 Thread no-reply
Forum: CFEngine Help Subject: Re: Variable Class Names Author: bbomgardner Link to topic: https://cfengine.com/forum/read.php?3,22838,22858#msg-22858 A quick test shows that that cfengine will actually canonify the string automatically in this case. This is news to me, as I thought that it would

Re: CFEngine Help: Variable Class Names

2011-07-19 Thread Daniel V. Klein
Aleksey is correct here - a string, which may contain variables to be expanded, is interpreted as a class, and the promise is evaluated if the resulting classname is true. So if the variable "foo" contains the 3 letters "baz", then ifvarclass => "foo$(foo)" will allow the promise to be execut

Re: CFEngine Help: Variable Class Names

2011-07-19 Thread Aleksey Tsalolikhin
Thanks for the correction, Seva, I certainly don't want to produce a misunderstanding. Reference manual states: Cfengine 3 has a new class predicate ifvarclass which is ANDed with the normal class expression, and which is evaluated together with the promise. It may contain variabl

CFEngine Help: Re: Variable Class Names

2011-07-19 Thread no-reply
Forum: CFEngine Help Subject: Re: Variable Class Names Author: jordy Link to topic: https://cfengine.com/forum/read.php?3,22838,22855#msg-22855 That is the solution!... thank you so much Diego!! ___ Help-cfengine mailing list Help-cfengine@cfengine.org

RE: Cfengine Help: Re: Making cf-runagent work

2011-07-19 Thread Jerome Yanga
Better yet, you can drop the file argument. # cf-runagent -H node1.cfengine.com -ivo "--no-lock -vf /tmp/templates/copy_local_file_via_cf_runagent.cf.test" Regards, j -Original Message- From: Jerome Yanga Sent: Tuesday, July 19, 2011 10:28 AM To: 'Seva Gluschenko' Cc: 'help-cfengine@cf

CFEngine Help: Re: Variable Class Names

2011-07-19 Thread no-reply
Forum: CFEngine Help Subject: Re: Variable Class Names Author: zzamboni Link to topic: https://cfengine.com/forum/read.php?3,22838,22852#msg-22852 You need to use canonify, and then use the variable in a class expression. Canonify ensures that the string only has characters that are valid in clas

Re: CFEngine Help: Variable Class Names

2011-07-19 Thread Seva Gluschenko
Aleksey, your statement sounds very new to me. IMHO, it may produce severe misunderstanding. The "ifvarclass" attribute does NOT allows one to treat a variable as a class, it only allows to check whether different classes were defined using a variable. 2011/7/19 Aleksey Tsalolikhin : > Hi, jordy

CFEngine Help: Re: How to skip complete "bundle agent" execution depending of a class?

2011-07-19 Thread no-reply
Forum: CFEngine Help Subject: Re: How to skip complete "bundle agent" execution depending of a class? Author: zzamboni Link to topic: https://cfengine.com/forum/read.php?3,22837,22850#msg-22850 I really like using "methods:". It's really useful for breaking up complex policies into logical and mo

Re: CFEngine Help: Variable Class Names

2011-07-19 Thread Aleksey Tsalolikhin
Hi, jordy. Also check out "ifvarclass" promise attribute -- it's for using variables as classes. It's recommended to use it with the canonify function. Best, -at ___ Help-cfengine mailing list Help-cfengine@cfengine.org https://cfengine.org/mailman/list

RE: Cfengine Help: Re: Making cf-runagent work

2011-07-19 Thread Jerome Yanga
Woohoo!!! Of all places to find the answer for this, I found it on the man pages. :) For anyone trying to get this to work, I did not change the cf file in this trail. I just had to change the way I ran cf-runagent. For completeness, here is the cf-serverd command I used. # cf-serverd -Kvf /

CFEngine Help: Re: How to skip complete "bundle agent" execution depending of a class?

2011-07-19 Thread no-reply
Forum: CFEngine Help Subject: Re: How to skip complete "bundle agent" execution depending of a class? Author: jordy Link to topic: https://cfengine.com/forum/read.php?3,22837,22848#msg-22848 Thank you Neil and Diego! I like the Diego's solution. It's really flexible!! ___

CFEngine Help: Re: How to skip complete "bundle agent" execution depending of a class?

2011-07-19 Thread no-reply
Forum: CFEngine Help Subject: Re: How to skip complete "bundle agent" execution depending of a class? Author: zzamboni Link to topic: https://cfengine.com/forum/read.php?3,22837,22847#msg-22847 You could invoke them from another bundle using methods:, and control execution using classes at that l

CFEngine Help: Re: Variable Class Names

2011-07-19 Thread no-reply
Forum: CFEngine Help Subject: Re: Variable Class Names Author: Seva Gluschenko Link to topic: https://cfengine.com/forum/read.php?3,22838,22846#msg-22846 No, I can't show you an example. Looking thoroughly into the reference manual, I've figured out that classify() won't really help, so that you

CFEngine Help: Re: Variable Class Names

2011-07-19 Thread no-reply
Forum: CFEngine Help Subject: Re: Variable Class Names Author: jordy Link to topic: https://cfengine.com/forum/read.php?3,22838,22844#msg-22844 Thank you Seva... could you show us an example? I don't understand how to create a variable name class (I know how to create a fixed name class, but not

Re: Cfengine Help: Re: Making cf-runagent work

2011-07-19 Thread Seva Gluschenko
Developers attend this maillist on more or less regular basis, but I can't guarantee their attention was gained by this thread. The source code for the community edition is available here: http://cfengine.com/pages/source_code You can download it and read (and even adjust for your needs). 2011/

RE: Cfengine Help: Re: Making cf-runagent work

2011-07-19 Thread Jerome Yanga
Thank you, Seva. Are there any links that you can provide for cf-runagent and cf-serverd? Do developers see these messages? Or is there another thread that I should forward this to? Regards, j -Original Message- From: Seva Gluschenko [mailto:seva.glusche...@gmail.com] Sent: Monday, Ju

CFEngine Help: Re: Variable Class Names

2011-07-19 Thread no-reply
Forum: CFEngine Help Subject: Re: Variable Class Names Author: Seva Gluschenko Link to topic: https://cfengine.com/forum/read.php?3,22838,22842#msg-22842 Use classify function ___ Help-cfengine mailing list Help-cfengine@cfengine.org https://cfengine.or

CFEngine Help: Re: How to skip complete "bundle agent" execution depending of a class?

2011-07-19 Thread no-reply
Forum: CFEngine Help Subject: Re: How to skip complete "bundle agent" execution depending of a class? Author: neilhwatson Link to topic: https://cfengine.com/forum/read.php?3,22837,22841#msg-22841 Perhaps abortclasses. http://cfengine.com/manuals/cf3-reference.html#abortclasses-in-agent _

CFEngine Help: Re: edit global list

2011-07-19 Thread no-reply
Forum: CFEngine Help Subject: Re: edit global list Author: schattenfell Link to topic: https://cfengine.com/forum/read.php?3,22770,22840#msg-22840 One way is to have each individual bundle add its own lines into the module file. Perhaps they directly add lines to a single file, or perhaps they ea

Re: CFEngine Help: Variable Class Names

2011-07-19 Thread Mike Svoboda
This might help... I execute a command and wrap it up with the canonify function. vars: "linux_machine_model" string => canonify(execresult("/usr/sbin/dmidecode -s system-product-name","noshell")); Canonify is a function that will “sanitize” the input to make i

CFEngine Help: Variable Class Names

2011-07-19 Thread no-reply
Forum: CFEngine Help Subject: Variable Class Names Author: jordy Link to topic: https://cfengine.com/forum/read.php?3,22838,22838#msg-22838 Hi!! I think this question can be a newbie question, but I've searched for answers and I can't find any. I have a variable that can have different strings

CFEngine Help: How to skip complete "bundle agent" execution depending of a class?

2011-07-19 Thread no-reply
Forum: CFEngine Help Subject: How to skip complete "bundle agent" execution depending of a class? Author: jordy Link to topic: https://cfengine.com/forum/read.php?3,22837,22837#msg-22837 Hi! We have 6 kind of different servers and I'm developing a complex set of promises for them. Some promises

CFEngine Help: Hello, does any one one out there have any old Bedford CF mark 1 spares for a petrol engine?

2011-07-19 Thread no-reply
Forum: CFEngine Help Subject: Hello, does any one one out there have any old Bedford CF mark 1 spares for a petrol engine? Author: angle kate Link to topic: https://cfengine.com/forum/read.php?3,22836,22836#msg-22836 i am looking for spares for a Bedford CF mark 1 petrol engine for a motor home

CFEngine Help: Re: Installing CFEngine on windows

2011-07-19 Thread no-reply
Forum: CFEngine Help Subject: Re: Installing CFEngine on windows Author: Frost Link to topic: https://cfengine.com/forum/read.php?3,22811,22835#msg-22835 For some reason it works now, very odd haven't done anything in particular. I just tried to reinstall the whole thing again to test if it still

CFEngine Help: Re: Installing CFEngine on windows

2011-07-19 Thread no-reply
Forum: CFEngine Help Subject: Re: Installing CFEngine on windows Author: Frost Link to topic: https://cfengine.com/forum/read.php?3,22811,22834#msg-22834 It seems to compile just fine. Yes i followed you guide, am i missing any packages or something?

CFEngine Help: Re: Class locality clarification

2011-07-19 Thread no-reply
Forum: CFEngine Help Subject: Re: Class locality clarification Author: toddnni Link to topic: https://cfengine.com/forum/read.php?3,22827,22833#msg-22833 Thanks for clarification Mark. I agree that the documentation needs some adjustments regarding this. I didn't understand 'classes' attribute fr