Merge "Check flavor option before image checks"
This commit is contained in:
commit
e88df234da
@ -154,6 +154,9 @@ def _parse_block_device_mapping_v2(args, image):
|
||||
|
||||
def _boot(cs, args):
|
||||
"""Boot a new server."""
|
||||
if not args.flavor:
|
||||
raise exceptions.CommandError(_("you need to specify a Flavor ID."))
|
||||
|
||||
if args.image:
|
||||
image = _find_image(cs, args.image)
|
||||
else:
|
||||
@ -166,9 +169,6 @@ def _boot(cs, args):
|
||||
# are selecting the first of many?
|
||||
image = images[0]
|
||||
|
||||
if not args.flavor:
|
||||
raise exceptions.CommandError(_("you need to specify a Flavor ID "))
|
||||
|
||||
min_count = 1
|
||||
max_count = 1
|
||||
# Don't let user mix num_instances and max_count/min_count.
|
||||
|
Loading…
x
Reference in New Issue
Block a user