I'm having trouble figuring out how to do multiple replace_patters operations.
What I'm trying to do is what the example below does, but configured to take a
series of search/replace pairs to iterate over. I suspect there's probably a
better solution to this than whatever I'll come up with if I keep poking at it
until it works at this stage in my cf3 knowledge ...
bundle agent autofs_config
{
files:
redhat_6::
"/tmp/autofs"
handle => "autofs_sysconfig_edit",
edit_line => test_edit("^#OPTIONS=\"\"","OPTIONS=\"-O fsc\"");
}
bundle edit_line test_edit(regex,string)
{
replace_patterns:
"$(regex)" replace_with => value("$(string)");
}
_______________________________________________
Help-cfengine mailing list
[email protected]
https://cfengine.org/mailman/listinfo/help-cfengine