[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: trigger process if file copied
From: |
Paul Heinlein |
Subject: |
Re: trigger process if file copied |
Date: |
Wed, 12 Feb 2003 05:54:08 -0800 (PST) |
On Wed, 12 Feb 2003, Zeev Fisher wrote:
> I use cfengine to copy some system files like the automounter maps
> and i would to refresh to the automounter daemon only if there was a
> need to copy something from the server.
>
> Is there an option for doing this ?
Yeah, it's pretty simple. Here's how I handle an analogous situation
with ntp configuration updates on our Red Hat Linux clients. When the
config is updates, I define a class called 'restartntp,' which is
merely calls Red Hat's init script in restart mode.
copy:
linux.redhat.ntp_pclient::
$(master_configs)/ntp/ntp.conf.linux
server=$(policyhost) dest=/etc/ntp.conf
m=444 o=root g=root type=sum define=restartntp
shellcommands:
linux.redhat.restartntp::
"/etc/init.d/ntpd restart"
--Paul Heinlein <heinlein@cse.ogi.edu>