It is unlikely to happen that way. Remember, there are two conditions, "promise_repaired" and "promise_kept". In your example, promise_kept will be set by one body and promise_repaired by another. They shouldn't supercede each other.
2010/11/25 <no-re...@cfengine.com>: > Forum: Cfengine Help > Subject: Re: if_repaired > Author: babudro > Link to topic: https://cfengine.com/forum/read.php?3,19388,19396#msg-19396 > > I note that two promises are being combined: > > > perms => usystem("0744"), > copy_from => umycopy("/var/lib/cfengine3/masterfiles/conf/sshd_config"), > > > The Cfengine reference manual says: > > > Important: complex promises, e.g. files promises that set multiple parameters > on a file simultaneously can report misleadingly. The classes for different > parts of a promise are not separable. Thus, if you promise to create and file > and change its permissions, when the file exists with incorrect permissions, > cf-agent will report that the ‘promise_kept’ for the file existence, but > ‘promise_repaired’ for the permissions. If you need separate reports, you > should code two separate promises rather than `overloading' a single one. > > > Could it be that the permissions are correct and, therefore, the promise is > being flagged as "kept" rather than "repaired"? > > _______________________________________________ > Help-cfengine mailing list > Help-cfengine@cfengine.org > https://cfengine.org/mailman/listinfo/help-cfengine > -- SY, Seva Gluschenko. _______________________________________________ Help-cfengine mailing list Help-cfengine@cfengine.org https://cfengine.org/mailman/listinfo/help-cfengine