1
0
mirror of https://github.com/OpenNebula/one.git synced 2025-03-21 14:50:08 +03:00

Feature #3175: Avoid errors if empty rules and apply an ACCEPT policy by default.

This commit is contained in:
Jaime Melis 2014-12-09 11:00:23 +01:00
parent 771a213b7f
commit 63ba5d4518

View File

@ -433,7 +433,7 @@ class SecurityGroup
rules.each do |rule|
@rules << Rule.new(rule)
end
end if rules
end
end
@ -554,7 +554,7 @@ class SecurityGroupIPTables < SecurityGroup
commands.iptables "-N #{GLOBAL_CHAIN}"
commands.iptables "-A FORWARD -m physdev --physdev-is-bridged -j #{GLOBAL_CHAIN}"
commands.iptables "-A #{GLOBAL_CHAIN} -j DROP"
commands.iptables "-A #{GLOBAL_CHAIN} -j ACCEPT"
commands.run!
end