Skip to content

Commit 917a642

Browse files
committed
Updated some descriptions, change flag -h to -d, sort flags
1 parent 09125be commit 917a642

File tree

3 files changed

+19
-19
lines changed

3 files changed

+19
-19
lines changed

SoftLayer/CLI/block/access/authorize.py

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -11,17 +11,17 @@
1111

1212
@click.command(cls=SoftLayer.CLI.command.SLCommand, )
1313
@click.argument('volume_id')
14-
@click.option('--hardware-id', '-h', multiple=True,
15-
help='The id of one SoftLayer_Hardware to authorize ' + MULTIPLE)
16-
@click.option('--virtual-id', '-v', multiple=True,
17-
help='The id of one SoftLayer_Virtual_Guest to authorize ' + MULTIPLE)
14+
@click.option('--hardware-id', '-d', multiple=True,
15+
help='The ID of one hardware server to authorize. ' + MULTIPLE)
1816
@click.option('--ip-address-id', '-i', multiple=True,
19-
help='The id of one SoftLayer_Network_Subnet_IpAddress to authorize ' + MULTIPLE)
17+
help='The ID of one IP address to authorize. ' + MULTIPLE)
2018
@click.option('--ip-address', multiple=True,
21-
help='An IP address to authorize ' + MULTIPLE)
19+
help='An IP address to authorize. ' + MULTIPLE)
20+
@click.option('--virtual-id', '-v', multiple=True,
21+
help='The ID of one virtual server to authorize. ' + MULTIPLE)
2222
@environment.pass_env
2323
def cli(env, volume_id, hardware_id, virtual_id, ip_address_id, ip_address):
24-
"""Authorizes hosts to access a given volume"""
24+
"""Authorize hosts to access a given volume."""
2525
block_manager = SoftLayer.BlockStorageManager(env.client)
2626
ip_address_id_list = list(ip_address_id)
2727

SoftLayer/CLI/block/access/list.py

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,15 +12,18 @@
1212

1313
@click.command(cls=SoftLayer.CLI.command.SLCommand, )
1414
@click.argument('volume_id')
15-
@click.option('--sortby', help='Column to sort by', default='name')
1615
@click.option('--columns',
1716
callback=column_helper.get_formatter(storage_utils.COLUMNS),
18-
help='Columns to display. Options: {0}'.format(
17+
help='Columns to display. Options are: {0}.'.format(
1918
', '.join(column.name for column in storage_utils.COLUMNS)),
2019
default=','.join(storage_utils.DEFAULT_COLUMNS))
20+
@click.option('--sortby',
21+
help='Column to sort by. Options are: {0}.'.format(
22+
', '.join(column.name for column in storage_utils.COLUMNS)),
23+
default='name')
2124
@environment.pass_env
2225
def cli(env, columns, sortby, volume_id):
23-
"""List ACLs."""
26+
"""List hosts that are authorized to access the volume."""
2427
block_manager = SoftLayer.BlockStorageManager(env.client)
2528
resolved_id = helpers.resolve_id(block_manager.resolve_ids, volume_id, 'Volume Id')
2629
access_list = block_manager.get_block_volume_access_list(

SoftLayer/CLI/block/access/revoke.py

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -8,20 +8,17 @@
88

99
@click.command(cls=SoftLayer.CLI.command.SLCommand, )
1010
@click.argument('volume_id')
11-
@click.option('--hardware-id', '-h', multiple=True,
12-
help='The id of one SoftLayer_Hardware'
13-
' to revoke authorization')
14-
@click.option('--virtual-id', '-v', multiple=True,
15-
help='The id of one SoftLayer_Virtual_Guest'
16-
' to revoke authorization')
11+
@click.option('--hardware-id', '-d', multiple=True,
12+
help='The ID of one IP address to revoke authorization')
1713
@click.option('--ip-address-id', '-i', multiple=True,
18-
help='The id of one SoftLayer_Network_Subnet_IpAddress'
19-
' to revoke authorization')
14+
help='The ID of one IP address to revoke authorization')
2015
@click.option('--ip-address', multiple=True,
2116
help='An IP address to revoke authorization')
17+
@click.option('--virtual-id', '-v', multiple=True,
18+
help='The ID of one virtual server to revoke authorization')
2219
@environment.pass_env
2320
def cli(env, volume_id, hardware_id, virtual_id, ip_address_id, ip_address):
24-
"""Revokes authorization for hosts accessing a given volume"""
21+
"""Revoke authorization for hosts that are accessing a specific volume."""
2522
block_manager = SoftLayer.BlockStorageManager(env.client)
2623
ip_address_id_list = list(ip_address_id)
2724

0 commit comments

Comments
 (0)