Browse Source

Merge "Fail if referenced source image for a new volume does not exist"

master
Zuul 5 days ago
committed by Gerrit Code Review
parent
commit
4a1b092efb
1 changed files with 2 additions and 0 deletions
  1. +2
    -0
      plugins/modules/volume.py

+ 2
- 0
plugins/modules/volume.py View File

@ -188,6 +188,8 @@ class VolumeModule(OpenStackModule):
)
if self.params['image']:
image_id = self.conn.get_image_id(self.params['image'])
if not image_id:
self.fail_json(msg="Failed to find image '%s'" % self.params['image'])
volume_args['imageRef'] = image_id
if self.params['volume']:


Loading…
Cancel
Save