MT#6253 Sync deployment.sh with what we have in deployment-iso.git as of commit 9aa7f

changes/02/2/1
Michael Prokop 11 years ago
parent 4222a91f98
commit ad4a3ab1a3

@ -59,6 +59,10 @@ ENABLE_VM_SERVICES=false
FILESYSTEM="ext4"
SYSTEMD=false
# if TARGET_DISK environment variable is set accept it
if [ -n "$TARGET_DISK" ] ; then
export DISK="${TARGET_DISK}"
else # otherwise try to find sane default
if [ -L /sys/block/vda ] ; then
export DISK=vda # will be configured as /dev/vda
else
@ -71,6 +75,7 @@ else
fi
done
fi
fi
### helper functions {{{
set_deploy_status() {
@ -754,6 +759,9 @@ check_for_supported_disk() {
}
# run in according environment only
if [ -n "$TARGET_DISK" ] ; then
logit "Skipping check for supported disk as TARGET_DISK variable is set."
else
if [[ $(imvirt 2>/dev/null) == "Physical" ]] ; then
if ! check_for_supported_disk ; then
@ -774,6 +782,7 @@ else
die "Error: /dev/${DISK} does not look like a virtual disk. Exiting to avoid possible data damage. Note: imvirt output is $(imvirt)"
fi
fi
fi
# relevant only while deployment, will be overriden later
if [ -n "$HOSTNAME" ] ; then

Loading…
Cancel
Save