fixed bugs

This commit is contained in:
Raphael Dannecker 2023-07-04 11:42:32 +02:00
parent 4e5eebe367
commit 983e915090
4 changed files with 20 additions and 9 deletions

View file

@ -11,9 +11,13 @@ fi
VM_NAME=$1
VM_CLONE=$2
VM_DIR="/tmp/${UID}/vmimages"
# Create User-VM-Dir and link system VM-Images
[[ -d "${VM_DIR}/xml" ]] || mkdir -p "${VM_DIR}/xml"
sudo /usr/local/bin/link-images.sh
# change to image-directory
VM_DIR="/tmp/${UID}/vmimages"
cd "${VM_DIR}"
if { [[ ! -f "xml/${VM_NAME}.xml" ]] && [[ ! -f "/var/lib/libvirt/images/xml/${VM_NAME}.xml" ]]; } || [[ ! -f "${VM_NAME}.qcow2" ]]; then