Blame SOURCES/chrony.dhclient

c2c5e4
#!/bin/bash
c2c5e4
c2c5e4
SERVERFILE=$SAVEDIR/chrony.servers.$interface
c2c5e4
c2c5e4
chrony_config() {
c2c5e4
	rm -f $SERVERFILE
c2c5e4
	if [ "$PEERNTP" != "no" ]; then
c2c5e4
		for server in $new_ntp_servers; do
c2c5e4
			echo "$server $NTPSERVERARGS" >> $SERVERFILE
c2c5e4
		done
c2c5e4
		/usr/libexec/chrony-helper is-running &&
c2c5e4
			/usr/libexec/chrony-helper add-dhclient-servers &&
c2c5e4
			/usr/libexec/chrony-helper remove-dhclient-servers || :
c2c5e4
	fi
c2c5e4
}
c2c5e4
c2c5e4
chrony_restore() {
c2c5e4
	if [ -f $SERVERFILE ]; then
c2c5e4
		rm -f $SERVERFILE
c2c5e4
		/usr/libexec/chrony-helper is-running &&
c2c5e4
			/usr/libexec/chrony-helper remove-dhclient-servers || :
c2c5e4
	fi
c2c5e4
}