Skip to content

Commit

Permalink
Merge pull request #949 from freyes/bug/1964117/yoga
Browse files Browse the repository at this point in the history
 Drop bug_1964117_workaround()
  • Loading branch information
coreycb authored Oct 26, 2022
2 parents c6b49aa + ddbee4d commit b9f6774
Showing 1 changed file with 0 additions and 38 deletions.
38 changes: 0 additions & 38 deletions zaza/openstack/charm_tests/octavia/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -142,9 +142,6 @@ def configure_octavia():
'octavia',
'configure-resources',
action_params={})
# When bug #1964117 is fix released for all affected releases this call can
# be removed.
bug_1964117_workaround()


def disable_ohm_port_security():
Expand All @@ -166,41 +163,6 @@ def disable_ohm_port_security():
'security_groups': []}})


def bug_1964117_workaround():
"""Apply Bug #1964117 if allowed."""
if openstack.ovn_present():
# Issue only known to affect ml2 ovs so if do not apply work around
# to ovn deploys.
return
allow_pkg_list = ['2.16.0-0ubuntu2.1~cloud0']
allow_release_list = ['focal_xena']
_allow_release_list = [
openstack.get_os_release(r)
for r in allow_release_list
]
current_release = openstack.get_os_release()
if current_release in _allow_release_list:
cmd_out = zaza.model.run_on_leader(
'octavia',
"""dpkg -l | awk '/openvswitch-switch/ {print $3;}'""")
pkg_version = cmd_out['Stdout'].strip()
if pkg_version in allow_pkg_list:
logging.info('Disabling port security to work around bug #1964117')
disable_ohm_port_security()
else:
msg = (
"Detected Xena deploy and package version {} is not in the "
"allow list {}. If you believe that bug #1964117 has been "
"resolved please remove the call to this function. If the "
"new package does not resolve bug #1964117 then please add "
"the new package version to the 'allow_pkg_list' defined at "
"the start of this function. If changes are required please "
"raise a PR againt "
"https://github.com/openstack-charmers/zaza-openstack-tests"
"".format(pkg_version, allow_pkg_list))
raise Exception(msg)


def centralized_fip_network():
"""Create network with centralized router for connecting lb and fips.
Expand Down

0 comments on commit b9f6774

Please sign in to comment.