Add logging when initializing a default FW section
Change-Id: I1a40120b6118c28bb508e37f6060f25e0611c481
This commit is contained in:
parent
734270d9e9
commit
d1362ba0d9
|
@ -567,14 +567,17 @@ class NsxLibFirewallSection(utils.NsxLibApiBase):
|
|||
|
||||
def init_default(self, name, description, nested_groups,
|
||||
log_sg_blocked_traffic):
|
||||
LOG.info("Initializing the default section named %s", name)
|
||||
fw_sections = self.list()
|
||||
for section in reversed(fw_sections):
|
||||
if section['display_name'] == name:
|
||||
LOG.info("Found existing default section %s", section['id'])
|
||||
break
|
||||
else:
|
||||
tags = self.build_v3_api_version_tag()
|
||||
section = self.create_empty(
|
||||
name, description, nested_groups, tags)
|
||||
LOG.info("Creating a new default section %s", section['id'])
|
||||
|
||||
block_rule = self.get_rule_dict(
|
||||
'Block All', action=consts.FW_ACTION_DROP,
|
||||
|
|
Loading…
Reference in New Issue