Sorry to arrive late, here. I just tried your example and it seems to provoke a
bug
in two different ways. It might take a while to find the cause, so you could
work around
it for now like this
bundle agent test
{
vars:
"LogRotate" slist => {
"alert",
};
files:
"/tmp/$(LogRotate).log"
action => if_elapsed("120"),
classes => repaired("logrotate_$(LogRotate)"),
rename => rotate("10");
}
body classes repaired(class)
{
promise_repaired => { "$(class)" };
}
Ingersoll, Robert wrote:
> I have tried every variation on this I can think of including moving the
> canonify to the classes promise (coredump) and I can't make this work.
>
> Any other suggestions on how to do this?
>
> This is with Community 3.0.4
>
>
> -----Original Message-----
> From: [email protected] on behalf of Ingersoll, Robert
> Sent: Mon 3/15/2010 3:25 PM
> To: [email protected]
> Cc: [email protected]; [email protected]
> Subject: RE: canonify promise_repaired
>
> I'm not sure if this is telling me it's unsupported, syntactically
> incorrect, or a bug?
>
> cf-agent -KI -b test -f ./test.cf
> !!! No bundlesequence in the common control body
> >> Using command line specified bundlesequence
> -> Rotating files /tmp/alert.log in 10 fifo
> Validation: Class item on rhs of lval 'class addition' given as { @-@ }
> is out of bounds (should match [a-zA-Z0-9_$()\[\].]+)
> -> Rotating files /tmp/alert.log in 10 fifo
> Validation: Class item on rhs of lval 'class addition' given as { @-@ }
> is out of bounds (should match [a-zA-Z0-9_$()\[\].]+)
>
>
> bundle agent test
> {
> vars:
> "LogRotate" slist => {
> "/tmp/alert.log",
> };
>
> files:
> "$(LogRotate)"
> action => ifelapsed("120"),
> classes => repaired("logrotate_$(this.promiser)"),
> rename => rotate("10");
> }
>
> body classes repaired(class)
> {
> promise_repaired => { canonify("$(class)") };
> }
>
>
>
>
>
>
>
> The information transmitted is intended only for the person or entity to
> which it is addressed and may contain confidential and/or privileged
> material. Any review, retransmission, dissemination or other use of, or
> taking of any action in reliance upon, this information by person or
> entities other than the intended recipient is prohibited. If you
> received this in error, please contact the sender and delete the
> material from any computer.
> [email protected]
> www.stginc.com
>
>
>
> ------------------------------------------------------------------------
>
> The information transmitted is intended only for the person or entity to
> which it is addressed and may contain confidential and/or privileged
> material. Any review, retransmission, dissemination or other use of, or
> taking of any action in reliance upon, this information by person or
> entities other than the intended recipient is prohibited. If you
> received this in error, please contact the sender and delete the
> material from any computer.
>
> [email protected] <mailto:[email protected]>
> www.stginc.com <http://www.stginc.com>__
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> Help-cfengine mailing list
> [email protected]
> https://cfengine.org/mailman/listinfo/help-cfengine
--
Mark Burgess
-------------------------------------------------
Professor of Network and System Administration
Oslo University College, Norway
Personal Web: http://www.iu.hio.no/~mark
Office Telf : +47 22453272
-------------------------------------------------
_______________________________________________
Help-cfengine mailing list
[email protected]
https://cfengine.org/mailman/listinfo/help-cfengine