@@ -25,7 +25,10 @@ def cli(env, identifier, no_vs, no_hardware):
2525 mgr = SoftLayer .NetworkManager (env .client )
2626 subnet_id = helpers .resolve_id (mgr .resolve_subnet_ids , identifier ,
2727 name = 'subnet' )
28- subnet = mgr .get_subnet (subnet_id )
28+
29+ mask = 'mask[ipAddresses[id, ipAddress,note], datacenter, virtualGuests, hardware]'
30+
31+ subnet = mgr .get_subnet (subnet_id , mask = mask )
2932
3033 table = formatting .KeyValueTable (['name' , 'value' ])
3134 table .align ['name' ] = 'r'
@@ -45,6 +48,14 @@ def cli(env, identifier, no_vs, no_hardware):
4548 table .add_row (['usable ips' ,
4649 subnet .get ('usableIpAddressCount' , formatting .blank ())])
4750
51+ ip_address = subnet .get ('ipAddresses' )
52+
53+ ip_table = formatting .KeyValueTable (['id' , 'ip' , 'note' ])
54+ for address in ip_address :
55+ ip_table .add_row ([address .get ('id' ), address .get ('ipAddress' ), address .get ('note' )])
56+
57+ table .add_row (['ipAddresses' , ip_table ])
58+
4859 if not no_vs :
4960 if subnet ['virtualGuests' ]:
5061 vs_table = formatting .Table (['hostname' , 'domain' , 'public_ip' , 'private_ip' ])
0 commit comments