add image caching to lxc
This commit is contained in:
parent
f2a343b00f
commit
70188b3105
1 changed files with 9 additions and 0 deletions
|
@ -152,6 +152,15 @@ if [ "$USE_CURRENT_DEVSTACK" = "1" ]; then
|
||||||
cp -pr $CWD $CACHEDIR/$DEST/devstack
|
cp -pr $CWD $CACHEDIR/$DEST/devstack
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# pre-cache uec images
|
||||||
|
for image_url in ${IMAGE_URLS//,/ }; do
|
||||||
|
IMAGE_FNAME=`basename "$image_url"`
|
||||||
|
if [ ! -f $CACHEDIR/$IMAGE_FNAME ]; then
|
||||||
|
wget -c $image_url -O $CACHEDIR/$IMAGE_FNAME
|
||||||
|
fi
|
||||||
|
cp $CACHEDIR/$IMAGE_FNAME $CACHEDIR/$DEST/devstack/files
|
||||||
|
done
|
||||||
|
|
||||||
# Destroy the old container
|
# Destroy the old container
|
||||||
lxc-destroy -n $GUEST_NAME
|
lxc-destroy -n $GUEST_NAME
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue