19f769f049
This reverts commit 7a4c396948
.
Note this time it sets it to F21, not F22, and gets rid of the
duplicate definition that doesn't get exported.
Change-Id: I240ad25d7a73c379559517a2a8399ae8c098314b
36 lines
1013 B
Bash
Executable File
36 lines
1013 B
Bash
Executable File
#!/bin/bash
|
|
|
|
if [ ${DIB_DEBUG_TRACE:-0} -gt 0 ]; then
|
|
set -x
|
|
fi
|
|
set -eu
|
|
set -o pipefail
|
|
|
|
[ -n "$ARCH" ]
|
|
[ -n "$TARGET_ROOT" ]
|
|
|
|
if [ 'amd64' = "$ARCH" ] ; then
|
|
ARCH="x86_64"
|
|
fi
|
|
|
|
DIB_LOCAL_IMAGE=${DIB_LOCAL_IMAGE:-""}
|
|
|
|
if [ -n "$DIB_LOCAL_IMAGE" ]; then
|
|
IMAGE_LOCATION=$DIB_LOCAL_IMAGE
|
|
# No need to copy a local image into the cache directory, so just specify
|
|
# the cached path as the original path.
|
|
CACHED_IMAGE=$IMAGE_LOCATION
|
|
BASE_IMAGE_FILE=`basename $DIB_LOCAL_IMAGE`
|
|
BASE_IMAGE_TAR=$BASE_IMAGE_FILE.tgz
|
|
else
|
|
# note default DIB_RELEASE set in environment setup
|
|
DIB_CLOUD_IMAGES=${DIB_CLOUD_IMAGES:-http://cloud.fedoraproject.org}
|
|
BASE_IMAGE_FILE=${BASE_IMAGE_FILE:-fedora-$DIB_RELEASE.$ARCH.qcow2}
|
|
BASE_IMAGE_TAR=$DIB_RELEASE-Cloud-$ARCH-$DIB_RELEASE.tgz
|
|
IMAGE_LOCATION=$DIB_CLOUD_IMAGES/$BASE_IMAGE_FILE
|
|
CACHED_IMAGE=$DIB_IMAGE_CACHE/$BASE_IMAGE_FILE
|
|
|
|
fi
|
|
|
|
$TMP_HOOKS_PATH/bin/extract-image $BASE_IMAGE_FILE $BASE_IMAGE_TAR $IMAGE_LOCATION $CACHED_IMAGE
|