From 687c2bdb601633419f12f3a7382fa631d5d2233d Mon Sep 17 00:00:00 2001 From: Holger Levsen Date: Sun, 2 Dec 2012 03:15:55 +0100 Subject: fixup: implement basics for cd tests --- bin/cd_tester.sh | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'bin/cd_tester.sh') diff --git a/bin/cd_tester.sh b/bin/cd_tester.sh index 89c89ddc..4860683a 100755 --- a/bin/cd_tester.sh +++ b/bin/cd_tester.sh @@ -45,7 +45,7 @@ cleanup_all() { # cleanup # umount $IMAGE_MNT - sudo rm $IMAGE $NAME.qcow + sudo rm $NAME.qcow # # create video # @@ -90,8 +90,12 @@ monitor_installation() { trap cleanup_all INT TERM EXIT -wget $IMAGE_URL -mkdir -p $IMAGE_MNT +# only wget if $IMAGE is older than a week (60*24*7=10080) +if test $(find $IMAGE -mmin +10080) ; then + rm $IMAGE + wget $IMAGE_URL +fi +sudo mkdir -p $IMAGE_MNT mount -o loop $IMAGE $IMAGE_MNT bootstrap monitor_installation -- cgit v1.2.3-70-g09d2