###############################################################################
#
# update.conf - ensure that the inputs and binaries in /etc/cfengine are
# synced to those on the server.
# 
# This copies the cfagent.conf and inputs directory from the cfengine
# server.
#
###############################################################################

control:
	actionsequence = ( copy links )
	DefaultCopyType = ( checksum )

	cfhost = ( cfservd.intern )
	localdir = ( /etc/cfengine )
	serverdir = ( /etc/cfengine )
	mode = ( 700 )
	fowner = ( root )
	fgroup = ( root )

copy:
	$(serverdir)/inputs
		dest=$(localdir)/inputs
		recurse=inf
		owner=$(fowner) group=$(fgroup)
		mode=$(mode)
		exclude=*~
		exclude=#*
		server=$(cfhost)
		trustkey=true

links:
	$(localdir)/cfagent.conf ->! $(localdir)/inputs/cfagent.conf
