@@ -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'
@@ -49,6 +52,14 @@ def cli(env, identifier, no_vs, no_hardware):
4952 table .add_row (['tags' ,
5053 formatting .tags (subnet .get ('tagReferences' ))])
5154
55+ ip_address = subnet .get ('ipAddresses' )
56+
57+ ip_table = formatting .KeyValueTable (['id' , 'ip' , 'note' ])
58+ for address in ip_address :
59+ ip_table .add_row ([address .get ('id' ), address .get ('ipAddress' ), address .get ('note' )])
60+
61+ table .add_row (['ipAddresses' , ip_table ])
62+
5263 if not no_vs :
5364 if subnet ['virtualGuests' ]:
5465 vs_table = formatting .Table (['hostname' , 'domain' , 'public_ip' , 'private_ip' ])
0 commit comments