aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJeff Bilyk <jbilyk@gmail.com>2011-07-31 17:24:30 -0400
committerJeff Bilyk <jbilyk@gmail.com>2011-07-31 17:24:30 -0400
commit69f1406837746d28913937eb353867ac49131ee6 (patch)
tree3bb80bc81c460e6ec97b6c33fdac05a69a185b7a
parent50a00f2f0f268425bebb5c1084b7ccf75e1ec519 (diff)
downloadalpine-conf-69f1406837746d28913937eb353867ac49131ee6.tar.bz2
alpine-conf-69f1406837746d28913937eb353867ac49131ee6.tar.xz
setup-ntpd: renamed from setup-chrony, add support for openntpd, other cleanups
-rw-r--r--Makefile2
-rw-r--r--setup-alpine.in2
-rwxr-xr-xsetup-chrony.in48
3 files changed, 2 insertions, 50 deletions
diff --git a/Makefile b/Makefile
index b152718..e0bb4be 100644
--- a/Makefile
+++ b/Makefile
@@ -15,7 +15,7 @@ SBIN_FILES := lbu\
setup-alpine-web\
setup-apklbu\
setup-apkrepos\
- setup-chrony\
+ setup-ntp\
setup-cryptswap\
setup-disk\
setup-dns\
diff --git a/setup-alpine.in b/setup-alpine.in
index 104f8a8..8fa5921 100644
--- a/setup-alpine.in
+++ b/setup-alpine.in
@@ -78,6 +78,6 @@ DEFAULT_DISK=none \
$PREFIX/sbin/setup-apklbu -i
-$PREFIX/sbin/setup-chrony
+$PREFIX/sbin/setup-ntp
$PREFIX/sbin/setup-sshd
diff --git a/setup-chrony.in b/setup-chrony.in
deleted file mode 100755
index a766528..0000000
--- a/setup-chrony.in
+++ /dev/null
@@ -1,48 +0,0 @@
-#!/bin/sh
-
-PREFIX=
-
-. "$PREFIX/lib/libalpine.sh"
-
-usage() {
- cat <<__EOF__
-usage: setup-chrony [-hn]
-
-Setup chrony for NTP time synchronization
-
-options:
- -h Show this help
- -n Don't prompt, just use defaults
-__EOF__
- exit 1
-}
-
-while getopts "hn" opt; do
- case $opt in
- n) PROMPT="0";;
- h) usage;;
- esac
-done
-
-if [ "$PROMPT" != "0" ]; then
- echo "Setup chrony for NTP? (y/N)"
- default_read setupchrony "N"
- if [ "$setupchrony" = "N" ] || [ "$setupchrony" = "n" ]; then
- exit 0
- fi
-fi
-
-exit 1
-
-acfinstalled="`apk version acf-core -q | awk '{print $1}'`"
-
-if [ "$acfinstalled" != "ERROR:" ]; then
- apk add acf-chrony -q
-else
- apk add chrony -q
-fi
-
-echo "10 cronpass" > /etc/chrony/chrony.keys
-
-/etc/init.d/chronyd start
-rc-update add chronyd default