With cfengine 3, I created this promise: packages:
"testpackage" package_policy => "add", package_method => generic, classes => if_ok("installed_ok"); The idea is to set the "installed_ok" class if the installation is successful, or if the package is already installed (see the "body classes if_ok" in the library). But if the installation fails, cfengine still thinks it was successful and sets the class: ... cf3 Q:apt-get --yes instal ...:WARNING: The following packages cannot be authenticated! cf3 Q:apt-get --yes instal ...: testpackage cf3 Q:apt-get --yes instal ...:E: There are problems and -y was used without --force-yes cf3 Q:apt-get --yes instal ...: cf3 Bulk package schedule execution ok for testpackage (outcome cannot be promised by cf-agent) cf3 ?> defining promise result class installed_ok cf3 -> Update schedule... If I run the apt-get command from the command line, its exit status is 100. In other words, it's definitely failing. But as can be seen above, cfengine thinks that the result was ok. Is this expected behavior? -- D. _______________________________________________ Help-cfengine mailing list Help-cfengine@cfengine.org https://cfengine.org/mailman/listinfo/help-cfengine