Forum: CFEngine Help Subject: Re: "real" templates Author: neilhwatson Link to topic: https://cfengine.com/forum/read.php?3,23837,23843#msg-23843
I try not to make policy to much like a program. I find it looses its ease of understanding. If I have to write policy a little longer that is easier to read I always choose that route. You might try different templates or even different methods based on the class of the client host. methods: ntp_servers:: "config" usebundle => ntp_servers( "$(sys.workdir)/masterfiles/ntp_tmp_s.conf", "@(ntp.servers)" ); mc_ntp_servers:: "config" usebundle => mc_ntp_servers( "$(other_variables)" ); !(ntp_servers.mc_ntp_servers):: "config" usebundle => ntp_clients( "$(template_file)", "@(ntp_servers)" ); Above clearly defines the types of ntp services to be configured and which hosts get them. _______________________________________________ Help-cfengine mailing list Help-cfengine@cfengine.org https://cfengine.org/mailman/listinfo/help-cfengine