diff --git a/roles/ci_lvms_storage/tasks/main.yml b/roles/ci_lvms_storage/tasks/main.yml index 045a3f1b09..26bf1adaff 100644 --- a/roles/ci_lvms_storage/tasks/main.yml +++ b/roles/ci_lvms_storage/tasks/main.yml @@ -154,3 +154,12 @@ - _cifmw_lvms_storage_cluster_lvmscluster_out.resources[0].status is defined - _cifmw_lvms_storage_cluster_lvmscluster_out.resources[0].status.ready is defined - _cifmw_lvms_storage_cluster_lvmscluster_out.resources[0].status.ready | bool + - _cifmw_lvms_storage_cluster_lvmscluster_out.resources[0].status.deviceClassStatuses is defined + - >- + _cifmw_lvms_storage_cluster_lvmscluster_out.resources[0].status.deviceClassStatuses | + selectattr("name", "defined") | + selectattr("nodeStatus", "defined") | + selectattr("name", "equalto", cifmw_lvms_storage_class) | + map(attribute="nodeStatus") | flatten | + selectattr("status", "defined") | + map(attribute="status") | unique | first | default("") == "Ready"