Skip to content

Commit 8f8a844

Browse files
author
Reedip
committed
Add necessary info to Floating IP list
This patch adds the Network ID and Project ID for the listed floating IPs when Neutron is enabled for OpenstackClient. Change-Id: I823090f2e6d30acd72247d30956f48f4d7672a50 Closes-Bug:#1566090
1 parent bfeecd5 commit 8f8a844

3 files changed

Lines changed: 15 additions & 0 deletions

File tree

openstackclient/network/v2/floating_ip.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -203,12 +203,16 @@ def take_action_network(self, client, parsed_args):
203203
'floating_ip_address',
204204
'fixed_ip_address',
205205
'port_id',
206+
'floating_network_id',
207+
'project_id',
206208
)
207209
headers = (
208210
'ID',
209211
'Floating IP Address',
210212
'Fixed IP Address',
211213
'Port',
214+
'Floating Network',
215+
'Project',
212216
)
213217

214218
query = {}

openstackclient/tests/unit/network/v2/test_floating_ip.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -237,6 +237,8 @@ class TestListFloatingIPNetwork(TestFloatingIPNetwork):
237237
'Floating IP Address',
238238
'Fixed IP Address',
239239
'Port',
240+
'Floating Network',
241+
'Project',
240242
)
241243

242244
data = []
@@ -246,6 +248,8 @@ class TestListFloatingIPNetwork(TestFloatingIPNetwork):
246248
ip.floating_ip_address,
247249
ip.fixed_ip_address,
248250
ip.port_id,
251+
ip.floating_network_id,
252+
ip.tenant_id,
249253
))
250254

251255
def setUp(self):
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
---
2+
features:
3+
- |
4+
``openstack floating ip`` now provides ``Floating Network`` and
5+
``Project`` to identify to which network and project the
6+
floating-ip belongs to.
7+
[Bug `1566090 <https://bugs.launchpad.net/bugs/1566090>`_]

0 commit comments

Comments
 (0)