summaryrefslogtreecommitdiff
path: root/sys-apps/smartmontools/files
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
committerV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
commit4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch)
treeba5f07bf3f9d22d82e54a462313f5d244036c768 /sys-apps/smartmontools/files
reinit the tree, so we can have metadata
Diffstat (limited to 'sys-apps/smartmontools/files')
-rw-r--r--sys-apps/smartmontools/files/smartd-r1.rc28
-rw-r--r--sys-apps/smartmontools/files/smartd.confd4
-rw-r--r--sys-apps/smartmontools/files/smartmontools-update-drivedb3
3 files changed, 35 insertions, 0 deletions
diff --git a/sys-apps/smartmontools/files/smartd-r1.rc b/sys-apps/smartmontools/files/smartd-r1.rc
new file mode 100644
index 000000000000..1aa2ece803dc
--- /dev/null
+++ b/sys-apps/smartmontools/files/smartd-r1.rc
@@ -0,0 +1,28 @@
+#!/sbin/openrc-run
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+pidfile="/run/smartd.pid"
+command="/usr/sbin/smartd"
+command_args="-p ${pidfile} ${SMARTD_OPTS}"
+extra_started_commands="reload"
+
+depend() {
+ need localmount
+ after bootmisc
+}
+
+start_pre() {
+ if [ ! -f "/etc/smartd.conf" ] ; then
+ eerror "You should setup your /etc/smartd.conf file!"
+ eerror "See the smartd.conf(5) manpage."
+ return 1
+ fi
+ return 0
+}
+
+reload() {
+ ebegin "Reloading configuration"
+ start-stop-daemon --signal HUP --pidfile ${pidfile} ${command##*/}
+ eend $?
+}
diff --git a/sys-apps/smartmontools/files/smartd.confd b/sys-apps/smartmontools/files/smartd.confd
new file mode 100644
index 000000000000..4b7db4dfd827
--- /dev/null
+++ b/sys-apps/smartmontools/files/smartd.confd
@@ -0,0 +1,4 @@
+# /etc/conf.d/smartd: config file for /etc/init.d/smartd
+
+# Insert any other options needed
+SMARTD_OPTS=""
diff --git a/sys-apps/smartmontools/files/smartmontools-update-drivedb b/sys-apps/smartmontools/files/smartmontools-update-drivedb
new file mode 100644
index 000000000000..831f1e6541b5
--- /dev/null
+++ b/sys-apps/smartmontools/files/smartmontools-update-drivedb
@@ -0,0 +1,3 @@
+#!/bin/sh
+
+/usr/sbin/update-smart-drivedb