21 lines
387 B
Plaintext
21 lines
387 B
Plaintext
|
#!/bin/bash
|
||
|
|
||
|
SERVERFILE=$SAVEDIR/chrony.servers.$interface
|
||
|
|
||
|
chrony_config() {
|
||
|
rm -f $SERVERFILE
|
||
|
if [ "$PEERNTP" != "no" ]; then
|
||
|
for server in $new_ntp_servers; do
|
||
|
echo "$server ${NTPSERVERARGS:-iburst}" >> $SERVERFILE
|
||
|
done
|
||
|
@CHRONY_HELPER@ update-daemon || :
|
||
|
fi
|
||
|
}
|
||
|
|
||
|
chrony_restore() {
|
||
|
if [ -f $SERVERFILE ]; then
|
||
|
rm -f $SERVERFILE
|
||
|
@CHRONY_HELPER@ update-daemon || :
|
||
|
fi
|
||
|
}
|