forked from extern/shorewall_code
More SHARED_DIR changes
git-svn-id: https://shorewall.svn.sourceforge.net/svnroot/shorewall/trunk@489 fbd18981-670d-0410-9b5c-8dc0c1a9a2bb
This commit is contained in:
parent
6a478754ac
commit
e2748d3245
@ -4311,6 +4311,10 @@ do_initialize() {
|
|||||||
startup_error "$FUNCTIONS does not exist!"
|
startup_error "$FUNCTIONS does not exist!"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
VERSION_FILE=$SHARED_DIR/version
|
||||||
|
|
||||||
|
[ -f $VERSION_FILE ] && version=`cat $VERSION_FILE`
|
||||||
|
|
||||||
run_user_exit params
|
run_user_exit params
|
||||||
|
|
||||||
config=`find_file shorewall.conf`
|
config=`find_file shorewall.conf`
|
||||||
@ -4323,10 +4327,6 @@ do_initialize() {
|
|||||||
exit 2
|
exit 2
|
||||||
fi
|
fi
|
||||||
|
|
||||||
VERSION_FILE=$SHARED_DIR/version
|
|
||||||
|
|
||||||
[ -f $VERSION_FILE ] && version=`cat $VERSION_FILE`
|
|
||||||
|
|
||||||
[ -z "${STATEDIR}" ] && STATEDIR=/var/state/shorewall
|
[ -z "${STATEDIR}" ] && STATEDIR=/var/state/shorewall
|
||||||
|
|
||||||
[ -d $STATEDIR ] || mkdir -p $STATEDIR
|
[ -d $STATEDIR ] || mkdir -p $STATEDIR
|
||||||
|
@ -571,24 +571,11 @@ fi
|
|||||||
[ -n "$SHOREWALL_DIR" ] && export SHOREWALL_DIR
|
[ -n "$SHOREWALL_DIR" ] && export SHOREWALL_DIR
|
||||||
|
|
||||||
PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/bin:/usr/local/sbin
|
PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/bin:/usr/local/sbin
|
||||||
SHARED_DIR=/usr/share/shorewall
|
|
||||||
MUTEX_TIMEOUT=
|
MUTEX_TIMEOUT=
|
||||||
|
|
||||||
if [ -n "$SHOREWALL_DIR" -a -f $SHOREWALL_DIR/shorewall.conf ]; then
|
|
||||||
config=$SHOREWALL_DIR/shorewall.conf
|
|
||||||
else
|
|
||||||
config=/etc/shorewall/shorewall.conf
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ -f $config ]; then
|
|
||||||
. $config
|
|
||||||
else
|
|
||||||
echo "$config does not exist!" >&2
|
|
||||||
exit 2
|
|
||||||
fi
|
|
||||||
|
|
||||||
[ -z "${STATEDIR}" ] && STATEDIR=/var/state/shorewall
|
[ -z "${STATEDIR}" ] && STATEDIR=/var/state/shorewall
|
||||||
|
|
||||||
|
SHARED_DIR=/usr/share/shorewall
|
||||||
FIREWALL=$SHARED_DIR/firewall
|
FIREWALL=$SHARED_DIR/firewall
|
||||||
FUNCTIONS=$SHARED_DIR/functions
|
FUNCTIONS=$SHARED_DIR/functions
|
||||||
VERSION_FILE=$SHARED_DIR/version
|
VERSION_FILE=$SHARED_DIR/version
|
||||||
@ -600,6 +587,15 @@ else
|
|||||||
exit 2
|
exit 2
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
config=`find_file shorewall.conf`
|
||||||
|
|
||||||
|
if [ -f $config ]; then
|
||||||
|
. $config
|
||||||
|
else
|
||||||
|
echo "$config does not exist!" >&2
|
||||||
|
exit 2
|
||||||
|
fi
|
||||||
|
|
||||||
if [ ! -f $FIREWALL ]; then
|
if [ ! -f $FIREWALL ]; then
|
||||||
echo "ERROR: Shorewall is not properly installed"
|
echo "ERROR: Shorewall is not properly installed"
|
||||||
if [ -L $FIREWALL ]; then
|
if [ -L $FIREWALL ]; then
|
||||||
|
Loading…
Reference in New Issue
Block a user