mirror of
https://git.freebsd.org/ports.git
synced 2025-04-28 09:36:41 -04:00
sysutils/bastille: update to 0.10.20231125
While here do not override upstream rc script PR: 274993 Reported by: dsh@bamus.cz Approved by: christer.edwards@gmail.com (maintainer)
This commit is contained in:
parent
923942600f
commit
08ed7d0165
4 changed files with 20 additions and 71 deletions
|
@ -1,5 +1,5 @@
|
|||
PORTNAME= bastille
|
||||
DISTVERSION= 0.10.20231013
|
||||
DISTVERSION= 0.10.20231125
|
||||
CATEGORIES= sysutils
|
||||
|
||||
MAINTAINER= christer.edwards@gmail.com
|
||||
|
@ -15,17 +15,25 @@ GH_ACCOUNT= bastillebsd
|
|||
NO_BUILD= yes
|
||||
NO_ARCH= yes
|
||||
|
||||
USE_RC_SUBR= bastille
|
||||
post-patch:
|
||||
@${REINPLACE_CMD} \
|
||||
-e 's|/usr/local/etc/bastille|${ETCDIR}|g' \
|
||||
-e 's|/usr/local|${PREFIX}|g' \
|
||||
${WRKSRC}/usr/local/etc/rc.d/bastille
|
||||
|
||||
do-install:
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/${PREFIX}/bin/bastille ${STAGEDIR}${PREFIX}/bin
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/usr/local/bin/bastille ${STAGEDIR}${PREFIX}/bin
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/usr/local/etc/rc.d/bastille \
|
||||
${STAGEDIR}${PREFIX}/etc/rc.d
|
||||
|
||||
post-install:
|
||||
${MKDIR} ${STAGEDIR}${ETCDIR}
|
||||
${MKDIR} ${STAGEDIR}${DATADIR}
|
||||
(cd ${WRKSRC}/${DATADIR} && ${COPYTREE_SHARE} . ${STAGEDIR}${DATADIR})
|
||||
${INSTALL_MAN} ${WRKSRC}/${PREFIX}/man/man8/bastille.8.gz \
|
||||
${STAGEDIR}${PREFIX}/man/man8/bastille.8.gz
|
||||
${INSTALL_DATA} ${WRKSRC}/${ETCDIR}/bastille.conf.sample ${STAGEDIR}${ETCDIR}/bastille.conf.sample
|
||||
(cd ${WRKSRC}/usr/local/share/bastille && \
|
||||
${COPYTREE_SHARE} . ${STAGEDIR}${DATADIR})
|
||||
${INSTALL_MAN} ${WRKSRC}/usr/local/man/man8/bastille.8.gz \
|
||||
${STAGEDIR}${PREFIX}/man/man8/${PORTNAME}.8.gz
|
||||
${INSTALL_DATA} ${WRKSRC}/usr/local/etc/bastille/bastille.conf.sample \
|
||||
${STAGEDIR}${ETCDIR}/${PORTNAME}.conf.sample
|
||||
|
||||
.include <bsd.port.mk>
|
||||
|
|
|
@ -1,3 +1,3 @@
|
|||
TIMESTAMP = 1697592468
|
||||
SHA256 (bastillebsd-bastille-0.10.20231013_GH0.tar.gz) = 46b431dccbf36363b9f396f5ea32fb6899c8b210973c6683acef401cd25414df
|
||||
SIZE (bastillebsd-bastille-0.10.20231013_GH0.tar.gz) = 622679
|
||||
TIMESTAMP = 1701531665
|
||||
SHA256 (bastillebsd-bastille-0.10.20231125_GH0.tar.gz) = 10ff52d33278d15af573173a3985381edb020add99c44d14942c3288f65c36e8
|
||||
SIZE (bastillebsd-bastille-0.10.20231125_GH0.tar.gz) = 625906
|
||||
|
|
|
@ -1,61 +0,0 @@
|
|||
#!/bin/sh
|
||||
|
||||
# Bastille jail startup script
|
||||
|
||||
# PROVIDE: bastille
|
||||
# REQUIRE: LOGIN
|
||||
# KEYWORD: shutdown
|
||||
|
||||
# Add the following to /etc/rc.conf[.local] to enable this service
|
||||
#
|
||||
# bastille_enable (bool): Set to NO by default.
|
||||
# Set it to YES to enable bastille.
|
||||
# bastille_list (string): Set to "ALL" by default.
|
||||
# Space separated list of jails to start.
|
||||
#
|
||||
|
||||
. /etc/rc.subr
|
||||
|
||||
name=bastille
|
||||
rcvar=${name}_enable
|
||||
|
||||
: ${bastille_enable:=NO}
|
||||
: ${bastille_list:="ALL"}
|
||||
|
||||
command=%%PREFIX%%/bin/${name}
|
||||
start_cmd="bastille_start"
|
||||
stop_cmd="bastille_stop"
|
||||
restart_cmd="bastille_stop && bastille_start"
|
||||
|
||||
bastille_start()
|
||||
{
|
||||
if [ ! -n "${bastille_list}" ]; then
|
||||
echo "${bastille_list} is undefined"
|
||||
return 1
|
||||
fi
|
||||
|
||||
local _jail
|
||||
|
||||
for _jail in ${bastille_list}; do
|
||||
echo "Starting Bastille Jail: ${_jail}"
|
||||
${command} start ${_jail}
|
||||
done
|
||||
}
|
||||
|
||||
bastille_stop()
|
||||
{
|
||||
if [ ! -n "${bastille_list}" ]; then
|
||||
echo "${bastille_list} is undefined"
|
||||
return 1
|
||||
fi
|
||||
|
||||
local _jail
|
||||
|
||||
for _jail in ${bastille_list}; do
|
||||
echo "Stopping Bastille Jail: ${_jail}"
|
||||
${command} stop ${_jail}
|
||||
done
|
||||
}
|
||||
|
||||
load_rc_config ${name}
|
||||
run_rc_command "$1"
|
|
@ -1,5 +1,6 @@
|
|||
@sample %%ETCDIR%%/bastille.conf.sample
|
||||
bin/bastille
|
||||
etc/rc.d/bastille
|
||||
%%DATADIR%%/bootstrap.sh
|
||||
%%DATADIR%%/clone.sh
|
||||
%%DATADIR%%/cmd.sh
|
||||
|
@ -19,6 +20,7 @@ bin/bastille
|
|||
%%DATADIR%%/list.sh
|
||||
%%DATADIR%%/mount.sh
|
||||
%%DATADIR%%/pkg.sh
|
||||
%%DATADIR%%/rcp.sh
|
||||
%%DATADIR%%/rdr.sh
|
||||
%%DATADIR%%/rename.sh
|
||||
%%DATADIR%%/restart.sh
|
||||
|
|
Loading…
Add table
Reference in a new issue