mirror of
https://gitlab.com/shorewall/code.git
synced 2024-11-14 11:44:01 +01:00
More operation fixes
git-svn-id: https://shorewall.svn.sourceforge.net/svnroot/shorewall/trunk@8962 fbd18981-670d-0410-9b5c-8dc0c1a9a2bb
This commit is contained in:
parent
ecb479b616
commit
7377eb1993
@ -120,16 +120,30 @@ sub generate_script_1() {
|
||||
|
||||
push_indent;
|
||||
|
||||
if ( $export ) {
|
||||
emit ( 'SHAREDIR=/usr/share/shorewall-lite',
|
||||
'CONFDIR=/etc/shorewall-lite',
|
||||
'PRODUCT="Shorewall Lite"'
|
||||
);
|
||||
if ( $family == F_IPV4 ) {
|
||||
if ( $export ) {
|
||||
emit ( 'SHAREDIR=/usr/share/shorewall-lite',
|
||||
'CONFDIR=/etc/shorewall-lite',
|
||||
'PRODUCT="Shorewall Lite"'
|
||||
);
|
||||
} else {
|
||||
emit ( 'SHAREDIR=/usr/share/shorewall',
|
||||
'CONFDIR=/etc/shorewall',
|
||||
'PRODUCT=\'Shorewall\'',
|
||||
);
|
||||
}
|
||||
} else {
|
||||
emit ( 'SHAREDIR=/usr/share/shorewall',
|
||||
'CONFDIR=/etc/shorewall',
|
||||
'PRODUCT=\'Shorewall\'',
|
||||
);
|
||||
if ( $export ) {
|
||||
emit ( 'SHAREDIR=/usr/share/shorewall6-lite',
|
||||
'CONFDIR=/etc/shorewall6-lite',
|
||||
'PRODUCT="Shorewall6 Lite"'
|
||||
);
|
||||
} else {
|
||||
emit ( 'SHAREDIR=/usr/share/shorewall6',
|
||||
'CONFDIR=/etc/shorewall6',
|
||||
'PRODUCT=\'Shorewall6\'',
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
emit( '[ -f ${CONFDIR}/vardir ] && . ${CONFDIR}/vardir' );
|
||||
|
@ -406,6 +406,9 @@ sub initialize( $ ) {
|
||||
BLACKLIST_DISPOSITION => undef,
|
||||
);
|
||||
} else {
|
||||
$globals{SHAREDIR} = '/usr/share/shorewall';
|
||||
$globals{CONFDIR} = '/etc/shorewall6';
|
||||
|
||||
%config =
|
||||
( STARTUP_ENABLED => undef,
|
||||
VERBOSITY => undef,
|
||||
@ -1811,7 +1814,7 @@ sub ensure_config_path() {
|
||||
|
||||
my $f = "$globals{SHAREDIR}/configpath";
|
||||
|
||||
$globals{CONFDIR} = "/usr/share/$product/configfiles/";
|
||||
$globals{CONFDIR} = "/usr/share/$product/configfiles/" if $> != 0;
|
||||
|
||||
unless ( $config{CONFIG_PATH} ) {
|
||||
fatal_error "$f does not exist" unless -f $f;
|
||||
|
Loading…
Reference in New Issue
Block a user