diff --git a/board/common/rootfs/usr/bin/ntp b/board/common/rootfs/usr/bin/ntp new file mode 100755 index 00000000..0fe7122a --- /dev/null +++ b/board/common/rootfs/usr/bin/ntp @@ -0,0 +1,19 @@ +#!/bin/sh +# Helper script to chronyc, checks if daemon is running + +if ! chronyc serverstats >/dev/null; then + echo "NTP client not enabled." + exit 1 +fi + +case $1 in + tracking) + chronyc tracking + ;; + sources) + chronyc sources -v + ;; + *) + echo "Unknown NTP command." + ;; +esac diff --git a/src/klish-plugin-infix/xml/infix.xml b/src/klish-plugin-infix/xml/infix.xml index 272d83b4..76ce02e1 100644 --- a/src/klish-plugin-infix/xml/infix.xml +++ b/src/klish-plugin-infix/xml/infix.xml @@ -250,6 +250,15 @@ + + ntp tracking + + + ntp sources + + + +