2013-01-09 20:50:06 +01:00
|
|
|
# Created by: Janos.Mohacsi@bsd.hu
|
2004-07-22 03:48:42 +02:00
|
|
|
# $FreeBSD$
|
|
|
|
|
|
|
|
PORTNAME= nagiostat
|
|
|
|
PORTVERSION= 1.0.0
|
2012-05-07 20:52:09 +02:00
|
|
|
PORTREVISION= 6
|
2004-07-22 03:48:42 +02:00
|
|
|
CATEGORIES= net-mgmt
|
2009-08-22 02:32:25 +02:00
|
|
|
MASTER_SITES= SF/${PORTNAME}/${PORTNAME}/1.0
|
2004-07-22 03:48:42 +02:00
|
|
|
EXTRACT_SUFX= .tgz
|
|
|
|
|
2013-01-09 20:50:06 +01:00
|
|
|
MAINTAINER= jmohacsi@bsd.hu
|
2004-07-22 03:48:42 +02:00
|
|
|
COMMENT= Nagiostat parses performance-data from Nagios and generates graphs
|
|
|
|
|
2007-07-05 08:19:49 +02:00
|
|
|
RUN_DEPENDS= rrdtool:${PORTSDIR}/databases/rrdtool \
|
2006-04-02 00:40:38 +02:00
|
|
|
nagios:${PORTSDIR}/net-mgmt/nagios
|
2006-01-28 22:09:16 +01:00
|
|
|
|
2013-09-04 05:24:02 +02:00
|
|
|
USES= perl5
|
2004-07-22 03:48:42 +02:00
|
|
|
NO_BUILD= yes
|
|
|
|
NO_WRKSUBDIR= yes
|
|
|
|
NAGIOSDIR?= /var/spool/nagios
|
|
|
|
DOC_FILES= README GPL.txt
|
|
|
|
|
2006-04-02 00:40:38 +02:00
|
|
|
NAGIOSWWWDIR?= www/nagios
|
|
|
|
PLIST_SUB+= NAGIOSWWWDIR=${NAGIOSWWWDIR}
|
|
|
|
|
2013-09-21 00:24:43 +02:00
|
|
|
NO_STAGE= yes
|
2004-07-22 03:48:42 +02:00
|
|
|
post-patch:
|
|
|
|
@${REINPLACE_CMD} \
|
|
|
|
-e 's|%%NAGIOSTATCONFDIR%%|${PREFIX}/etc/|' \
|
|
|
|
-e 's|%%NAGIOSTATDIR%%|${PREFIX}/libexec/${PORTNAME}/|' \
|
|
|
|
-e 's|%%NAGIOSTATRRD%%|${NAGIOSDIR}/${PORTNAME}rrd/|' \
|
|
|
|
-e 's|%%PREFIX%%|${PREFIX}|' \
|
|
|
|
${WRKSRC}/nagiostat ${WRKSRC}/nagiostat.conf ${WRKSRC}/README
|
|
|
|
do-install:
|
|
|
|
@${MKDIR} ${PREFIX}/libexec/${PORTNAME}
|
|
|
|
@${MKDIR} ${NAGIOSDIR}/${PORTNAME}rrd
|
|
|
|
@${INSTALL_SCRIPT} ${WRKSRC}/nagiostat ${PREFIX}/libexec/${PORTNAME}/
|
2006-04-02 00:40:38 +02:00
|
|
|
@${LN} -fs ${PREFIX}/libexec/${PORTNAME}/nagiostat ${PREFIX}/${NAGIOSWWWDIR}/cgi-bin/nagiostat.cgi
|
2004-07-22 03:48:42 +02:00
|
|
|
@${INSTALL_DATA} ${WRKSRC}/nagiostat.conf ${PREFIX}/etc/nagiostat.conf-sample
|
|
|
|
@${MKDIR} ${PREFIX}/libexec/${PORTNAME}/html-templates/
|
|
|
|
@${INSTALL_DATA} ${WRKSRC}/html-templates/default.html ${PREFIX}/libexec/${PORTNAME}/html-templates/
|
|
|
|
@${INSTALL_DATA} ${WRKSRC}/html-templates/graphindex.html ${PREFIX}/libexec/${PORTNAME}/html-templates/
|
|
|
|
|
|
|
|
post-install:
|
|
|
|
.if !defined(NOPORTDOCS)
|
|
|
|
@${MKDIR} ${DOCSDIR}
|
|
|
|
.for file in ${DOC_FILES}
|
|
|
|
@${INSTALL_DATA} ${WRKSRC}/${file} ${DOCSDIR}
|
|
|
|
.endfor
|
|
|
|
.endif
|
|
|
|
|
2009-07-22 18:27:08 +02:00
|
|
|
.include <bsd.port.mk>
|