summaryrefslogtreecommitdiff
path: root/novaclient/v2/shell.py
diff options
context:
space:
mode:
Diffstat (limited to 'novaclient/v2/shell.py')
-rw-r--r--novaclient/v2/shell.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/novaclient/v2/shell.py b/novaclient/v2/shell.py
index 69028d09..d5361ddc 100644
--- a/novaclient/v2/shell.py
+++ b/novaclient/v2/shell.py
@@ -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.