diff options
Diffstat (limited to 'net-misc/tlsdate/files')
-rw-r--r-- | net-misc/tlsdate/files/tlsdate.confd | 8 | ||||
-rwxr-xr-x | net-misc/tlsdate/files/tlsdate.rc | 17 | ||||
-rw-r--r-- | net-misc/tlsdate/files/tlsdated.confd | 15 | ||||
-rwxr-xr-x | net-misc/tlsdate/files/tlsdated.rc | 19 |
4 files changed, 59 insertions, 0 deletions
diff --git a/net-misc/tlsdate/files/tlsdate.confd b/net-misc/tlsdate/files/tlsdate.confd new file mode 100644 index 000000000000..2d7ed030de33 --- /dev/null +++ b/net-misc/tlsdate/files/tlsdate.confd @@ -0,0 +1,8 @@ +# config file for /etc/init.d/tlsdate + +# Command to execute to set the time. +# This are some common tlsdate options: +# -l: leap (set time regardless of difference) +# -H: hostname to sync with +# -x: proxy URL +TLSDATE_OPTS="-l -H www.google.com" diff --git a/net-misc/tlsdate/files/tlsdate.rc b/net-misc/tlsdate/files/tlsdate.rc new file mode 100755 index 000000000000..b4d6f97ecc39 --- /dev/null +++ b/net-misc/tlsdate/files/tlsdate.rc @@ -0,0 +1,17 @@ +#!/sbin/runscript +# Copyright 1999-2012 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-misc/tlsdate/files/tlsdate.rc,v 1.1 2012/12/11 01:49:23 vapier Exp $ + +description="set time once when started" + +depend() { + use net +} + +start() { + : ${TLSDATE_CMD:=tlsdate} + ebegin "Setting clock via tlsdate '${TLSDATE_CMD}'" + "${TLSDATE_CMD}" ${TLSDATE_OPTS} + eend $? "Failed to set clock" +} diff --git a/net-misc/tlsdate/files/tlsdated.confd b/net-misc/tlsdate/files/tlsdated.confd new file mode 100644 index 000000000000..d257289cc58d --- /dev/null +++ b/net-misc/tlsdate/files/tlsdated.confd @@ -0,0 +1,15 @@ +# config file for /etc/init.d/tlsdated + +# Command to execute to set the time. +# This are some common tlsdate options: +# -l: leap (set time regardless of difference) +# -H: hostname to sync with +# -x: proxy URL +TLSDATED_CMD="/usr/bin/tlsdate -l -H www.google.com" + +# Additional options; see `man tlsdated` for reference. +TLSDATED_OPTS="" + +# Cache dir. Probably don't need to change this. +# It matches the compiled-in default. +TLSDATED_CACHE_DIR="/var/cache/tlsdated" diff --git a/net-misc/tlsdate/files/tlsdated.rc b/net-misc/tlsdate/files/tlsdated.rc new file mode 100755 index 000000000000..e055a03a9993 --- /dev/null +++ b/net-misc/tlsdate/files/tlsdated.rc @@ -0,0 +1,19 @@ +#!/sbin/runscript +# Copyright 1999-2012 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-misc/tlsdate/files/tlsdated.rc,v 1.1 2012/12/11 01:49:23 vapier Exp $ + +description="start a daemon to continuously set time via a helper" + +command="tlsdated" +command_args="${TLSDATED_OPTS} -- ${TLSDATED_CMD}" +command_background="true" +pidfile="/var/run/${SVCNAME}.pid" + +depend() { + use net +} + +start_pre() { + checkpath -d -m 0700 "${TLSDATED_CACHE_DIR}" +} |