Commit bcb18722 authored by Nikos Skalkotos's avatar Nikos Skalkotos
Browse files

Merge branch 'master' into debian

parents 74264132 fb391215
2012-02-29, v0.3.3
* Check if the images partition table is valid
2012-02-06, v0.3.2
2012-01-26, v0.3.1
......
......@@ -94,6 +94,13 @@ get_distro() {
fi
}
check_partition_table() {
local dev="$1"
if ! "$PARTED" -s "$dev" print; then
log_error "Unable to read partition table for device \`${dev}'"
fi
}
get_last_partition() {
local dev="$1"
......@@ -167,5 +174,5 @@ check_if_excluded() {
}
trap cleanup EXIT
set -o pipefail
# vim: set sta sts=4 shiftwidth=4 sw=4 et ai :
AC_PREREQ(2.59)
AC_INIT(snf-image-helper, 0.3.2, synnefo@lists.grnet.gr)
AC_INIT(snf-image-helper, 0.3.3, synnefo@lists.grnet.gr)
AC_CONFIG_AUX_DIR(autotools)
AC_CONFIG_SRCDIR(configure)
......
......@@ -20,7 +20,6 @@
. @commondir@/common.sh
set -e
set -o pipefail
if [ "x$1" != "x--force" ]; then
echo "WARNING: Exiting, this command would cause the system to halt." >&2
......
......@@ -33,6 +33,8 @@ if [ ! -b "$SNF_IMAGE_DEV" ]; then
log_error "Device file:\`${SNF_IMAGE_DEV}' is not a block device"
fi
check_partition_table "$SNF_IMAGE_DEV"
if [ $(get_partition_count "$SNF_IMAGE_DEV") -eq 0 ]; then
log_error "Device: \`${SNF_IMAGE_DEV}' does not contain any partition"
fi
......
......@@ -25,7 +25,6 @@
### END TASK INFO
set -e
set -o pipefail
. "@commondir@/common.sh"
......
2012-02-29, v0.3.3
* Fix a bug in pithcat where the restored image had incorrect
size. The trailing zeros in the image files where not restored.
2012-02-06, v0.3.2
* Make pithcat work with pithos v0.8.3
......
AC_PREREQ(2.59)
AC_INIT(snf-image, 0.3.2, synnefo@lists.grnet.gr)
AC_INIT(snf-image, 0.3.3, synnefo@lists.grnet.gr)
AC_CONFIG_AUX_DIR(autotools)
AC_CONFIG_SRCDIR(configure)
......
......@@ -150,7 +150,8 @@ fi
result=$(sed 's|\r||g' "$result_file" | head -1)
if [ "x$result" != "xSUCCESS" ]; then
log_error "Helper VM returned error"
log_error "Helper VM returned error:"
log_error "$result"
exit 1
fi
......
......@@ -65,7 +65,10 @@ def print_data(backend, url):
object)
for hash in hashmap:
block = backend.get_block(hash)
if len(block) > size:
block = block[:size]
stdout.write(block)
size -= len(block)
def main():
......
......@@ -159,9 +159,9 @@ exit 101
EOF
chmod +x "$target/usr/sbin/policy-rc.d"
debootstrap --arch amd64 --include "$HELPER_EXTRA_PKGS" \
--variant=minbase stable "$target" "$HELPER_MIRROR" 2>&1 | \
sed -e 's/^/DEBOOTSTRAP: /g'
debootstrap --arch $(dpkg --print-architecture) \
--include "$HELPER_EXTRA_PKGS" --variant=minbase stable "$target" \
"$HELPER_MIRROR" 2>&1 | sed -e 's/^/DEBOOTSTRAP: /g'
rm "$target/usr/sbin/policy-rc.d"
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment