Correct installation on systems with systemd

Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
Tom Eastep 2012-07-14 14:38:30 -07:00
parent 2cce81cfc1
commit 691a9bf793
3 changed files with 3 additions and 3 deletions

View File

@ -401,7 +401,7 @@ if [ -z "$DESTDIR" ]; then
echo "Shorewall Init will start automatically at boot" echo "Shorewall Init will start automatically at boot"
else else
if [ -n "$SYSTEMD" ]; then if [ -n "$SYSTEMD" ]; then
if systemctl enable shorewall-init; then if systemctl enable shorewall-init.service; then
echo "Shorewall Init will start automatically at boot" echo "Shorewall Init will start automatically at boot"
fi fi
elif [ -x ${SBINDIR}/insserv -o -x /usr${SBINDIR}/insserv ]; then elif [ -x ${SBINDIR}/insserv -o -x /usr${SBINDIR}/insserv ]; then

View File

@ -499,7 +499,7 @@ if [ -z "$DESTDIR" -a -n "$first_install" -a -z "${cygwin}${mac}" ]; then
perl -p -w -i -e 's/^STARTUP_ENABLED=No/STARTUP_ENABLED=Yes/;s/^IP_FORWARDING=On/IP_FORWARDING=Keep/;s/^SUBSYSLOCK=.*/SUBSYSLOCK=/;' ${CONFDIR}/${PRODUCT}/${PRODUCT}.conf perl -p -w -i -e 's/^STARTUP_ENABLED=No/STARTUP_ENABLED=Yes/;s/^IP_FORWARDING=On/IP_FORWARDING=Keep/;s/^SUBSYSLOCK=.*/SUBSYSLOCK=/;' ${CONFDIR}/${PRODUCT}/${PRODUCT}.conf
update-rc.d $PRODUCT enable defaults update-rc.d $PRODUCT enable defaults
elif [ -n "$SYSTEMD" ]; then elif [ -n "$SYSTEMD" ]; then
if systemctl enable $PRODUCT; then if systemctl enable ${PRODUCT}.service; then
echo "$Product will start automatically at boot" echo "$Product will start automatically at boot"
fi fi
elif mywhich insserv; then elif mywhich insserv; then

View File

@ -1131,7 +1131,7 @@ if [ -z "$DESTDIR" -a -n "$first_install" -a -z "${cygwin}${mac}" ]; then
perl -p -w -i -e 's/^STARTUP_ENABLED=No/STARTUP_ENABLED=Yes/;s/^IP_FORWARDING=On/IP_FORWARDING=Keep/;s/^SUBSYSLOCK=.*/SUBSYSLOCK=/;' ${CONFDIR}/$PRODUCT/$PRODUCT.conf perl -p -w -i -e 's/^STARTUP_ENABLED=No/STARTUP_ENABLED=Yes/;s/^IP_FORWARDING=On/IP_FORWARDING=Keep/;s/^SUBSYSLOCK=.*/SUBSYSLOCK=/;' ${CONFDIR}/$PRODUCT/$PRODUCT.conf
update-rc.d $PRODUCT enable update-rc.d $PRODUCT enable
elif [ -n "$SYSTEMD" ]; then elif [ -n "$SYSTEMD" ]; then
if systemctl enable $PRODUCT; then if systemctl enable ${PRODUCT}.service; then
echo "$Product will start automatically at boot" echo "$Product will start automatically at boot"
fi fi
elif mywhich insserv; then elif mywhich insserv; then