X-Git-Url: https://gerrit.linuxfoundation.org/infra/gitweb?a=blobdiff_plain;f=shell%2Fjenkins-verify-images.sh;h=663dfb6e25825d3b6960ffe40dbccc6e546a2c3a;hb=refs%2Ftags%2Fv0.60.1;hp=d005c52f0873b1c16ed408af3b1daaacf3944b97;hpb=b34689ffcc1280b944b16191d2cfdb3640b8d298;p=releng%2Fglobal-jjb.git diff --git a/shell/jenkins-verify-images.sh b/shell/jenkins-verify-images.sh index d005c52f..663dfb6e 100755 --- a/shell/jenkins-verify-images.sh +++ b/shell/jenkins-verify-images.sh @@ -40,18 +40,20 @@ verify_images() } echo "Verifying that cloud has a master configuration file" -for cloud in jenkins-config/clouds/openstack/*; do - if [[ -f $cloud/cloud.cfg ]]; then - # Get the OS_CLOUD variable from cloud config - if ! os_cloud=$(grep -E "^OS_CLOUD=" "$cloud/cloud.cfg" | cut -d'=' -f2); then - os_cloud="vex" +if [[ -d jenkins-config/clouds/openstack ]]; then + for cloud in jenkins-config/clouds/openstack/*; do + if [[ -f $cloud/cloud.cfg ]]; then + # Get the OS_CLOUD variable from cloud config + if ! os_cloud=$(grep -E "^OS_CLOUD=" "$cloud/cloud.cfg" | cut -d'=' -f2); then + os_cloud="vex" + fi + OS_CLOUD=$os_cloud verify_images "$cloud" + else + echo "ERROR: No cloud.cfg for $cloud" + error=true fi - OS_CLOUD=$os_cloud verify_images "$cloud" - else - echo "ERROR: No cloud.cfg for $cloud" - error=true - fi -done + done +fi if $error; then exit 1