Daniel Dehennin <[email protected]> writes: > Aleksey Tsalolikhin <[email protected]> writes: > >> I moved the classes promise higher, before the vars promise, >> (which is how it is evaluated anyway), but I get: >> >> Can't stat file "./@(g.country)" for parsing > > I remember something about this, a bug report[1] after a thread on the > mailing-list[2].
I improve my test and figure out that my problem is not in input but in
bundlesequence.
The common bundles in the included files are evaluated, but not the
agent ones.
#v+ bin/cf-agent -K -I
R: Bundle base PASS
R: Bundle common test PASS
R: Bundle agent test FAIL
R: Bundle common test2 PASS
R: Bundle agent test2 FAIL
#v-
#v+ promises.cf
body common control
{
bundlesequence => { "base", @(test.bundles) };
inputs => {"test.cf", @(test.inputs) };
version => "0.0.2";
}
bundle agent base
{
classes:
"base" expression => "any";
reports:
base::
"Bundle base PASS";
!base::
"Bundle base FAIL";
test_common::
"Bundle common test PASS";
!test_common::
"Bundle common test FAIL";
test_agent::
"Bundle agent test PASS";
!test_agent::
"Bundle agent test FAIL";
test2_common::
"Bundle common test2 PASS";
!test2_common::
"Bundle common test2 FAIL";
test2_agent::
"Bundle agent test2 PASS";
!test2_agent::
"Bundle agent test2 FAIL";
}
#v-
#v+ test.cf
bundle common test
{
vars:
any::
"bundles" slist => { "test", @(test2.bundles) };
"inputs" slist => { "test2.cf" };
classes:
"test_common" expression => "any";
}
bundle agent test
{
classes:
"test_agent" expression => "any";
}
#v-
#v+ test2.cf
bundle common test2
{
vars:
any::
"bundles" slist => { "test2" };
classes:
"test2_common" expression => "any";
}
bundle agent test2
{
classes:
"test2_agent" expression => "any";
}
#v-
Regards.
--
Daniel Dehennin
Récupérer ma clef GPG:
gpg --keyserver pgp.mit.edu --recv-keys 0x6A2540D1
pgpDlspdSAgCO.pgp
Description: PGP signature
_______________________________________________ Help-cfengine mailing list [email protected] https://cfengine.org/mailman/listinfo/help-cfengine
