1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-11-23 00:43:28 +00:00

Fork the nsca27 and nsca27-ports for users having problems with nsca 2.9.x

This commit is contained in:
Martin Matuska 2013-01-29 19:49:38 +00:00
parent 2cf46f2158
commit 418a7e0813
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=311182
9 changed files with 167 additions and 0 deletions

View File

@ -186,6 +186,8 @@
SUBDIR += nrpep
SUBDIR += nsca
SUBDIR += nsca-client
SUBDIR += nsca27
SUBDIR += nsca27-client
SUBDIR += nstreams
SUBDIR += observium
SUBDIR += ocsinventory-agent

View File

@ -0,0 +1,17 @@
# New ports collection makefile for: nsca-client
# Date created: Sun Apr 30 17:23:00 CET 2006
# Whom: Martin Matuska <mm@FreeBSD.org>
#
# $FreeBSD$
#
PKGNAMESUFFIX= -client
MAINTAINER= mm@FreeBSD.org
LICENSE= GPLv2
_BUILDING_NSCA_CLIENT= yes
MASTERDIR= ${.CURDIR}/../nsca27
.include "${MASTERDIR}/Makefile"

75
net-mgmt/nsca27/Makefile Normal file
View File

@ -0,0 +1,75 @@
# New ports collection makefile for: nsca
# Date created: 2003-11-18
# Whom: Paul Dlug <paul@nerdlabs.com>
#
# $FreeBSD$
#
PORTNAME= nsca
PORTVERSION= 2.7.2
PORTREVISION= 6
CATEGORIES= net-mgmt
MASTER_SITES= SF/nagios/nsca-2.x/nsca-${PORTVERSION}
MAINTAINER= mm@FreeBSD.org
COMMENT= Nagios Service Check Acceptor
LICENSE= GPLv2
.if !defined(_BUILDING_NSCA_CLIENT)
#RUN_DEPENDS= nagios:${PORTSDIR}/net-mgmt/nagios
.endif
LIB_DEPENDS= mcrypt:${PORTSDIR}/security/libmcrypt
.if !defined(_BUILDING_NSCA_CLIENT)
LATEST_LINK= nsca27
CONFLICTS= nsca-2.9.*
.else
LATEST_LINK= nsca27-client
CONFLICTS= nsca-client-2.9.*
.endif
GNU_CONFIGURE= yes
USE_PERL5= yes
CONFIGURE_ARGS= --prefix=${PREFIX} --localstatedir=/var/spool/nagios
DOCSDIR?= ${PREFIX}/share/doc/${PORTNAME}${PKGNAMESUFFIX}
.if !defined(_BUILDING_NSCA_CLIENT)
USE_RC_SUBR= nsca
PLIST_SUB+= SERVER=""
WITHOUT_CLIENT= yes
PKGMESSAGE= ${WRKDIR}/pkg-message
SUB_FILES+= pkg-message
.else
PLIST_SUB+= SERVER="@comment "
PKGMESSAGE= ${WRKDIR}/pkg-message.client
SUB_FILES+= pkg-message.client
.endif
.if !defined(_BUILDING_NSCA_CLIENT)
PLIST_SUB+= CLIENT=""
.else
PLIST_SUB+= CLIENT="@comment "
.endif
DOCS= Changelog LEGAL README SECURITY
do-install:
.if defined(_BUILDING_NSCA_CLIENT)
${INSTALL_PROGRAM} ${WRKSRC}/src/send_nsca ${PREFIX}/sbin/send_nsca
${MKDIR} ${PREFIX}/etc/nagios
${INSTALL_DATA} ${WRKSRC}/sample-config/send_nsca.cfg ${PREFIX}/etc/nagios/send_nsca.cfg-sample
.else
${INSTALL_PROGRAM} ${WRKSRC}/src/nsca ${PREFIX}/sbin/nsca
${MKDIR} ${PREFIX}/etc/nagios
${INSTALL_DATA} ${WRKSRC}/sample-config/nsca.cfg ${PREFIX}/etc/nagios/nsca.cfg-sample
.endif
post-install:
.if !defined(NOPORTDOCS)
@${MKDIR} ${DOCSDIR}
cd ${WRKSRC} && ${INSTALL_DATA} ${DOCS} ${DOCSDIR}
.endif
@${CAT} ${PKGMESSAGE}
.include <bsd.port.mk>

2
net-mgmt/nsca27/distinfo Normal file
View File

@ -0,0 +1,2 @@
SHA256 (nsca-2.7.2.tar.gz) = fb41e3b536735235056643fb12187355c6561b9148996c093e8faddd4fced571
SIZE (nsca-2.7.2.tar.gz) = 104953

View File

@ -0,0 +1,35 @@
#!/bin/sh
# $FreeBSD$
#
# PROVIDE: nsca
# REQUIRE: nagios
# BEFORE: LOGIN
# KEYWORD: shutdown
#
# Add the following lines to /etc/rc.conf to enable nsca:
# nsca_enable (bool): Set to "NO" by default.
# Set it to "YES" to enable nsca.
# nsca_flags (str): Set to "--daemon" by default.
# nsca_configfile (str): Set to "%%PREFIX%%/etc/nagios/nsca.cfg" by default.
#
. /etc/rc.subr
name="nsca"
rcvar=nsca_enable
command="%%PREFIX%%/sbin/nsca"
pidfile="/var/run/nsca.pid"
extra_commands=reload
nsca_enable=${nsca_enable:-"NO"}
nsca_flags=${nsca_flags:-"--daemon"}
nsca_configfile=${nsca_configfile:-"%%PREFIX%%/etc/nagios/nsca.cfg"}
load_rc_config "${name}"
required_files="${nsca_configfile}"
command_args="-c ${nsca_configfile}"
run_rc_command "$1"

View File

@ -0,0 +1,9 @@
*** ATTENTION ***
This port installs only the client part of NSCA ("send_nsca").
If you need the nsca daemon install the net-mgmt/nsca port.
The default configuration file is installed at:
%%PREFIX%%/etc/nagios/send_nsca.cfg-sample

View File

@ -0,0 +1,9 @@
*** ATTENTION ***
This port includes only the server part of NSCA ("nsca").
If you need the "send_nsca" utility install the net-mgmt/nsca-client port.
The default configuration file is installed at:
%%PREFIX%%/etc/nagios/nsca.cfg-sample

View File

@ -0,0 +1,7 @@
The Nagios Service Check Acceptor (NSCA) is used to send service check
results to a central Nagios server. This consists of the "nsca" daemon
which runs on the main Nagios server and accepts results and the
"send_nsca" client which is used to send results to the server.
Author: Ethan Galstad
WWW: http://www.nagios.org/

11
net-mgmt/nsca27/pkg-plist Normal file
View File

@ -0,0 +1,11 @@
@comment $FreeBSD$
%%PORTDOCS%%%%DOCSDIR%%/Changelog
%%PORTDOCS%%%%DOCSDIR%%/LEGAL
%%PORTDOCS%%%%DOCSDIR%%/README
%%PORTDOCS%%%%DOCSDIR%%/SECURITY
%%PORTDOCS%%@dirrm %%DOCSDIR%%
%%SERVER%%etc/nagios/nsca.cfg-sample
%%SERVER%%sbin/nsca
%%CLIENT%%etc/nagios/send_nsca.cfg-sample
%%CLIENT%%sbin/send_nsca
@dirrmtry etc/nagios