1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

kubevirt_pvc: improve failure handling (#57163)

This commit is contained in:
Mariusz Mazur 2019-05-30 11:14:28 +02:00 committed by ansibot
parent 4c00fc7b32
commit cac34ac568

View file

@ -391,6 +391,8 @@ class KubevirtPVC(KubernetesRawModule):
if import_status == desired_cdi_status: if import_status == desired_cdi_status:
return_obj = entity return_obj = entity
break break
elif import_status == 'Failed':
raise CreatePVCFailed("PVC creation incomplete; importing data failed")
else: else:
return_obj = entity return_obj = entity
break break