* [pve-devel] applied: [PATCH manager] ui: boot order: handle cloudinit correctly
@ 2020-10-22 16:45 Thomas Lamprecht
0 siblings, 0 replies; only message in thread
From: Thomas Lamprecht @ 2020-10-22 16:45 UTC (permalink / raw)
To: pve-devel
heuristically..
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
---
and it's biting us once again to handle the cloudinit temp build like a cdrom
drive...
www/manager6/qemu/BootOrderEdit.js | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/www/manager6/qemu/BootOrderEdit.js b/www/manager6/qemu/BootOrderEdit.js
index 11048896..1e924dea 100644
--- a/www/manager6/qemu/BootOrderEdit.js
+++ b/www/manager6/qemu/BootOrderEdit.js
@@ -19,12 +19,14 @@ Ext.define('PVE.qemu.BootOrderPanel', {
xclass: 'Ext.app.ViewController',
},
+ isCloudinit: (v) => v.match(/media=cdrom/) && v.match(/[:/]vm-\d+-cloudinit/),
+
isDisk: function(value) {
return PVE.Utils.bus_match.test(value);
},
isBootdev: function(dev, value) {
- return this.isDisk(dev) ||
+ return (this.isDisk(dev) && !this.isCloudinit(value)) ||
(/^net\d+/).test(dev) ||
(/^hostpci\d+/).test(dev) ||
((/^usb\d+/).test(dev) && !(/spice/).test(value));
@@ -59,7 +61,7 @@ Ext.define('PVE.qemu.BootOrderPanel', {
}
} else if (orderList[i] === 'd') {
Ext.Object.each(me.vmconfig, function(key, value) {
- if (me.isDisk(key) && (/media=cdrom/).test(value)) {
+ if (me.isDisk(key) && value.match(/media=cdrom/) && !me.isCloudinit(value)) {
list.push(key);
}
});
--
2.20.1
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2020-10-22 16:45 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-10-22 16:45 [pve-devel] applied: [PATCH manager] ui: boot order: handle cloudinit correctly Thomas Lamprecht
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.