From fae3f21da1a4517b0f2182f92f870ebfd7dded58 Mon Sep 17 00:00:00 2001 From: Johannes Thumshirn Date: Thu, 27 May 2021 16:54:51 +0900 Subject: [PATCH] run.py: fix qemu short-form boolean warning When running virtme with qemu 6.0.0 it complains about the deprecation of short options: qemu-system-x86_64: -fsdev local,id=virtfs1,path=/,security_model=none,readonly,multidevs=remap: warning: short-form boolean option 'readonly' deprecated Please use readonly=on instead qemu-system-x86_64: -fsdev local,id=virtfs5,path=/usr/lib/python3.8/site-packages/virtme-0.1.1-py3.8.egg/virtme/guest,security_model=none,readonly,multidevs=remap: warning: short-form boolean option 'readonly' deprecated Please use readonly=on instead Just pass in 'readonly=on' to silence the warning again. Signed-off-by: Johannes Thumshirn --- virtme/commands/run.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/virtme/commands/run.py b/virtme/commands/run.py index f11444e..8cecb07 100644 --- a/virtme/commands/run.py +++ b/virtme/commands/run.py @@ -248,7 +248,7 @@ def export_virtfs(qemu: qemu_helpers.Qemu, arch: architectures.Arch, fsid = 'virtfs%d' % len(qemuargs) qemuargs.extend(['-fsdev', 'local,id=%s,path=%s,security_model=%s%s%s' % (fsid, qemu.quote_optarg(path), - security_model, ',readonly' if readonly else '', + security_model, ',readonly=on' if readonly else '', ',multidevs=remap' if qemu.has_multidevs else '')]) qemuargs.extend(['-device', '%s,fsdev=%s,mount_tag=%s' % (arch.virtio_dev_type('9p'), fsid, qemu.quote_optarg(mount_tag))])