Merge "Ensure klb handler reacretes lb"

This commit is contained in:
Zuul 2020-09-30 05:53:53 +00:00 committed by Gerrit Code Review
commit a8d4776b6b
1 changed files with 4 additions and 1 deletions

View File

@ -376,7 +376,10 @@ class LBaaSv2Driver(base.LBaaSDriver):
# when enforcing sg rules on the lb sg, meaning octavia
# Amphora provider is configured.
if CONF.octavia_defaults.enforce_sg_rules:
sg_id = self._get_vip_port(loadbalancer).security_group_ids[0]
try:
sg_id = self._get_vip_port(loadbalancer).security_group_ids[0]
except AttributeError:
sg_id = None
if sg_id:
rules = os_net.security_group_rules(security_group_id=sg_id,
description=listener[