Forum: Cfengine Help
Subject: Re: simple file copy problem
Author: Seva Gluschenko
Link to topic: https://cfengine.com/forum/read.php?3,22319,22320#msg-22320

You can try setting up two promises like this:

files:
"/usr/local/sbin"
         comment     => "copy root scripts for $(sys.fqhost)",
         copy_from   => copy("${v.datadir}/usr/local/sbin"),
         classes        => if_repaired("$(this.promiser)_updated"),
         depth_search => recursion("inf");

"/usr/local/sbin"
         comment     => "copy root scripts for $(sys.fqhost)",
         perms          => file("root", "root", "0770"),
         ifvarclass    => canonify("$(this.promiser)_updated"),
         depth_search => recursion("inf");


I can't guarantee it will work, though. There were complains about 
$(this.promiser) usability.

_______________________________________________
Help-cfengine mailing list
Help-cfengine@cfengine.org
https://cfengine.org/mailman/listinfo/help-cfengine

Reply via email to