diff options
author | krion <krion@FreeBSD.org> | 2003-11-03 01:37:15 +0800 |
---|---|---|
committer | krion <krion@FreeBSD.org> | 2003-11-03 01:37:15 +0800 |
commit | dab15b4f139cb1106c2491fae0f62d78dd5f43be (patch) | |
tree | ebbb06f59a39cb5a00bb7bed987781c6616bbccf /net/AquaGatekeeper | |
parent | 32d216afab5cad0fe46784f3850aadabb768a1f2 (diff) | |
download | freebsd-ports-graphics-dab15b4f139cb1106c2491fae0f62d78dd5f43be.tar.gz freebsd-ports-graphics-dab15b4f139cb1106c2491fae0f62d78dd5f43be.tar.zst freebsd-ports-graphics-dab15b4f139cb1106c2491fae0f62d78dd5f43be.zip |
This is new port for AquaGatekeeper by The Aqua Group.
It can be used as H.323 gatekeeper, IP-to-IP voice gateway
or proxy. It can be used to pass voice traffic from private
networks to the Internet and vice versa when runs on the NAT
box.It provides billing information and
can optionally use RADUIS.
PR: 58833
Submitted by: Eugene Grosbein <eugen@grosbein.pp.ru>
Diffstat (limited to 'net/AquaGatekeeper')
-rw-r--r-- | net/AquaGatekeeper/Makefile | 53 | ||||
-rw-r--r-- | net/AquaGatekeeper/distinfo | 1 | ||||
-rw-r--r-- | net/AquaGatekeeper/files/agk.sh.sample | 37 | ||||
-rw-r--r-- | net/AquaGatekeeper/pkg-deinstall | 65 | ||||
-rw-r--r-- | net/AquaGatekeeper/pkg-descr | 12 | ||||
-rw-r--r-- | net/AquaGatekeeper/pkg-install | 80 | ||||
-rw-r--r-- | net/AquaGatekeeper/pkg-message | 5 | ||||
-rw-r--r-- | net/AquaGatekeeper/pkg-plist | 15 |
8 files changed, 268 insertions, 0 deletions
diff --git a/net/AquaGatekeeper/Makefile b/net/AquaGatekeeper/Makefile new file mode 100644 index 00000000000..ff3353e0ff3 --- /dev/null +++ b/net/AquaGatekeeper/Makefile @@ -0,0 +1,53 @@ +# New ports collection makefile for: AquaGatekeeper +# Date created: 2 November 2003 +# Whom: Eugene Grosbein <eugen@grosbein.pp.ru> +# +# $FreeBSD$ +# + +PORTNAME= AquaGatekeeper +PORTVERSION= 1.17 +CATEGORIES= net +MASTER_SITES= ftp://ftp.aqua.comptek.ru/pub/GateKeeper/ \ + ftp://www.kuzbass.ru/pub/FreeBSD/ports/distfiles/ +DISTNAME= AquaGatekeeper117FreeBSD +EXTRACT_SUFX= .tgz + +MAINTAINER= eugen@grosbein.pp.ru +COMMENT= Aqua H323 Gatekeeper and proxy + +WRKSRC= ${WRKDIR}/${PORTNAME} +NO_BUILD= yes +ONLY_FOR_ARCHS= i386 + +NO_PACKAGE= "No commercial redistribution" +NO_CDROM= "No commercial redistribution" + +.if !defined(BATCH) && !defined(PACKAGE_BUILDING) +IS_INTERACTIVE= yes +.endif + +do-install: + @${INSTALL_PROGRAM} ${WRKSRC}/AquaGatekeeper ${PREFIX}/bin/ + @${INSTALL_SCRIPT} ${FILESDIR}/agk.sh.sample ${PREFIX}/etc/rc.d/ + @${INSTALL_DATA} ${WRKSRC}/Config/AquaGatekeeper.cfg ${PREFIX}/etc/AquaGatekeeper.cfg.sample + @${MKDIR} ${EXAMPLESDIR} + @${INSTALL_DATA} ${WRKSRC}/Config/Example.cfg ${EXAMPLESDIR} +.if !defined(NOPORTDOCS) + @${MKDIR} ${DOCSDIR} + @for docfile in ${WRKSRC}/Help/*; \ + do ${INSTALL_MAN} $$docfile ${DOCSDIR}; \ + done +.endif + +post-install: + @${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL + @${SED} "s'%%PREFIX%%'${PREFIX}'" < pkg-message + +.include <bsd.port.pre.mk> + +.if ${OSVERSION} > 500000 || ${OSVERSION} < 400000 +BROKEN= "Supported only on 4.x systems" +.endif + +.include <bsd.port.post.mk> diff --git a/net/AquaGatekeeper/distinfo b/net/AquaGatekeeper/distinfo new file mode 100644 index 00000000000..f258dbb9163 --- /dev/null +++ b/net/AquaGatekeeper/distinfo @@ -0,0 +1 @@ +MD5 (AquaGatekeeper117FreeBSD.tgz) = 68fded95233caff1cc05bbac953cd8b7 diff --git a/net/AquaGatekeeper/files/agk.sh.sample b/net/AquaGatekeeper/files/agk.sh.sample new file mode 100644 index 00000000000..e97c1a902e3 --- /dev/null +++ b/net/AquaGatekeeper/files/agk.sh.sample @@ -0,0 +1,37 @@ +#!/bin/sh + +PREFIX=$(expr `realpath $0` : "\(/.*\)/etc/rc\.d/`basename $0`\$") +PROG=$PREFIX/bin/AquaGatekeeper +CFG=$PREFIX/etc/agk.cfg +TIMEOUT=30 + +case "$1" in +start) + shift + su -m agk -c "[ -x $PROG -a -r $CFG ] && + echo -n ' AquaGatekeeper' && $PROG -d --configuration=$CFG $@" + ;; +stop) + shift + signal=-TERM + [ -n "$1" ] && signal="$1" + killall $signal AquaGatekeeper + [ $signal != -2 -a $signal != -INT ] && exit 0 + i=1 + while [ $i -le $TIMEOUT ] + do + ps -axc | grep -q AquaGatekeeper || break + i=$(($i+1)) + sleep 1 + done + ;; +restart) + `realpath $0` stop -INT + `realpath $0` start + ;; +*) + echo "Usage: `basename $0` {start|stop|restart}" >&2 + ;; +esac + +exit 0 diff --git a/net/AquaGatekeeper/pkg-deinstall b/net/AquaGatekeeper/pkg-deinstall new file mode 100644 index 00000000000..d89d859698b --- /dev/null +++ b/net/AquaGatekeeper/pkg-deinstall @@ -0,0 +1,65 @@ +#!/bin/sh + +USER=agk +GROUP=agk + +ask() { + local question default answer + + question=$1 + default=$2 + if [ -z "${PACKAGE_BUILDING}" ]; then + read -p "${question} [${default}]? " answer + fi + if [ x${answer} = x ]; then + answer=${default} + fi + echo ${answer} +} + +yesno() { + local dflt question answer + + question=$1 + dflt=$2 + while :; do + answer=$(ask "${question}" "${dflt}") + case "${answer}" in + [Yy]*) return 0;; + [Nn]*) return 1;; + esac + echo "Please answer yes or no." + done +} + +delete_account() { + local u g + + u=$1 + g=$2 + if yesno "Do you want me to remove group \"${g}\"" y; then + pw groupdel -n ${g} + echo "Done." + fi + if yesno "Do you want me to remove user \"${u}\"" y; then + pw userdel -n ${u} + echo "Done." + fi +} + +[ "$2" = DEINSTALL ] || exit 0 + +export PATH=/bin:/usr/bin:/usr/sbin + +if ps -axc | grep -q AquaGatekeeper; then + if yesno "There are some AquaGatekeeper processes running. Shall I kill them" y + then + killall AquaGatekeeper + sleep 2 + else + echo "OK ... I hope you know what you are doing." + fi +fi + +delete_account ${USER} ${GROUP} +exit 0 diff --git a/net/AquaGatekeeper/pkg-descr b/net/AquaGatekeeper/pkg-descr new file mode 100644 index 00000000000..a8ba595db4a --- /dev/null +++ b/net/AquaGatekeeper/pkg-descr @@ -0,0 +1,12 @@ +Aqua Gatekeeper is H.323 gatekeeper and proxy by Aqua Project Group. +It is compatible with many hardware/software like Cisco H.323 gateways and +Microsoft NetMeeting 3.01 for Windows 2000 and later. + +This port presents Aqua Gatekeeper Startup Edition. +It is not a free software but may be used free of charge. +The Aqua Gatekeeper Startup Edition is limited to 30 concurrent calls. + +WWW: http://www.aqua.comptek.ru/man/voip/gatekeeper/index.htm + +- Grosbein +eugen@grosbein.pp.ru diff --git a/net/AquaGatekeeper/pkg-install b/net/AquaGatekeeper/pkg-install new file mode 100644 index 00000000000..233bb70ff96 --- /dev/null +++ b/net/AquaGatekeeper/pkg-install @@ -0,0 +1,80 @@ +#!/bin/sh + +USER=agk +UID=172 +GROUP=${USER} +GID=${UID} + +ask() { + local question default answer + + question=$1 + default=$2 + if [ -z "${PACKAGE_BUILDING}" ]; then + read -p "${question} [${default}]? " answer + fi + if [ x${answer} = x ]; then + answer=${default} + fi + echo ${answer} +} + +yesno() { + local dflt question answer + + question=$1 + dflt=$2 + while :; do + answer=$(ask "${question}" "${dflt}") + case "${answer}" in + [Yy]*) return 0;; + [Nn]*) return 1;; + esac + echo "Please answer yes or no." + done +} + +make_account() { + local u g uid gid gcos + + u=$1 + uid=$2 + g=$3 + gid=$4 + gcos=$5 + + if pw group show "${g}" >/dev/null 2>&1; then + echo "You already have a group \"${g}\", so I will use it." + else + echo "You need a group \"${g}\"." + if which -s pw && yesno "Would you like me to create it" y; then + pw groupadd -n ${g} -g ${gid} || exit + echo "Done." + else + echo "Please create it, and try again." + if ! grep -q "^${u}:" /etc/passwd; then + echo "While you're at it, please create a user \"${u}\" too," + echo "with a default group of \"${g}\"." + fi + exit 1 + fi + fi + + if pw user show "${u}" >/dev/null 2>&1; then + echo "You already have a user \"${u}\", so I will use it." + else + echo "You need a user \"${u}\"." + if which -s pw && yesno "Would you like me to create it" y; then + pw useradd -n ${u} -u ${uid} -g ${g} -h - -d /nonexistent \ + -s /nonexistent -c "${gcos}" || exit + echo "Done." + else + echo "Please create it, and try again." + exit 1 + fi + fi +} + +[ "$2" = POST-INSTALL ] || exit 0 + +make_account ${USER} ${UID} ${GROUP} ${GID} "AquaGateKeeper" diff --git a/net/AquaGatekeeper/pkg-message b/net/AquaGatekeeper/pkg-message new file mode 100644 index 00000000000..005fb0e618f --- /dev/null +++ b/net/AquaGatekeeper/pkg-message @@ -0,0 +1,5 @@ +**************************************************************************** + Please read documentation located in %%PREFIX%%/share/doc/AquaGatekeeper + You will need to write configuration file to run the Gatekeeper. + Some examples are in %%PREFIX%%/share/examples/AquaGatekeeper +**************************************************************************** diff --git a/net/AquaGatekeeper/pkg-plist b/net/AquaGatekeeper/pkg-plist new file mode 100644 index 00000000000..ee8d8a40961 --- /dev/null +++ b/net/AquaGatekeeper/pkg-plist @@ -0,0 +1,15 @@ +bin/AquaGatekeeper +etc/rc.d/agk.sh.sample +etc/AquaGatekeeper.cfg.sample +%%PORTDOCS%%%%DOCSDIR%%/AquaGatekeeper.htm +%%PORTDOCS%%%%DOCSDIR%%/AquaGatekeeperMonitor.chm +%%PORTDOCS%%%%DOCSDIR%%/CommandLineOptions.htm +%%PORTDOCS%%%%DOCSDIR%%/ConfigSyntax.htm +%%PORTDOCS%%%%DOCSDIR%%/License.rtf +%%PORTDOCS%%%%DOCSDIR%%/LicenseRus.rtf +%%PORTDOCS%%%%DOCSDIR%%/OperationPrinciples.htm +%%PORTDOCS%%%%DOCSDIR%%/RevisionHistory.htm +%%PORTDOCS%%%%DOCSDIR%%/default.css +%%EXAMPLESDIR%%/Example.cfg +%%PORTDOCS%%@dirrm %%DOCSDIR%% +%%PORTDOCS%%@dirrm %%EXAMPLESDIR%% |