diff options
Diffstat (limited to 'core')
-rw-r--r-- | core/modules/run-virt/data/opt/openslx/vmchooser/scripts/set-firewall | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/core/modules/run-virt/data/opt/openslx/vmchooser/scripts/set-firewall b/core/modules/run-virt/data/opt/openslx/vmchooser/scripts/set-firewall index 3dd19778..64c8eaa8 100644 --- a/core/modules/run-virt/data/opt/openslx/vmchooser/scripts/set-firewall +++ b/core/modules/run-virt/data/opt/openslx/vmchooser/scripts/set-firewall @@ -215,7 +215,11 @@ if ! ( # BLOCK if [ "$DEST" = "*" ]; then # Special case: '*' - default rule, so BLOCK -> no default servers - [ -z "$blockall" ] && blockall=1 + if [ -s "$DNSCFG" ]; then + [ -z "$blockall" ] && blockall=1 + else + both=1 + fi else # A host - map to 0.0.0.0 echo "address=/$DEST/" >> "$DNSCFG" @@ -224,7 +228,11 @@ if ! ( # ACCEPT if [ "$DEST" = "*" ]; then # Special case: '*' - degault rule, so ACCEPT -> default servers - [ -z "$blockall" ] && blockall=0 + if [ -s "$DNSCFG" ]; then + [ -z "$blockall" ] && blockall=0 + else + both=1 + fi else # specifically map to our DNS servers for dnsip in $dnslist; do |