diff --git a/ovn-tester/cms/openstack/openstack.py b/ovn-tester/cms/openstack/openstack.py index 84a8bb5e..9fe2c821 100644 --- a/ovn-tester/cms/openstack/openstack.py +++ b/ovn-tester/cms/openstack/openstack.py @@ -246,12 +246,8 @@ def connect_external_network_to_project( self.external_port = lr_port gw_net = DualStackSubnet(netaddr.IPNetwork("0.0.0.0/0")) - # XXX: ovsdbapp does not allow setting external IDs to static route - # XXX: Setting 'policy' to "" throws "constraint violation" error in - # logs because ovsdbapp does not allow not specifying policy. - # However, the route itself is created successfully with no - # policy, the same way Neutron does it. - self.nbctl.route_add(project.router, gw_net, lr_port.ip, "") + # NOTE(mkalcok): Neutron actually sets policy to '""' + self.nbctl.route_add(project.router, gw_net, lr_port.ip, '""') gw_nodes = self._get_gateway_chassis(external_network.num_gw_nodes) for index, chassis in enumerate(gw_nodes): @@ -616,9 +612,9 @@ def _add_router_port( if is_gw: lsp_options = ( - "exclude-lb-vips-from-garp=true, " - "nat-addresses=router, " - f"router-port={router_port_name}" + "exclude-lb-vips-from-garp=true " + "nat-addresses=router " + f"router-port={router_port_name} " ) self.nbctl.ls_port_set_set_options(ls_port, lsp_options) @@ -639,8 +635,8 @@ def _create_default_security_group(self) -> PortGroup: f"inport == @{pg_name} && ip6", ] out_rules = [ - f"outport == @{pg_name} && ip4 && ip4.src == $pg_{pg_name}_ip4", - f"outport == @{pg_name} && ip6 && ip6.src == $pg_{pg_name}_ip6", + f"outport == @{pg_name} && ip4 && ip4.src == ${pg_name}_ip4", + f"outport == @{pg_name} && ip6 && ip6.src == ${pg_name}_ip6", ] for rule in in_rules: