From cc4b23aafa7e210aa3bb697649f16bdee1be6510 Mon Sep 17 00:00:00 2001 From: Clint Byrum Date: Wed, 27 Feb 2013 20:23:13 -0800 Subject: [PATCH] Namespace SHA256SUMS file to distro/release/arch Its possible other images will want to use the same filename Change-Id: Iae393bfc71205d39e2bc6e12f5524824607d6101 --- elements/ubuntu/root.d/10-cache-ubuntu-tarball | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/elements/ubuntu/root.d/10-cache-ubuntu-tarball b/elements/ubuntu/root.d/10-cache-ubuntu-tarball index 7b3ff166..afd110bd 100755 --- a/elements/ubuntu/root.d/10-cache-ubuntu-tarball +++ b/elements/ubuntu/root.d/10-cache-ubuntu-tarball @@ -16,10 +16,10 @@ mkdir -p $IMG_PATH # TODO: don't cache -current forever. if [ ! -f $IMG_PATH/$BASE_IMAGE_FILE ] ; then echo "Fetching Base Image" + wget $SHA256SUMS -O $IMG_PATH/SHA256SUMS.ubuntu.$RELEASE.$ARCH wget $CLOUD_IMAGES/$RELEASE/current/$BASE_IMAGE_FILE -O $IMG_PATH/$BASE_IMAGE_FILE.tmp - wget $SHA256SUMS -O $IMG_PATH/SHA256SUMS pushd $IMG_PATH - awk "/$BASE_IMAGE_FILE/ { print \$0 \".tmp\" }" SHA256SUMS | sha256sum --check - + awk "/$BASE_IMAGE_FILE/ { print \$0 \".tmp\" }" SHA256SUMS.ubuntu.$RELEASE.$ARCH | sha256sum --check - popd mv $IMG_PATH/$BASE_IMAGE_FILE.tmp $IMG_PATH/$BASE_IMAGE_FILE fi