Skip to content

Commit 02049d9

Browse files
Merge pull request #1840 from edsonarios/issue1839
`slcli block access`, updated some descriptions, change flag -h to -d, sort flags
2 parents 0989178 + 6525409 commit 02049d9

File tree

6 files changed

+23
-23
lines changed

6 files changed

+23
-23
lines changed

SoftLayer/CLI/autoscale/detail.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
@click.argument('identifier')
1616
@environment.pass_env
1717
def cli(env, identifier):
18-
"""Get details of an Autoscale groups."""
18+
"""Get details of an Autoscale group."""
1919

2020
autoscale = AutoScaleManager(env.client)
2121
group = autoscale.details(identifier)

SoftLayer/CLI/autoscale/list.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
@click.command(cls=SLCommand)
1414
@environment.pass_env
1515
def cli(env):
16-
"""List AutoScale Groups."""
16+
"""List all Autoscale Groups on your account."""
1717

1818
autoscale = AutoScaleManager(env.client)
1919
groups = autoscale.list()

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 SoftLayer_Network_Subnet_IpAddress 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/password.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
@click.command(cls=SoftLayer.CLI.command.SLCommand, )
1010
@click.argument('access_id')
1111
@click.option('--password', '-p', multiple=False,
12-
help='Password you want to set, this command will fail if the password is not strong')
12+
help='Password you want to set, this command will fail if the password is not strong.')
1313
@environment.pass_env
1414
def cli(env, access_id, password):
1515
"""Changes a password for a volume's access.

SoftLayer/CLI/block/access/revoke.py

Lines changed: 7 additions & 10 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 SoftLayer_Hardware 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 SoftLayer_Network_Subnet_IpAddress to revoke authorization.')
2015
@click.option('--ip-address', multiple=True,
21-
help='An IP address to revoke authorization')
16+
help='An IP address to revoke authorization.')
17+
@click.option('--virtual-id', '-v', multiple=True,
18+
help='The ID of one SoftLayer_Virtual_Guest 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)