Add raw image support for lxd scenario 39/19839/8
authorJingLu5 <lvjing5@huawei.com>
Fri, 2 Sep 2016 00:28:00 +0000 (08:28 +0800)
committerJingLu5 <lvjing5@huawei.com>
Fri, 2 Sep 2016 00:28:00 +0000 (08:28 +0800)
JIRA: YARDSTICK-325

Provide a raw format yardstick-trusty-server image when runing os-nosdn-lxd-ha
or os-nosdn-lxd-noha scenarios

Change-Id: I7bd1dcfe187f529134f6b30d4dd4c887f5639048
Signed-off-by: JingLu5 <lvjing5@huawei.com>
tests/ci/yardstick-verify

index 5ac0850..8670bf4 100755 (executable)
@@ -269,9 +269,16 @@ load_yardstick_image()
         rm -f $VIVID_KERNEL $VIVID_IMAGE
         cd $YARDSTICK_REPO_DIR
     fi
+
+    if [ "$DEPLOY_SCENARIO" == "os-nosdn-lxd-ha" -o "$DEPLOY_SCENARIO" == "os-nosdn-lxd-noha" ]; then
+        DISK_FORMAT="raw"
+    else
+        DISK_FORMAT="qcow2"
+    fi
+
     output=$(eval glance --os-image-api-version 1 image-create \
         --name yardstick-trusty-server \
-        --is-public true --disk-format qcow2 \
+        --is-public true --disk-format $DISK_FORMAT \
         --container-format bare \
         $EXTRA_PARAMS \
         --file $QCOW_IMAGE)