Date: Fri, 7 Dec 2012 19:24:29 +0000 (UTC) From: Ryan Steinmetz <zi@FreeBSD.org> To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r308443 - in head/net: . hsflowd hsflowd/files Message-ID: <201212071924.qB7JOTib066966@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: zi Date: Fri Dec 7 19:24:29 2012 New Revision: 308443 URL: http://svnweb.freebsd.org/changeset/ports/308443 Log: New port: net/hsflowd: The Host sFlow agent exports physical and virtual server performance metrics using the sFlow protocol. The agent provides scalable, multi-vendor, multi-OS performance monitoring with minimal impact on the systems being monitored. WWW: http://host-sflow.sourceforge.net/ Feature safe: yes Added: head/net/hsflowd/ head/net/hsflowd/Makefile (contents, props changed) head/net/hsflowd/distinfo (contents, props changed) head/net/hsflowd/files/ head/net/hsflowd/files/hsflowd.in (contents, props changed) head/net/hsflowd/files/pkg-message.in (contents, props changed) head/net/hsflowd/pkg-descr (contents, props changed) head/net/hsflowd/pkg-plist (contents, props changed) Modified: head/net/Makefile Modified: head/net/Makefile ============================================================================== --- head/net/Makefile Fri Dec 7 17:57:16 2012 (r308442) +++ head/net/Makefile Fri Dec 7 19:24:29 2012 (r308443) @@ -229,6 +229,7 @@ SUBDIR += hs-sendfile SUBDIR += hs-simple-sendfile SUBDIR += hs-socks + SUBDIR += hsflowd SUBDIR += htpdate SUBDIR += http_ping SUBDIR += httping Added: head/net/hsflowd/Makefile ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/net/hsflowd/Makefile Fri Dec 7 19:24:29 2012 (r308443) @@ -0,0 +1,36 @@ +# Created by: Ryan Steinmetz <zi@FreeBSD.org> +# $FreeBSD$ + +PORTNAME= hsflowd +PORTVERSION= 1.22.2 +CATEGORIES= net +MASTER_SITES= SF/host-sflow/REL-1_22/ \ + http://mirrors.rit.edu/zi/ + +MAINTAINER= zi@FreeBSD.org +COMMENT= Agent that exports metrics using the sFlow protocol + +MAKE_JOBS_UNSAFE= no +SUB_FILES= pkg-message +USE_RC_SUBR= ${PORTNAME} +MAKE_ENV= BINDIR=${PREFIX}/sbin INITDIR=${PREFIX}/etc/rc.d \ + CONFDIR=${ETCDIR} + +post-patch: + @${REINPLACE_CMD} -e 's|gcc|${CC}|g' \ + -e '/scripts\/hsflowd /d' \ + -e 's|hsflowd.conf|hsflowd.conf.sample|g' \ + ${WRKSRC}/src/FreeBSD/Makefile ${WRKSRC}/src/sflow/Makefile \ + ${WRKSRC}/src/json/Makefile + @${REINPLACE_CMD} -e 's|/etc|${ETCDIR}|g' ${WRKSRC}/src/FreeBSD/hsflowd.h + @${REINPLACE_CMD} -e 's|/usr|${PREFIX}|g' \ + ${WRKSRC}/src/FreeBSD/scripts/hsflowd + @${MV} ${WRKSRC}/src/FreeBSD/scripts/hsflowd.conf \ + ${WRKSRC}/src/FreeBSD/scripts/hsflowd.conf.sample + +post-install: + @if [ ! -f ${ETCDIR}/hsflowd.conf ]; then \ + ${CP} ${ETCDIR}/hsflowd.conf.sample ${ETCDIR}/hsflowd.conf ; \ + fi + +.include <bsd.port.mk> Added: head/net/hsflowd/distinfo ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/net/hsflowd/distinfo Fri Dec 7 19:24:29 2012 (r308443) @@ -0,0 +1,2 @@ +SHA256 (hsflowd-1.22.2.tar.gz) = 648806afa02cb5588dd69aba54be0d5810f56af112003a861df0aadd6c28611c +SIZE (hsflowd-1.22.2.tar.gz) = 1841547 Added: head/net/hsflowd/files/hsflowd.in ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/net/hsflowd/files/hsflowd.in Fri Dec 7 19:24:29 2012 (r308443) @@ -0,0 +1,29 @@ +#!/bin/sh +# +# init(1) startup script for hsflowd daemon +# +# description: Host sFlow Daemon +# processname: hsflowd +# pidfile: /var/run/hsflowd.pid +# + +. /etc/rc.subr + + +name=hsflowd +rcvar=`set_rcvar` + +load_rc_config $name + +hsflowd_enable=${hsflowd_enable:-"NO"} + +stop_postcmd="hsflowd_postcmd" + +command="%%PREFIX%%/sbin/${name}" +pidfile="/var/run/${name}.pid" + +hsflowd_postcmd() { + rm -f $pidfile +} + +run_rc_command "$1" Added: head/net/hsflowd/files/pkg-message.in ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/net/hsflowd/files/pkg-message.in Fri Dec 7 19:24:29 2012 (r308443) @@ -0,0 +1,4 @@ +Please edit %%ETCDIR%%/hsflowd.conf based on your needs and add the following +to /etc/rc.conf: + +hsflowd_enable="YES" Added: head/net/hsflowd/pkg-descr ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/net/hsflowd/pkg-descr Fri Dec 7 19:24:29 2012 (r308443) @@ -0,0 +1,6 @@ +The Host sFlow agent exports physical and virtual server performance +metrics using the sFlow protocol. The agent provides scalable, +multi-vendor, multi-OS performance monitoring with minimal impact on +the systems being monitored. + +WWW: http://host-sflow.sourceforge.net/ Added: head/net/hsflowd/pkg-plist ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/net/hsflowd/pkg-plist Fri Dec 7 19:24:29 2012 (r308443) @@ -0,0 +1,6 @@ +@comment $FreeBSD$ +etc/hsflowd/hsflowd.conf.sample +sbin/hsflowd +@dirrmtry etc/hsflowd +@unexec if cmp -s %D/etc/hsflowd/hsflowd.conf %D/etc/hsflowd.conf.sample; then rm -f %D/etc/hsflowd.conf; fi +@unexec if [ -d %%ETCDIR%% ]; then echo "==> If you are permanently removing this port, you should do a ``rm -rf %%ETCDIR%%`` to remove any configuration files."; fi
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201212071924.qB7JOTib066966>