Skip to content

Commit 71fdd8e

Browse files
author
earthmant
committed
another fix
1 parent d1acf3a commit 71fdd8e

1 file changed

Lines changed: 2 additions & 3 deletions

File tree

neutron_plugin/port.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,12 +34,12 @@
3434
set_neutron_runtime_properties,
3535
create_object_dict,
3636
COMMON_RUNTIME_PROPERTIES_KEYS,
37+
OPENSTACK_ID_PROPERTY,
3738
is_external_relationship_not_conditionally_created)
3839

3940
from neutron_plugin.network import NETWORK_OPENSTACK_TYPE
4041
from neutron_plugin.subnet import SUBNET_OPENSTACK_TYPE
4142
from neutron_plugin.security_group import SG_OPENSTACK_TYPE
42-
from neutron_plugin.floatingip import FLOATINGIP_OPENSTACK_TYPE
4343
from openstack_plugin_common.floatingip import get_server_floating_ip
4444

4545
PORT_OPENSTACK_TYPE = 'port'
@@ -119,8 +119,7 @@ def attach(nova_client, neutron_client, **kwargs):
119119
network_name = network['network']['name']
120120
server = nova_client.servers.get(server_id)
121121
floating_ip_id = \
122-
get_openstack_id_of_single_connected_node_by_openstack_type(
123-
ctx, FLOATINGIP_OPENSTACK_TYPE, if_exists=True)
122+
ctx.target.instance.runtime_properties[OPENSTACK_ID_PROPERTY]
124123
floating_ip = neutron_client.show_floatingip(floating_ip_id)
125124
floating_ip_address = floating_ip['floating_ip_address']
126125
server_addresses = \

0 commit comments

Comments
 (0)