Add mod_watch4 4.3, an Apache2 module to monitor bandwidth usage, for
use with MRTG etc. PR: 57865 Submitted by: Toshiya SAITOH <toshiya@saitoh.nu> Approved by: erwin (mentor) (implicitly)
This commit is contained in:
parent
2824eec981
commit
f42f9284f3
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=97768
7 changed files with 123 additions and 0 deletions
|
@ -273,6 +273,7 @@
|
|||
SUBDIR += mod_v2h
|
||||
SUBDIR += mod_vdbh
|
||||
SUBDIR += mod_watch
|
||||
SUBDIR += mod_watch4
|
||||
SUBDIR += mod_webapp
|
||||
SUBDIR += mod_zap
|
||||
SUBDIR += moinmoin
|
||||
|
|
58
www/mod_watch4/Makefile
Normal file
58
www/mod_watch4/Makefile
Normal file
|
@ -0,0 +1,58 @@
|
|||
# New ports collection makefile for: mod_watch4
|
||||
# Date created: 11 Octber 2003
|
||||
# Whom: Toshiya SAITOH <toshiya@saitoh.nu>
|
||||
#
|
||||
# $FreeBSD$
|
||||
#
|
||||
|
||||
PORTNAME= mod_watch
|
||||
PORTVERSION= 4.3
|
||||
CATEGORIES= www
|
||||
MASTER_SITES= http://www.snert.com/Software/download/
|
||||
DISTNAME= ${PORTNAME}${PORTVERSION:S/./0/g}
|
||||
EXTRACT_SUFX= .tgz
|
||||
DIST_SUBDIR= apache2
|
||||
|
||||
MAINTAINER= toshiya@saitoh.nu
|
||||
COMMENT= An Apache2 module to monitor bandwidth usage, for use with MRTG etc
|
||||
|
||||
RUN_DEPENDS= mrtg:${PORTSDIR}/net/mrtg
|
||||
|
||||
NO_PACKAGE= "Binary package distribution is prohibited by license"
|
||||
NO_CDROM= "Commercial distfile distribution is prohibited by license"
|
||||
|
||||
USE_PERL5_RUN= yes
|
||||
USE_APACHE= yes
|
||||
WITH_APACHE2= yes
|
||||
|
||||
WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVERSION}
|
||||
MAKEFILE= Makefile.dso
|
||||
|
||||
MAKE_ARGS+= APXS="${APXS}"
|
||||
|
||||
ALL_TARGET= build
|
||||
|
||||
DOCS= apache2mrtg.shtml index.shtml mailto.js mod_watch.shtml style.css
|
||||
DOCS_HTMLIMAGES= apache-header-476-62.png mrpixel.gif mrtg-bar.png \
|
||||
sun-logo.jpg wave1.jpg
|
||||
|
||||
do-install:
|
||||
${APXS} -i -a -n watch ${WRKSRC}/mod_watch.la
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/apache2mrtg.pl ${PREFIX}/sbin
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/mod_watch.pl ${PREFIX}/sbin
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/nfields.pl ${PREFIX}/sbin
|
||||
.if !defined(NOPORTDOCS)
|
||||
@${INSTALL} -d -m 0755 ${DOCSDIR}/html/Img
|
||||
${INSTALL_DATA} ${WRKSRC}/CHANGES.TXT ${DOCSDIR}/
|
||||
${INSTALL_DATA} ${WRKSRC}/LICENSE.TXT ${DOCSDIR}/
|
||||
.for f in ${DOCS}
|
||||
${INSTALL_DATA} ${WRKSRC}/${f} ${DOCSDIR}/html/
|
||||
.endfor
|
||||
.for f in ${DOCS_HTMLIMAGES}
|
||||
${INSTALL_DATA} ${WRKSRC}/Img/${f} ${DOCSDIR}/html/Img/
|
||||
.endfor
|
||||
.endif
|
||||
@${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL
|
||||
@${CAT} ${PKGMESSAGE}
|
||||
|
||||
.include <bsd.port.mk>
|
1
www/mod_watch4/distinfo
Normal file
1
www/mod_watch4/distinfo
Normal file
|
@ -0,0 +1 @@
|
|||
MD5 (apache2/mod_watch403.tgz) = 06d57713adb935f16596d22256bca913
|
8
www/mod_watch4/pkg-descr
Normal file
8
www/mod_watch4/pkg-descr
Normal file
|
@ -0,0 +1,8 @@
|
|||
This Apache module will watch and collect the bytes in & out per virtual host,
|
||||
per file owner, and the web server as a whole. It was designed for use with
|
||||
MRTG, which will make nice graphical representations of the data, but is
|
||||
general enough that it can be applied to other purposes.
|
||||
|
||||
WWW: http://www.snert.com/Software/mod_watch/
|
||||
|
||||
- Toshiya Saitoh <toshiya@saitoh.nu>
|
14
www/mod_watch4/pkg-install
Normal file
14
www/mod_watch4/pkg-install
Normal file
|
@ -0,0 +1,14 @@
|
|||
#!/bin/sh
|
||||
|
||||
case $2 in
|
||||
PRE-INSTALL)
|
||||
;;
|
||||
POST-INSTALL)
|
||||
install -d -o www -g www -m 0755 /var/spool/mod_watch
|
||||
;;
|
||||
*)
|
||||
echo "Unexpected Argument $2."
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
exit 0
|
20
www/mod_watch4/pkg-message
Normal file
20
www/mod_watch4/pkg-message
Normal file
|
@ -0,0 +1,20 @@
|
|||
************************************************************
|
||||
You've installed mod_watch, a module to monitor bandwidth
|
||||
usage.
|
||||
|
||||
/var/spool/mod_watch has been created. It's owned by user
|
||||
www and group www. For mod_watch to work, the Apache
|
||||
user/group must be able to create and update files in this
|
||||
directory.
|
||||
|
||||
Edit your apache.conf or httpd.conf to enable and setup this
|
||||
module. Have a look at the files in
|
||||
${PREFIX}/share/doc/mod_watch/html for information on how to
|
||||
configure it etc.
|
||||
|
||||
Then do this to make it work effective:
|
||||
|
||||
# apachectl configtest (see if there are any config errors)
|
||||
# apachectl restart
|
||||
|
||||
************************************************************
|
21
www/mod_watch4/pkg-plist
Normal file
21
www/mod_watch4/pkg-plist
Normal file
|
@ -0,0 +1,21 @@
|
|||
sbin/apache2mrtg.pl
|
||||
sbin/mod_watch.pl
|
||||
sbin/nfields.pl
|
||||
libexec/apache2/mod_watch.so
|
||||
@exec %D/sbin/apxs -e -A -n watch %D/%F
|
||||
@unexec %D/sbin/apxs -e -A -n watch %D/%F
|
||||
%%PORTDOCS%%%%DOCSDIR%%/html/Img/apache-header-476-62.png
|
||||
%%PORTDOCS%%%%DOCSDIR%%/html/Img/mrpixel.gif
|
||||
%%PORTDOCS%%%%DOCSDIR%%/html/Img/mrtg-bar.png
|
||||
%%PORTDOCS%%%%DOCSDIR%%/html/Img/sun-logo.jpg
|
||||
%%PORTDOCS%%%%DOCSDIR%%/html/Img/wave1.jpg
|
||||
%%PORTDOCS%%%%DOCSDIR%%/html/apache2mrtg.shtml
|
||||
%%PORTDOCS%%%%DOCSDIR%%/html/index.shtml
|
||||
%%PORTDOCS%%%%DOCSDIR%%/html/mailto.js
|
||||
%%PORTDOCS%%%%DOCSDIR%%/html/mod_watch.shtml
|
||||
%%PORTDOCS%%%%DOCSDIR%%/html/style.css
|
||||
%%PORTDOCS%%%%DOCSDIR%%/CHANGES.TXT
|
||||
%%PORTDOCS%%%%DOCSDIR%%/LICENSE.TXT
|
||||
%%PORTDOCS%%@dirrm %%DOCSDIR%%/html/Img
|
||||
%%PORTDOCS%%@dirrm %%DOCSDIR%%/html
|
||||
%%PORTDOCS%%@dirrm %%DOCSDIR%%
|
Loading…
Reference in a new issue