diff options
author | Patrick Lauer <patrick@gentoo.org> | 2011-04-13 15:40:32 +0000 |
---|---|---|
committer | Patrick Lauer <patrick@gentoo.org> | 2011-04-13 15:40:32 +0000 |
commit | bd981fc761e7566a1248467c81c87b9a42b0f593 (patch) | |
tree | 4ff39c8e0f72f9dc59eeb7342bfab5b80420fc95 /app-admin/monit | |
parent | Fix dependencies. (diff) | |
download | gentoo-2-bd981fc761e7566a1248467c81c87b9a42b0f593.tar.gz gentoo-2-bd981fc761e7566a1248467c81c87b9a42b0f593.tar.bz2 gentoo-2-bd981fc761e7566a1248467c81c87b9a42b0f593.zip |
init script fix for #362033
(Portage version: 2.2.0_alpha29/cvs/Linux x86_64)
Diffstat (limited to 'app-admin/monit')
-rw-r--r-- | app-admin/monit/ChangeLog | 8 | ||||
-rw-r--r-- | app-admin/monit/files/monit.initd-5.0-r1 | 38 | ||||
-rw-r--r-- | app-admin/monit/monit-5.2.3-r1.ebuild | 46 |
3 files changed, 91 insertions, 1 deletions
diff --git a/app-admin/monit/ChangeLog b/app-admin/monit/ChangeLog index 783f855d28b4..26eff9f83e32 100644 --- a/app-admin/monit/ChangeLog +++ b/app-admin/monit/ChangeLog @@ -1,6 +1,12 @@ # ChangeLog for app-admin/monit # Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/app-admin/monit/ChangeLog,v 1.57 2011/03/20 18:28:05 armin76 Exp $ +# $Header: /var/cvsroot/gentoo-x86/app-admin/monit/ChangeLog,v 1.58 2011/04/13 15:40:32 patrick Exp $ + +*monit-5.2.3-r1 (13 Apr 2011) + + 13 Apr 2011; Patrick Lauer <patrick@gentoo.org> +files/monit.initd-5.0-r1, + +monit-5.2.3-r1.ebuild: + init script fix for #362033 20 Mar 2011; Raúl Porcel <armin76@gentoo.org> monit-5.2.3.ebuild: sparc stable wrt #355567 diff --git a/app-admin/monit/files/monit.initd-5.0-r1 b/app-admin/monit/files/monit.initd-5.0-r1 new file mode 100644 index 000000000000..14e03131aa89 --- /dev/null +++ b/app-admin/monit/files/monit.initd-5.0-r1 @@ -0,0 +1,38 @@ +#!/sbin/runscript +# Copyright 1999-2011 Gentoo Foundation +# Distributed under the terms of the GNU General Public License, v2 or later +# $Header: /var/cvsroot/gentoo-x86/app-admin/monit/files/monit.initd-5.0-r1,v 1.1 2011/04/13 15:40:32 patrick Exp $ + +opts="${opts} reload configtest" + + +depend() { + use net +} + +configtest() { + /usr/bin/monit -t 1>/dev/null 2>&1 + ret=$? + if [ $ret -ne 0 ]; then + eerror "${SVCNAME} has detected an error in your setup:" + /usr/bin/monit -t + fi + return $ret +} +start() { + ebegin "Starting monit" + start-stop-daemon --start --quiet --exec /usr/bin/monit >/dev/null 2>&1 + eend $? +} + +stop() { + ebegin "Stopping monit" + start-stop-daemon --stop --quiet --exec /usr/bin/monit + eend $? +} + +reload() { + ebegin "Reloading monit" + /usr/bin/monit -c /etc/monitrc reload >/dev/null 2>&1 + eend $? +} diff --git a/app-admin/monit/monit-5.2.3-r1.ebuild b/app-admin/monit/monit-5.2.3-r1.ebuild new file mode 100644 index 000000000000..5f5049de13ef --- /dev/null +++ b/app-admin/monit/monit-5.2.3-r1.ebuild @@ -0,0 +1,46 @@ +# Copyright 1999-2011 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/app-admin/monit/monit-5.2.3-r1.ebuild,v 1.1 2011/04/13 15:40:32 patrick Exp $ + +EAPI="2" + +DESCRIPTION="a utility for monitoring and managing daemons or similar programs running on a Unix system." +HOMEPAGE="http://mmonit.com/monit/" +SRC_URI="http://mmonit.com/monit/dist/${P}.tar.gz" + +LICENSE="GPL-3" +SLOT="0" +KEYWORDS="~amd64 ~ppc ~sparc ~x86" +IUSE="ssl" + +RDEPEND="ssl? ( dev-libs/openssl )" +DEPEND="${RDEPEND} + sys-devel/flex + sys-devel/bison" + +src_prepare() { + sed -i -e '/^INSTALL_PROG/s/-s//' Makefile.in || die "sed failed in Makefile.in" +} + +src_configure() { + econf $(use_with ssl) || die "econf failed" +} + +src_compile() { + emake || die "emake failed" +} + +src_install() { + make DESTDIR="${D}" install || die "make install failed" + + dodoc CHANGES.txt README* + dohtml -r doc/* + + insinto /etc; insopts -m700; doins monitrc || die "doins monitrc failed" + newinitd "${FILESDIR}"/monit.initd-5.0-r1 monit || die "newinitd failed" +} + +pkg_postinst() { + elog "Sample configurations are available at:" + elog "http://mmonit.com/monit/documentation/" +} |