Skip to content

Commit 89d1d02

Browse files
author
Dean Troyer
committed
Cache UEC image earlier
1 parent ff0ed1d commit 89d1d02

1 file changed

Lines changed: 9 additions & 9 deletions

File tree

tools/build_libvirt.sh

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -167,6 +167,15 @@ git_clone $KEYSTONE_REPO $COPY_DIR/$DEST/keystone $KEYSTONE_BRANCH
167167
git_clone $NOVNC_REPO $COPY_DIR/$DEST/noVNC $NOVNC_BRANCH
168168
git_clone $CITEST_REPO $COPY_DIR/$DEST/openstack-integration-tests $CITEST_BRANCH
169169

170+
# Pre-load an image for testing
171+
UEC_NAME=$DIST_NAME-server-cloudimg-amd64
172+
CIVMDIR=${COPY_DIR}${DEST}/openstack-integration-tests/include/sample_vm
173+
if [ ! -e $CIVMDIR/$UEC_NAME.tar.gz ]; then
174+
mkdir -p $CIVMDIR
175+
(cd $CIVMDIR && wget -N http://uec-images.ubuntu.com/$DIST_NAME/current/$UEC_NAME.tar.gz;
176+
tar xzf $UEC_NAME.tar.gz;)
177+
fi
178+
170179
# Back to devstack
171180
cd $TOP_DIR
172181

@@ -410,15 +419,6 @@ umount $ROOTFS/dev
410419
chroot $ROOTFS dpkg-reconfigure openssh-server
411420
sed -e 's/^PasswordAuthentication.*$/PasswordAuthentication yes/' -i $ROOTFS/etc/ssh/sshd_config
412421

413-
# Pre-load an image for testing
414-
UEC_NAME=$DIST_NAME-server-cloudimg-amd64
415-
CIVMDIR=${ROOTFS}${DEST}/openstack-integration-tests/include/sample_vm
416-
if [ ! -e $CIVMDIR/$UEC_NAME.tar.gz ]; then
417-
mkdir -p $CIVMDIR
418-
(cd $CIVMDIR && wget -N http://uec-images.ubuntu.com/$DIST_NAME/current/$UEC_NAME.tar.gz;
419-
tar xzf $UEC_NAME.tar.gz;)
420-
fi
421-
422422
# Unmount
423423
umount $ROOTFS || echo 'ok'
424424
ROOTFS=""

0 commit comments

Comments
 (0)