Hello,

I'm trying the example from
http://www.cfengine.org/manuals/cf3-solutions.html#Postfix-mail-configuration
.
However, /etc/postfix/sasl-passwd needs to be converted with postmap
before restarting Postfix.

What's the proper way to deal with this? I thought of defining a new
class ("changed_sasl-passwd") if the file was successfully edited.
Then, postmap would be executed only if this class was defined:

processes:

  "/usr/lib/postfix/master"
        restart_class => "start_postfix";

commands:

  start_postfix.!changed_sasl-passwd::
        "/etc/init.d/postfix restart";

  start_postfix.changed_sasl-passwd::
        "postmap $(prefix)/sasl-passwd";
        "/etc/init.d/postfix restart";

Unfortunately, I can't find the correct syntax to define the new class.


Thank you,
Ari Constancio
_______________________________________________
Help-cfengine mailing list
Help-cfengine@cfengine.org
https://cfengine.org/mailman/listinfo/help-cfengine

Reply via email to