Forum: CFEngine Help
Subject: Re: CFEngine Help: Re: CFEngine Help: Multple (identical) command
executions optimized away?
Author: j.mullins
Link to topic: https://cfengine.com/forum/read.php?3,25778,25784#msg-25784
Thanks Nick. Your explanation makes sense, but it caught me off guard.
Below is a less contrived example, where it's less obvious that the command
will only execute once. This is similar to my use case, and I'm providing it
for illustration, since it took some time to track down what was happening.
Hopefully, this will be helpful to someone else in the future.
body common control
{
bundlesequence => { "test" };
inputs => { "cfengine_stdlib.cf" };
}
bundle agent test
{
methods:
"any" usebundle => execute_ls;
commands:
"/bin/ls";
}
bundle agent execute_ls
{
commands:
"/bin/ls";
}
#ls will only be execute once.
_______________________________________________
Help-cfengine mailing list
[email protected]
https://cfengine.org/mailman/listinfo/help-cfengine