diff options
author | edwin <edwin@FreeBSD.org> | 2003-10-08 19:22:32 +0800 |
---|---|---|
committer | edwin <edwin@FreeBSD.org> | 2003-10-08 19:22:32 +0800 |
commit | b8f76f0a72f24a3e283f18f4cc1c7e0be7f1e5ef (patch) | |
tree | 00053a8fafb2dc9db5de86ef761f7b05c94121cc /www/pglogd | |
parent | 4231ca19396ec1596bf8e5a5d2c1dbb6b8371d5a (diff) | |
download | freebsd-ports-gnome-b8f76f0a72f24a3e283f18f4cc1c7e0be7f1e5ef.tar.gz freebsd-ports-gnome-b8f76f0a72f24a3e283f18f4cc1c7e0be7f1e5ef.tar.zst freebsd-ports-gnome-b8f76f0a72f24a3e283f18f4cc1c7e0be7f1e5ef.zip |
NEW PORT: pglod - inserts web logs into a PostgreSQL database
pgLOGd, simply put, is a program that takes web server log
entries and sends them to a database. It is called pgLOGd
because of the database it was designed to function with,
PostgreSQL.
It is fast, robust and features fall-back-logging to a text
file. It is flexible and typically uses less than 128K of
memory.
PR: ports/51647
Submitted by: Allie Micka <allie@pajunas.com>
Diffstat (limited to 'www/pglogd')
-rw-r--r-- | www/pglogd/Makefile | 33 | ||||
-rw-r--r-- | www/pglogd/distinfo | 1 | ||||
-rw-r--r-- | www/pglogd/files/020.pglogd.sh | 17 | ||||
-rw-r--r-- | www/pglogd/files/patch-Makefile | 25 | ||||
-rw-r--r-- | www/pglogd/pkg-descr | 8 | ||||
-rw-r--r-- | www/pglogd/pkg-message | 17 | ||||
-rw-r--r-- | www/pglogd/pkg-plist | 11 |
7 files changed, 112 insertions, 0 deletions
diff --git a/www/pglogd/Makefile b/www/pglogd/Makefile new file mode 100644 index 000000000000..7b819c648cf9 --- /dev/null +++ b/www/pglogd/Makefile @@ -0,0 +1,33 @@ +# New ports collection makefile for: pglogd +# Date created: 23 April 2003 +# Whom: Allie Micka <allie@pajunas.com> +# +# $FreeBSD$ +# + +PORTNAME= pglogd +PORTVERSION= 2.2b +CATEGORIES= www databases +MASTER_SITES= http://www.digitalstratum.com/pglogd/ +DISTNAME= pglogd-2.2beta + +MAINTAINER= allie@pajunas.com +COMMENT= Sends web server log entries to a PostgreSQL database + +LIB_DEPENDS= pq.3:${PORTSDIR}/databases/postgresql7 + +USE_REINPLACE= yes + +post-extract: + @${CP} ${FILESDIR}/020.pglogd.sh ${WRKSRC}/020.pglogd.sh + @${REINPLACE_CMD} -e "s=%%PREFIX%%=${PREFIX}=g" ${WRKSRC}/020.pglogd.sh + +post-install: + ${INSTALL_DATA} ${WRKSRC}/020.pglogd.sh ${PREFIX}/etc/rc.d/020.pglogd.sh + @if [ ! -f ${PREFIX}/etc/rc.d/020.pglogd.sh ]; then \ + ${ECHO} "Installing ${PREFIX}/etc/rc.d/020.pglogd.sh startup file."; \ + ${INSTALL_SCRIPT} ${WRKSRC}/020.pglogd.sh ${PREFIX}/etc/rc.d/020.pglogd.sh; \ + fi + @${CAT} ${PKGMESSAGE} + +.include <bsd.port.mk> diff --git a/www/pglogd/distinfo b/www/pglogd/distinfo new file mode 100644 index 000000000000..5a87cdd94770 --- /dev/null +++ b/www/pglogd/distinfo @@ -0,0 +1 @@ +MD5 (pglogd-2.2beta.tar.gz) = af94fba991e7bf432f8464f787319708 diff --git a/www/pglogd/files/020.pglogd.sh b/www/pglogd/files/020.pglogd.sh new file mode 100644 index 000000000000..7494cb35180e --- /dev/null +++ b/www/pglogd/files/020.pglogd.sh @@ -0,0 +1,17 @@ +#!/bin/sh +CONFIG=%%PREFIX%%/pglogd.conf +PID=/var/run/pglogd.pid + +case "$1" in +start) + [ -r ${CONFIG} ] && [ -x %%PREFIX%%/bin/pglogd ] && %%PREFIX%%/bin/pglogd -s -c ${CONFIG} > /dev/null && echo -n ' pglogd' + ;; +stop) + [ -r ${PID} ] && kill `cat ${PID}` > /dev/null && echo -n ' pglogd' + ;; +*) + echo "Usage: `basename $0` {start|stop}" >&2 + ;; +esac + +exit 0 diff --git a/www/pglogd/files/patch-Makefile b/www/pglogd/files/patch-Makefile new file mode 100644 index 000000000000..51e6cd9ccfe7 --- /dev/null +++ b/www/pglogd/files/patch-Makefile @@ -0,0 +1,25 @@ +--- Makefile Sat Jan 19 11:05:45 2002 ++++ Makefile.new Wed Apr 23 17:28:05 2003 +@@ -31,7 +31,7 @@ + # + + # Change this to your PostgreSQL install directroy. +-PGDIR = /usr/local/pgsql ++PGDIR = ${PREFIX} + + + ### NO NEED TO EDIT BELOW THIS LINE ### +@@ -56,3 +56,13 @@ + + pglog_dump : ${SRCS_DUMP} ${HDRS_DUMP} + ${CC} ${COPTS} -o $@ ${CFLAGS} ${LDFLAGS} ${LIBS} ${SRCS_DUMP} ++ ++install : ++ install -m 750 -s -c pglogd ${PREFIX}/bin/ ++ install -m 755 -d ${PREFIX}/share/pglogd/ ++ install -m 644 -c pglogd_tables.sql ${PREFIX}/share/pglogd/pglogd_tables.sql ++ install -m 644 -c README ${PREFIX}/share/pglogd/README ++ install -m 644 -c CHANGELOG ${PREFIX}/share/pglogd/CHANGELOG ++ install -m 644 -c weblog_daily.sql ${PREFIX}/share/pglogd/weblog_daily.sql ++ install -m 644 -c queries.txt ${PREFIX}/share/pglogd/queries.txt ++ install -m 644 -c pglogd.conf ${PREFIX}/etc/pglogd.conf.sample diff --git a/www/pglogd/pkg-descr b/www/pglogd/pkg-descr new file mode 100644 index 000000000000..66c547a29907 --- /dev/null +++ b/www/pglogd/pkg-descr @@ -0,0 +1,8 @@ +pgLOGd, simply put, is a program that takes web server log entries and +sends them to a database. It is called pgLOGd because of the database +it was designed to function with, PostgreSQL. + +It is fast, robust and features fall-back-logging to a text file. It +is flexible and typically uses less than 128K of memory. + +WWW: http://www.digitalstratum.com/pglogd/ diff --git a/www/pglogd/pkg-message b/www/pglogd/pkg-message new file mode 100644 index 000000000000..9a2e29a522ad --- /dev/null +++ b/www/pglogd/pkg-message @@ -0,0 +1,17 @@ +========================================================= +You need to create a PostgreSQL database for your logs: + + # su - postgres + $ createdb pglogd + $ psql pglogd < /usr/local/share/pglogd/pglogd_tables.sql + $ exit + +and copy /usr/local/etc/pglogd.conf.sample to pglogd.conf + +pglogd can then be started with: + + # /usr/local/etc/rc.d/020.pglogd.sh start + +Read the complete documentation on configuring pglogd +and apache at http://www.digitalstratum.com/pglogd/ +========================================================= diff --git a/www/pglogd/pkg-plist b/www/pglogd/pkg-plist new file mode 100644 index 000000000000..8767dc370d48 --- /dev/null +++ b/www/pglogd/pkg-plist @@ -0,0 +1,11 @@ +bin/pglogd +share/pglogd/pglogd_tables.sql +share/pglogd/queries.txt +share/pglogd/weblog_daily.sql +share/pglogd/README +share/pglogd/CHANGELOG +etc/pglogd.conf.sample +etc/rc.d/020.pglogd.sh +@dirrm share/pglogd +@unexec if cmp -s %D/etc/rc.d/020.pglogd.sh %D/etc/rc.d/020.pglogd.sh-dist; then rm -f %D/etc/rc.d/020.pglogd.sh; fi +@exec [ -f %B/020.pglogd.sh ] || ( cp %B/%f %B/020.pglogd.sh; chmod 755 %B/020.pglogd.sh ) |