aboutsummaryrefslogtreecommitdiff
blob: dee57ffe387050342511118c694f01a726b0eac7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
# Copyright 1999-2016 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2

EAPI=5

DESCRIPTION="Report and optionally restart crashed OpenRC services"
HOMEPAGE="https://github.com/srcshelton/openrc-restart-crashed"
SRC_URI="https://github.com/srcshelton/openrc-restart-crashed/archive/v1.0.0.tar.gz -> openrc-restart-crashed-v1.0.0.tar.gz"
RESTRICT="nomirror"

LICENSE="GPL-2"
SLOT="0"
KEYWORDS="amd64 arm x86"
IUSE="+cron"

RDEPEND="
	>=app-shells/bash-4.0
	sys-apps/openrc
	cron? ( virtual/cron )"

src_install() {
	exeinto "/usr/local/sbin"
	doexe "openrc-restart-crashed"

	if use cron; then
		insinto "/etc/cron.d"
		newins "${FILESDIR}"/openrc-restart-crashed.cron openrc-restart-crashed
	fi
}