Rationalize init logs

Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
Tom Eastep 2010-04-10 11:46:50 -07:00
parent 76b9ef7005
commit 4365b83b15
6 changed files with 63 additions and 55 deletions

View File

@ -336,12 +336,14 @@ if [ -z "$PREFIX" ]; then
ln -s ${DEST}/${INIT} /usr/share/shorewall-lite/init
fi
if [ -z "$PREFIX" -a -n "$first_install" ]; then
if [ -z "$PREFIX" ]; then
touch /var/log/shorewall-lite-init.log
if [ -n "$first_install" ]; then
if [ -n "$DEBIAN" ]; then
run_install $OWNERSHIP -m 0644 default.debian /etc/default/shorewall-lite
ln -s ../init.d/shorewall-lite /etc/rcS.d/S40shorewall-lite
echo "Shorewall Lite will start automatically at boot"
touch /var/log/shorewall-init.log
else
if [ -x /sbin/insserv -o -x /usr/sbin/insserv ]; then
if insserv /etc/init.d/shorewall-lite ; then
@ -367,6 +369,7 @@ if [ -z "$PREFIX" -a -n "$first_install" ]; then
fi
fi
fi
fi
#
# Report Success

View File

@ -1,4 +1,4 @@
/var/log/shorewall-init.log {
/var/log/shorewall-lite-init.log {
missingok
notifempty
create 0600 root root

View File

@ -264,6 +264,7 @@ fi
run_install $OWNERSHIP -m 0644 configfiles/shorewall.conf ${PREFIX}/usr/share/shorewall/configfiles/shorewall.conf
perl -p -w -i -e 's|^CONFIG_PATH=.*|CONFIG_PATH=/usr/share/shorewall/configfiles:/usr/share/shorewall|;' ${PREFIX}/usr/share/shorewall/configfiles/shorewall.conf
perl -p -w -i -e 's|^STARTUP_LOG=.*|STARTUP_LOG=/var/log/shorewall-lite-init.log' ${PREFIX}/usr/share/shorewall/configfiles/shorewall.conf
if [ ! -f ${PREFIX}/etc/shorewall/shorewall.conf ]; then
run_install $OWNERSHIP -m 0644 configfiles/shorewall.conf ${PREFIX}/etc/shorewall/shorewall.conf

View File

@ -334,12 +334,14 @@ if [ -z "$PREFIX" ]; then
ln -s ${DEST}/${INIT} /usr/share/shorewall6-lite/init
fi
if [ -z "$PREFIX" -a -n "$first_install" ]; then
if [ -z "$PREFIX" ]; then
touch /var/log/shorewall6-lite-init.log
if [ -n "$first_install" ]; then
if [ -n "$DEBIAN" ]; then
run_install $OWNERSHIP -m 0644 default.debian /etc/default/shorewall6-lite
ln -s ../init.d/shorewall6-lite /etc/rcS.d/S40shorewall6-lite
echo "Shorewall6 Lite will start automatically at boot"
touch /var/log/shorewall-init.log
else
if [ -x /sbin/insserv -o -x /usr/sbin/insserv ]; then
if insserv /etc/init.d/shorewall6-lite ; then
@ -365,6 +367,7 @@ if [ -z "$PREFIX" -a -n "$first_install" ]; then
fi
fi
fi
fi
#
# Report Success

View File

@ -1,4 +1,4 @@
/var/log/shorewall6-init.log {
/var/log/shorewall6-lite-init.log {
missingok
notifempty
create 0600 root root

View File

@ -256,7 +256,8 @@ fi
#
run_install $OWNERSHIP -m 0644 shorewall6.conf ${PREFIX}/usr/share/shorewall6/configfiles/shorewall6.conf
qt mywhich perl && perl -p -w -i -e 's|^CONFIG_PATH=.*|CONFIG_PATH=/usr/share/shorewall6/configfiles:/usr/share/shorewall6|;' ${PREFIX}/usr/share/shorewall6/configfiles/shorewall6.conf
perl -p -w -i -e 's|^CONFIG_PATH=.*|CONFIG_PATH=/usr/share/shorewall6/configfiles:/usr/share/shorewall6|;' ${PREFIX}/usr/share/shorewall6/configfiles/shorewall6.conf
perl -p -w -i -e 's|^STARTUP_LOG=.*|STARTUP_LOG=/var/log/shorewall6-lite-init.log' ${PREFIX}/usr/share/shorewall/configfiles/shorewall.conf
if [ ! -f ${PREFIX}/etc/shorewall6/shorewall6.conf ]; then
run_install $OWNERSHIP -m 0644 shorewall6.conf ${PREFIX}/etc/shorewall6/shorewall6.conf