The 'nmdm' is a console type used by the bhyve driver.
It works like a pty console, so adding support is just
a matter of adding it to the 'usable_types' list.
Signed-off-by: Roman Bogorodskiy <bogorodskiy@gmail.com>
Use this to fix uitests testNewVMInstallFail and friends.
Now that we catch / in object names which took away our easy way to
make libvirt domain creation fail and hit some important error
code paths
Signed-off-by: Cole Robinson <crobinso@redhat.com>
usb is an architecture-independent sound device and useful for
Windows on Arm, which does not support PC sound devices.
Signed-off-by: Akihiko Odaki <odaki@rsg.ci.i.u-tokyo.ac.jp>
Only tests used manual value for the attribute, otherwise we always used
what was detected by conn_device_boot_order() function.
Remove that attribute and update tests to use unittest.mock.patch where
needed.
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
- Add bhyve to a list of guest types that support virtio device type
- Do not include rtl8139 for bhyve
Signed-off-by: Roman Bogorodskiy <bogorodskiy@gmail.com>
In case the system tray icon is not available on Wayland (because of the
lack of Ayatana AppIndicator), the only notification of that is an
untranslated message shown only as tooltip on the check box of the
option.
To make that notification a bit more visible, use the same approach for
the libguestfs option change: add a row below the check box with a
warning icon and text next to it. This row is shown only in case there
is an error message to show, and it is used instead of setting the
tooltop of the check box.
Also, reword the error message to make it a bit less technical, and make
it translatable.
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
Add inline markers in few files for the specific lines that are longer
than the current limit (100), and that neither black nor ruff can
shorten.
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
According to PEP8 [1], 'l' (lowercase 'L') is name to avoid, as
potentially hard to read.
Switch the occurrences to more clear names representing better what the
variables/parameters represent (e.g. "tunnel", "data", etc). In case the
variable/parameter is really a list, use "lst" to not use "list" and
override the builtin.
Additionally, a 'w' variable was changed for consistency with the 'l'
changed in the line above it.
There should be no behaviour changes.
[1] https://peps.python.org/pep-0008/#names-to-avoid
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
It was needed to get the "new style" classes in Python 2, and Python 3
has only that style of classes. Hence the inheritance from "object" is
not needed and thus obsolete, so drop it.
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
As a result of the reformatting with black, few strings that were in
different lines are now in the same line, still as separate strings that
are implicitly concatenated. Merge them in a single string instead.
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
Move the placeholder replacements/formatting outside the gettext
function calls: this way the gettext calls work as expected, looking up
the actual string with placeholders and not the one with the
replacements already done (which will not work).
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
logind now supports a new key binding https://github.com/systemd/systemd/pull/29542
Ctrl+Alt+Shift+Esc that emits SecureAttentionKey to allow login managers to start
or switch back to the greeter
Using qemu-bridge-helper QEMU Session VMs are now able to use host
bridge interfaces. Currently only interface named virbr0 is allowed by
default but it is possible to change it in `/etc/qemu/bridge.conf`.
We will still keep the usermode network as default.
Resolves: https://github.com/virt-manager/virt-manager/issues/863
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
As all major distros support the riscv64 architecture, add it to the
list of prioritized architectures. This will move it up in the
architecture drop-down menu and thereby easier to find when creating
a new VM.
Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
Using internal and external snapshot mode for the same VM has some
limitations. When creating new snapshot default to the same mode as
already existing currently used snapshot. If there is no existing
snapshot default to external snapshot.
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
The commit c5a46646 asks libvirt to fill in a default panic model for us.
Now libvirt domcaps can advertise panic models, Let's fill in the panic
model combo with the advertised values.
Signed-off-by: Lin Ma <lma@suse.de>
The reason we fork by default, is to force ssh to invoke
ssh-askpass when a password is required, rather than prompt on
a terminal no one is looking at. There's a more thorough
explanation here:
https://github.com/virt-manager/virt-manager/issues/731
With SSH_ASKPASS_REQUIRE=force, we now have a way to force ssh
to use askpass in the above scenario, when ssh and libvirt are new
enough.
The default forking behavior has caused maintenance pain in the
past, and is currently causing issues on macos:
https://github.com/virt-manager/virt-manager/issues/620
Let's flip the default to `--no-fork`. The VIRT_MANAGER_DEFAULT_FORK
env variable is there as an escape hatch incase I really miscalculated.
I don't expect many people are depending on use of askpass either
way, or if they are, they are launching virt-manager from their
desktop and not a terminal, which already gives us the correct
behavior AFAICT>
My suspicion is barely anyone will notice, which is why
I'm ok with changing this now, despite the libvirt support being
brand new.
If this doesn't raise any issues, then we can eventually drop
the forking behavior all together.
Signed-off-by: Cole Robinson <crobinso@redhat.com>
openssh 8.4p1 released in Sep 2020 finally added a feature
to force using SSH_ASKPASS instead of prompting on the commandline
for password, if a password would be required.
https://man.openbsd.org/ssh.1#SSH_ASKPASS_REQUIRE
Getting this behavior is basically what our whole fork dance is
about. Now we can do it with an environment variable
Let the user override it from the environment though, so there's
an escape hatch incase this causes unforseen problems
Signed-off-by: Cole Robinson <crobinso@redhat.com>
Drop our hardcoded model lists, and just ask libvirt to fill in
a model for us. Add an entry to the combo box so users can type
in a non-default value if they want one.
Long term libvirt should be providing all this info to us via
domcapabilities
Signed-off-by: Cole Robinson <crobinso@redhat.com>
Latest upstream release was back in 2012 and the new
libayatana-appindicator project is present in all distribution supported
by libvirt.
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>