Forum: CFEngine Help
Subject: Matching files and replacing files with regex
Author: Devastator101
Link to topic: https://cfengine.com/forum/read.php?3,25425,25425#msg-25425

Hi guys,

I would like to know how to replace files using regex built in cfengine.  I 
would like to replace .conf files in a client with the .conf files from the 
configuration server.  Below is the code I have created. 
 
   "/etc/application/(^(.*)\.)+conf"
    perms => system("0644","root","root"),
    copy_from => mycopy( "/my/repository/config/files/$(match.2)", "servername" 
);


Can anybody help me with this.

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

Reply via email to