diff options
author | Jonathan Bauer | 2021-06-25 14:55:08 +0200 |
---|---|---|
committer | Jonathan Bauer | 2021-06-25 14:55:08 +0200 |
commit | 09f9b20ae36bbbff9e303c52d2a8f2a034cd4f1e (patch) | |
tree | 75f018f5ad995d286de930f0a0c450ab8a208f4b /core/modules/qemukvm/data/opt/openslx/vmchooser/plugins/qemukvm/includes/setup_rw_layer.inc | |
parent | Merge branch 'master' into installer (diff) | |
parent | [clientrequest] add remote debugging modul from Christoph Schulthess (diff) | |
download | mltk-09f9b20ae36bbbff9e303c52d2a8f2a034cd4f1e.tar.gz mltk-09f9b20ae36bbbff9e303c52d2a8f2a034cd4f1e.tar.xz mltk-09f9b20ae36bbbff9e303c52d2a8f2a034cd4f1e.zip |
Merge branch 'master' into installer
Diffstat (limited to 'core/modules/qemukvm/data/opt/openslx/vmchooser/plugins/qemukvm/includes/setup_rw_layer.inc')
-rw-r--r-- | core/modules/qemukvm/data/opt/openslx/vmchooser/plugins/qemukvm/includes/setup_rw_layer.inc | 25 |
1 files changed, 0 insertions, 25 deletions
diff --git a/core/modules/qemukvm/data/opt/openslx/vmchooser/plugins/qemukvm/includes/setup_rw_layer.inc b/core/modules/qemukvm/data/opt/openslx/vmchooser/plugins/qemukvm/includes/setup_rw_layer.inc deleted file mode 100644 index 32637e5d..00000000 --- a/core/modules/qemukvm/data/opt/openslx/vmchooser/plugins/qemukvm/includes/setup_rw_layer.inc +++ /dev/null @@ -1,25 +0,0 @@ - -setup_rw_layer() { - if isempty VM_DISKFILE_RO; then - writelog "No source diskfile found! This should be specified in the given XML file. Is it valid?" - EXIT_TYPE="user" EXIT_REASON="Keine virtuelle Festplatte zu dieser Veranstaltung angegeben!" cleanexit 1 - fi - - # setup qcow2 backing file for that disk file - writelog "Creating backing file for '${VM_DISKFILE_RO}'..." - # TODO: WTF? This is fucked up, VM_DISKFILE_RW is set if we want to run in persistent mode, - # this plugin shouldn't mess around with it.... - declare -rg VM_DISKFILE_RW="${TMPDIR}/$(basename ${VM_DISKFILE_RO}).qcow2" - if qemu-img create -f qcow2 -b "${VM_DISKFILE_RO}" "${VM_DISKFILE_RW}"; then - # all good, use it as main disk drive - # TODO: determine the proper type of controller to use, ideally virtio? - VIRTCMDOPTS+=("-drive" "if=virtio,format=qcow2,file=${VM_DISKFILE_RW}" ) - else - writelog "Error creating backing file for '${VM_DISKFILE_RO}'" - # TODO use -snapshot as fallback, test it! - # How is this supposed to even work without a disk? - VIRTCMDOPTS+=( "-snapshot" ) - fi -} - -call_post_source setup_rw_layer |