1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-11-24 00:45:52 +00:00

- Add sample rc script

PR:		ports/66052
Submitted by:	Udo Schweigert <udo.schweigert@siemens.com> (maintainer)
This commit is contained in:
Pav Lucistnik 2004-05-02 18:09:24 +00:00
parent da2eac75c6
commit 5a5e873d18
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=108178
3 changed files with 37 additions and 1 deletions

View File

@ -27,6 +27,7 @@ WRKSRC= ${WRKDIR}/nessus-core
USE_LIBTOOL_VER=13
WANT_GNOME= yes
USE_REINPLACE= YES
.include <bsd.port.pre.mk>
@ -40,7 +41,13 @@ CONFIGURE_ARGS+=--disable-gtk
MAN1= nessus.1 nessus-mkrand.1 nessus-mkcert-client.1
MAN8= nessusd.8 nessus-adduser.8 nessus-mkcert.8 nessus-rmuser.8
post-extract:
@${CP} ${FILESDIR}/nessusd.sh ${WRKSRC}/nessusd.sh
@${REINPLACE_CMD} -E -e 's|%%PREFIX%%|${PREFIX}|g' ${BUILD_WRKSRC}/nessusd.sh
post-install:
${INSTALL_SCRIPT} ${BUILD_WRKSRC}/nessusd.sh \
${LOCALBASE}/etc/rc.d/nessusd.sh.sample
@${SETENV} ${SCRIPTS_ENV} ${SH} ${SCRIPTDIR}/move_nessus
.if ! exists(${PREFIX}/var/CA/serverkey.pem)
.if ! defined(BATCH)
@ -48,6 +55,6 @@ post-install:
.else
${PREFIX}/sbin/nessus-mkcert -q
.endif
.endif
.endif
.include <bsd.port.post.mk>

View File

@ -0,0 +1,28 @@
#! /bin/sh
#
# $FreeBSD$
#
umask 022
arg=${1:-start}
nessusd_bin=%%PREFIX%%/sbin/nessusd
nessus_arg="-D"
kill_arg=nessusd
echo -n " nessusd"
case $arg in
start)
test -x $nessusd_bin || exit 1
$nessusd_bin $nessus_arg
;;
stop)
killall $kill_arg > /dev/null 2>&1
;;
restart)
killall $kill_arg > /dev/null 2>&1
test -x $nessusd_bin || exit 1
$nessusd_bin $nessus_arg
;;
esac

View File

@ -1,3 +1,4 @@
etc/rc.d/nessusd.sh.sample
bin/nessus
bin/nessus-mkcert-client
bin/nessus-mkrand