diff options
author | Munechika SUMIKAWA <sumikawa@FreeBSD.org> | 2002-11-03 15:43:59 +0000 |
---|---|---|
committer | Munechika SUMIKAWA <sumikawa@FreeBSD.org> | 2002-11-03 15:43:59 +0000 |
commit | 1e3c877f0532697ca1f59b5b71b6ee70a20a1db6 (patch) | |
tree | f8af1e6b4223cbacad5c4ecab33f4d954097a20c /security | |
parent | Correct pkg-plist. (diff) |
Add startup script.
Submitted by: Sam Pikesley <samdavidpikesley@yahoo.co.uk>
Notes
Notes:
svn path=/head/; revision=69354
Diffstat (limited to 'security')
-rw-r--r-- | security/racoon/Makefile | 3 | ||||
-rw-r--r-- | security/racoon/files/racoon.sh | 18 | ||||
-rw-r--r-- | security/racoon2/Makefile | 3 | ||||
-rw-r--r-- | security/racoon2/files/racoon.sh | 18 |
4 files changed, 42 insertions, 0 deletions
diff --git a/security/racoon/Makefile b/security/racoon/Makefile index 5aec98aaab68..a6ac14807697 100644 --- a/security/racoon/Makefile +++ b/security/racoon/Makefile @@ -7,6 +7,7 @@ PORTNAME= racoon PORTVERSION= 20020507a +PORTREVISION= 1 CATEGORIES= security net MASTER_SITES= ftp://ftp.kame.net/pub/kame/misc/ @@ -37,6 +38,8 @@ pre-configure: (cd ${WRKSRC}/../libipsec; make) post-install: + @${SED} 's@%PREFIX%@${LOCALBASE}@g' ${FILESDIR}/racoon.sh > ${PREFIX}/etc/rc.d/racoon.sh + @${CHMOD} +x ${PREFIX}/etc/rc.d/racoon.sh @if [ -z `/sbin/sysctl -a | ${GREP} -q ipsec && echo ipsec` ]; then \ ${ECHO_MSG} "WARNING: IPsec feature is disabled on this host"; \ ${ECHO_MSG} " You must build the kernel if you want to run racoon on the host"; \ diff --git a/security/racoon/files/racoon.sh b/security/racoon/files/racoon.sh new file mode 100644 index 000000000000..d6a5c1b3098a --- /dev/null +++ b/security/racoon/files/racoon.sh @@ -0,0 +1,18 @@ +#!/bin/sh + +case "$1" in + start) + if [ -x %PREFIX%/sbin/racoon ]; then + %PREFIX%/sbin/racoon -f %PREFIX%/etc/racoon/racoon.conf && echo -n ' racoon' + fi + ;; + + stop) + /usr/bin/killall racoon && echo -n ' racoon' + ;; + + *) + echo "Usage: `basename $0` { start | stop }" + exit 64 + ;; +esac diff --git a/security/racoon2/Makefile b/security/racoon2/Makefile index 5aec98aaab68..a6ac14807697 100644 --- a/security/racoon2/Makefile +++ b/security/racoon2/Makefile @@ -7,6 +7,7 @@ PORTNAME= racoon PORTVERSION= 20020507a +PORTREVISION= 1 CATEGORIES= security net MASTER_SITES= ftp://ftp.kame.net/pub/kame/misc/ @@ -37,6 +38,8 @@ pre-configure: (cd ${WRKSRC}/../libipsec; make) post-install: + @${SED} 's@%PREFIX%@${LOCALBASE}@g' ${FILESDIR}/racoon.sh > ${PREFIX}/etc/rc.d/racoon.sh + @${CHMOD} +x ${PREFIX}/etc/rc.d/racoon.sh @if [ -z `/sbin/sysctl -a | ${GREP} -q ipsec && echo ipsec` ]; then \ ${ECHO_MSG} "WARNING: IPsec feature is disabled on this host"; \ ${ECHO_MSG} " You must build the kernel if you want to run racoon on the host"; \ diff --git a/security/racoon2/files/racoon.sh b/security/racoon2/files/racoon.sh new file mode 100644 index 000000000000..d6a5c1b3098a --- /dev/null +++ b/security/racoon2/files/racoon.sh @@ -0,0 +1,18 @@ +#!/bin/sh + +case "$1" in + start) + if [ -x %PREFIX%/sbin/racoon ]; then + %PREFIX%/sbin/racoon -f %PREFIX%/etc/racoon/racoon.conf && echo -n ' racoon' + fi + ;; + + stop) + /usr/bin/killall racoon && echo -n ' racoon' + ;; + + *) + echo "Usage: `basename $0` { start | stop }" + exit 64 + ;; +esac |