1
0
mirror of https://github.com/GNS3/gns3-server synced 2024-12-24 15:58:08 +00:00

Merge pull request #2178 from GNS3/fix/2177

Fix Qemu binary not set when adding appliance from template
This commit is contained in:
Jeremy Grossmann 2023-02-04 10:12:30 +05:45 committed by GitHub
commit 2b6bec1b93
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -216,7 +216,7 @@ class QemuVM(BaseNode):
if qemu_bin == "qemu":
self._platform = "i386"
else:
self._platform = re.sub(r'^qemu-system-(.*)$', r'\1', qemu_bin, re.IGNORECASE)
self._platform = re.sub(r'^qemu-system-(\w+).*$', r'\1', qemu_bin, re.IGNORECASE)
if self._platform.split(".")[0] not in QEMU_PLATFORMS:
raise QemuError("Platform {} is unknown".format(self._platform))
log.info('QEMU VM "{name}" [{id}] has set the QEMU path to {qemu_path}'.format(name=self._name,

View File

@ -35,7 +35,7 @@ QEMU_TEMPLATE_PROPERTIES = {
"platform": {
"description": "Platform to emulate",
"enum": QEMU_PLATFORMS,
"default": "i386"
"default": ""
},
"linked_clone": {
"description": "Whether the VM is a linked clone or not",