Browse Source

fix: bugfix in bootflag logic (#89)

pull/90/head 1.2.4
Giovanni Torres 8 months ago committed by GitHub
parent
commit
9662dae320
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
  1. 11
      kvm-install-vm

11
kvm-install-vm

@ -412,11 +412,14 @@ function set_boot_flag() {
*) machine="" ;; *) machine="" ;;
esac esac
local code_fd="${share_dir}/OVMF_CODE${SECUREBOOT:+.secboot}.fd" local suffix=""
local vars_fd="${share_dir}/OVMF_VARS${SECUREBOOT:+.secboot}.fd" if (( SECUREBOOT )); then
local secure_flag=$(( SECUREBOOT ? 1 : 0 )) suffix=".secboot"
fi
local code_fd="${share_dir}/OVMF_CODE${suffix}.fd"
local vars_fd="${share_dir}/OVMF_VARS${suffix}.fd"
BOOTFLAG="--boot uefi,loader=${code_fd},loader.readonly=yes,loader.type=pflash,nvram_template=$vars_fd,nvram=/var/tmp/$(basename "$vars_fd"),loader.secure=$( (( secure_flag )) && echo yes || echo no ) --features smm=on" "$machine" BOOTFLAG="--boot uefi,loader=${code_fd},loader.readonly=yes,loader.type=pflash,nvram_template=$vars_fd,nvram=/var/tmp/$(basename "$vars_fd"),loader.secure=$( (( SECUREBOOT )) && echo yes || echo no ) --features smm=on $machine"
} }
function create_vm () function create_vm ()

Loading…
Cancel
Save