From 6065772feca1862844efd6388b4782354154a6fc Mon Sep 17 00:00:00 2001 From: Jesse Andrews Date: Tue, 25 Oct 2011 23:41:59 -0700 Subject: [PATCH] cache the images --- tools/build_kvm.sh | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/tools/build_kvm.sh b/tools/build_kvm.sh index 32c7bf6..d804f42 100755 --- a/tools/build_kvm.sh +++ b/tools/build_kvm.sh @@ -284,6 +284,15 @@ if [ "$COPYENV" = "1" ]; then cp_it ~/.bashrc $ROOTFS/$DEST/.bashrc fi +# pre-cache uec images +for image_url in ${IMAGE_URLS//,/ }; do + IMAGE_FNAME=`basename "$image_url"` + if [ ! -f $IMAGES_DIR/$IMAGE_FNAME ]; then + wget -c $image_url -O $IMAGES_DIR/$IMAGE_FNAME + fi + cp $IMAGES_DIR/$IMAGE_FNAME $ROOTFS/$DEST/devstack/files/images +fi + # Configure the runner RUN_SH=$ROOTFS/$DEST/run.sh cat > $RUN_SH <