summaryrefslogtreecommitdiff
path: root/sysutils/py-google-compute-engine/files/google_clock_skew_daemon.in
diff options
context:
space:
mode:
authorRichard Gallamore <ultima@FreeBSD.org>2017-08-19 18:02:55 +0000
committerRichard Gallamore <ultima@FreeBSD.org>2017-08-19 18:02:55 +0000
commit9c025a94bc00007f14d8423fd0e82eb299cb1e6d (patch)
tree5dd3b30a70103b8c338a8d891e08fa16dabb30bd /sysutils/py-google-compute-engine/files/google_clock_skew_daemon.in
parentRtMidi is a set of C++ classes (RtMidiIn, RtMidiOut, and API specific classes) (diff)
Google Compute Engine offers scripts and daemons which runs in the
background and provides the following services: - Accounts daemon to setup and manage user accounts, and to enable SSH key based authentication. - Clock skew daemon to keep the system clock in sync after VM start and stop events. - Instance setup scripts to execute VM configuration scripts during boot. - IP forwarding daemon that integrates network load balancing with forwarding rule changes into the guest. - Metadata scripts to run user provided scripts at VM startup and shutdown. - Network setup service to enable multiple network interfaces on boot. WWW: https://github.com/GoogleCloudPlatform/compute-image-packages PR: 219687 Submitted by: Helen Koike (maintainer) Reviewed by: matthew (mentor), koobs, sunpoet, swills, julian Approved by: matthew (mentor) Differential Revision: https://reviews.freebsd.org/D12077
Diffstat (limited to 'sysutils/py-google-compute-engine/files/google_clock_skew_daemon.in')
-rw-r--r--sysutils/py-google-compute-engine/files/google_clock_skew_daemon.in34
1 files changed, 34 insertions, 0 deletions
diff --git a/sysutils/py-google-compute-engine/files/google_clock_skew_daemon.in b/sysutils/py-google-compute-engine/files/google_clock_skew_daemon.in
new file mode 100644
index 000000000000..8ba2db500769
--- /dev/null
+++ b/sysutils/py-google-compute-engine/files/google_clock_skew_daemon.in
@@ -0,0 +1,34 @@
+#!/bin/sh
+
+# $FreeBSD$
+#
+# PROVIDE: google_clock_skew_daemon
+# BEFORE: LOGIN
+# REQUIRE: NETWORKING syslogd google_instance_setup google_network_setup
+# KEYWORD: shutdown
+#
+# google_clock_skew_daemon_enable (bool): Set to NO by default.
+# Set it to YES to enable google_clock_skew_daemon.
+#
+
+. /etc/rc.subr
+
+name="google_clock_skew_daemon"
+rcvar="google_clock_skew_daemon_enable"
+
+load_rc_config "${name}"
+
+: ${google_clock_skew_daemon_enable:="NO"}
+
+command_interpreter="%%PYTHON_CMD%%"
+command=%%PREFIX%%/bin/${name}
+pidfile=/var/run/${name}.pid
+start_cmd="google_clock_skew_daemon_start"
+
+google_clock_skew_daemon_start()
+{
+ check_startmsgs && echo "Starting ${name}."
+ daemon -p ${pidfile} -t ${name} ${command}
+}
+
+run_rc_command "$1"