Merge "Glance image delete output"

This commit is contained in:
Jenkins
2015-02-20 14:48:49 +00:00
committed by Gerrit Code Review
4 changed files with 51 additions and 0 deletions
+3
View File
@@ -332,6 +332,9 @@ def do_image_delete(gc, args):
"""Delete specified image(s)."""
for args_image in args.images:
image = utils.find_resource(gc.images, args_image)
if image and image.status == "deleted":
msg = "No image with an ID of '%s' exists." % image.id
raise exc.CommandError(msg)
try:
if args.verbose:
print('Requesting image delete for %s ...' %