[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: file modification
From: |
J . K . Wight |
Subject: |
Re: file modification |
Date: |
Fri, 7 Mar 2003 08:41:15 +0000 |
Debbie Brown writes:
> Several of our desktops have customized config files (/etc/system for
> example). I would like to have a group of files (i.e. file1) that only
> contain the lines that are unique for these config files (i.e. file2); each
> file will be unique to the system it updates. Any admin can update this
> group of files & they don't have to have cfengine knowledge. Basically,
> these files are like a template that contains the special additions that need
> to be added to certain files on the system.
I handle these sorts of situations, where the additions can be grouped
together, like this:
{ /etc/sysconfig/iptables
EmptyEntireFilePlease
InsertLine "*filter"
InsertFile "/local/etc/iptables.d/iptables"
InsertFile "/local/etc/iptables.d/iptables.$(host)"
InsertLine "COMMIT"
DefineClasses "doiptables"
}
I do it on every machine. It doesn't matter if iptables.$(host)
doesn't exist for some machines.
Jim