From 6ea3f2e5e571e9eeef85b7796ee88278de698451 Mon Sep 17 00:00:00 2001 From: parazyd Date: Mon, 12 Feb 2018 11:23:34 +0100 Subject: [PATCH] Add dam-client initscript. --- rootfs-overlay/common/etc/init.d/dam-client | 17 +++++++++++++++++ rootfs-overlay/common/etc/rc.local | 2 +- 2 files changed, 18 insertions(+), 1 deletion(-) create mode 100755 rootfs-overlay/common/etc/init.d/dam-client diff --git a/rootfs-overlay/common/etc/init.d/dam-client b/rootfs-overlay/common/etc/init.d/dam-client new file mode 100755 index 0000000..a9bf81f --- /dev/null +++ b/rootfs-overlay/common/etc/init.d/dam-client @@ -0,0 +1,17 @@ +#!/sbin/openrc-run +# Copyright 1999-2018 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +command=/home/decode/go/bin/dam-client +pidfile=/var/run/dam-client.pid + +description="Tor DAM client" + +depend() { + after dam-dir +} + +start() { + start-stop-daemon --start -u decode -g decode \ + --pidfile $pidfile -b -m -x $command +} diff --git a/rootfs-overlay/common/etc/rc.local b/rootfs-overlay/common/etc/rc.local index 3c035fd..3533822 100755 --- a/rootfs-overlay/common/etc/rc.local +++ b/rootfs-overlay/common/etc/rc.local @@ -1,7 +1,7 @@ #!/bin/sh # rc.local for base images -[ -f /etc/ssh/ssh_host_rsa_key.pub ] || dpkg-reconfigure openssh-server +[ -f /etc/ssh/ssh_host_rsa_key.pub ] || ssh-keygen -A netdata