File: ip-up

package info (click to toggle)
chrony 1.21z-5
  • links: PTS
  • area: main
  • in suites: etch-m68k
  • size: 2,080 kB
  • ctags: 2,375
  • sloc: ansic: 14,831; yacc: 858; sh: 588; perl: 426; makefile: 148
file content (17 lines) | stat: -rw-r--r-- 556 bytes parent folder | download | duplicates (8)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#!/bin/sh
# This script tells chronyd that the connection is up so that it can
# contact the server.  John Hasler <jhasler@debian.org> 1998-2003
# Any possessor of a copy of this program may treat it as if it
# were in the public domain.  I waive all rights.

/bin/pidof chronyd > /dev/null || exit 0
KEY=$(awk '$1 ~ /^commandkey$/ { print $2; exit}' /etc/chrony/chrony.conf)
PASSWORD=`awk '$1 ~ /^'$KEY'$/ {print $2; exit}' /etc/chrony/chrony.keys`
/usr/bin/chronyc << EOF
password $PASSWORD
online
burst 5/10
quit
EOF
touch /var/run/chrony-ppp-up
exit 0