|
1 |
| -"""Display details for a specified cloud object storage.""" |
| 1 | +"""Display permission details for a cloud object storage.""" |
2 | 2 | # :license: MIT, see LICENSE for more details.
|
3 | 3 |
|
4 | 4 | import click
|
|
11 | 11 | @click.argument('object_id')
|
12 | 12 | @environment.pass_env
|
13 | 13 | def cli(env, object_id):
|
14 |
| - """Display details for a cloud object storage.""" |
| 14 | + """Display permission details for a cloud object storage.""" |
15 | 15 |
|
16 | 16 | block_manager = SoftLayer.BlockStorageManager(env.client)
|
17 | 17 |
|
18 | 18 | cloud = block_manager.get_network_message_delivery_accounts(object_id)
|
19 | 19 | end_points = block_manager.get_end_points(object_id)
|
20 | 20 |
|
21 |
| - table = formatting.Table(['name', 'value']) |
| 21 | + table = formatting.Table(['Name', 'Value']) |
22 | 22 |
|
23 |
| - table_credentials = formatting.Table(['Id', 'Username', 'Password', 'Description']) |
| 23 | + table_credentials = formatting.Table(['Id', 'Access Key ID', 'Secret Access Key', 'Description']) |
24 | 24 |
|
25 | 25 | for credential in cloud.get('credentials'):
|
26 | 26 | table_credentials.add_row([credential.get('id'),
|
27 | 27 | credential.get('username'),
|
28 | 28 | credential.get('password'),
|
29 | 29 | credential['type']['description']])
|
30 | 30 |
|
31 |
| - table_url = formatting.Table(['region', |
32 |
| - 'location', |
33 |
| - 'type', |
34 |
| - 'url']) |
| 31 | + table_url = formatting.Table(['Region', |
| 32 | + 'Location', |
| 33 | + 'Type', |
| 34 | + 'URL']) |
35 | 35 | for end_point in end_points:
|
36 | 36 | table_url.add_row([end_point.get('region') or '',
|
37 | 37 | end_point.get('location') or '',
|
38 | 38 | end_point.get('type'),
|
39 | 39 | end_point.get('url'), ])
|
40 | 40 |
|
41 | 41 | table.add_row(['UUID', cloud.get('uuid')])
|
42 |
| - table.add_row(['Credemtial', table_credentials]) |
43 |
| - table.add_row(['EndPoint URL', table_url]) |
| 42 | + table.add_row(['Credentials', table_credentials]) |
| 43 | + table.add_row(['EndPoint URL´s', table_url]) |
44 | 44 | env.fout(table)
|
0 commit comments