Compare commits

...

2015 Commits
v2.2.0 ... main

Author SHA1 Message Date
Nicolás Gal
4e51b595ac Translated using Weblate (Spanish)
Currently translated at 100.0% (1459 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/
2025-04-22 12:22:19 +02:00
hsu zangmen
e7cbaab554 Translated using Weblate (Chinese (Traditional) (zh_TW))
Currently translated at 100.0% (1459 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_TW/
2025-04-22 12:22:19 +02:00
ano n
af9baaceb5 Translated using Weblate (German)
Currently translated at 95.9% (1400 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/de/
2025-04-22 12:22:19 +02:00
ano n
e17c3ef3a0 Translated using Weblate (German)
Currently translated at 93.8% (1369 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/de/
2025-04-22 12:22:19 +02:00
AbhinavTiruvee
237896029d Validation: allow spaces, disallow slashes
Libvirt permits spaces in object names but rejects the ‘/’ character.
This change aligns our validator with libvirt’s behavior (and QEMU’s),
preventing names with '/' while still allowing human‑friendly
names with spaces.

Fixes: #740
2025-04-22 12:11:00 +02:00
Pavel Hrdina
443123ece6 virtinst: urldetect: detect Debian version for ISO images
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2025-04-16 12:06:57 -04:00
Pavel Hrdina
66aa81ae6d test_urldetect: arch is detected from the ISO media
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2025-04-16 12:06:57 -04:00
Pavel Hrdina
fbf7f060be virtinst: urldetect: figure out Debian arch from the ISO media
We should not use guest.os.arch, it doesn't work correctly if the ISO is
i386 and the VM arch is x86_64.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2025-04-16 12:06:57 -04:00
Pavel Hrdina
4257e19748 virtinst: urldetect: move default Debian arch to _set_url_paths
The function _find_treearch will be used for ISO files as well where we
don't want to have default arch.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2025-04-16 12:06:57 -04:00
Pavel Hrdina
c8a5b81867 virtinst: urldetect: don't check x86_64 for Debian/Ubuntu
They are using amd64 instead.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2025-04-16 12:06:57 -04:00
Pavel Hrdina
3b3eac28a6 test_urldetect: use fake badarch Debian
Instead of using existing arch use badarch in order to test parts of the
code when we don't know the architecture.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2025-04-16 12:06:57 -04:00
Cole Robinson
fb71f02fa2 uitests: Add coverage for mixed internal and external snapshots
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2025-04-16 11:58:33 -04:00
Cole Robinson
09574977da uitests: fix testManagerDefaultStartup race
"Checking for virtualization" is only there for about a second

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2025-04-16 11:58:33 -04:00
Cole Robinson
6458f09b72 uitests: fix testNewVMSession after networking changes
Keep this test as covering the default `Usermode` case

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2025-04-16 11:58:33 -04:00
Cole Robinson
f312872496 uitests: fix push button usage on fedora 41
somewhere in the stack this was renamed to just `button`

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2025-04-16 11:58:33 -04:00
Pavel Hrdina
4f9618289f virt-install: detect wayland in order to start virt-viewer
When running virt-install using waypipe the DISPLAY variable is not
defined and virt-install will complain that it cannot start virt-viewer.

Check for WAYLAND_DISPLAY as well, DISPLAY is defined only when xwayland
is used. In case of waypipe it configures only WAYLAND_DISPLAY.

Move the check before we check for virt-viewer as without display there
is no point to check if virt-viewer is installed or not.

Fixes: https://github.com/virt-manager/virt-manager/issues/884
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2025-03-24 15:32:28 +01:00
Joren
297d1cd282 Separate virtio sound device testing into an individual test 2025-03-22 14:14:46 +01:00
Pavel Hrdina
e39e0ad5f0 virt-manager: add support for vDPA network device
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2025-03-18 20:34:22 +01:00
Joren
e5142f28fe virt-install: add support for vDPA network device 2025-03-18 20:34:22 +01:00
Pavel Hrdina
714d5f1afd virt-manager: list virtual networks when creating new QEMU Session VM
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>
2025-03-18 20:33:33 +01:00
Pavel Hrdina
0273621b43 Update issue templates
The old issue template stopped working as GitHub updated how the
template should look like. While at it create two issue templates, one
for bugs and the other for feature requests.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2025-03-14 08:27:44 +01:00
dependabot[bot]
afc55ac0b9 ci: bump actions/setup-python from 3 to 5
Bumps [actions/setup-python](https://github.com/actions/setup-python) from 3 to 5.
- [Release notes](https://github.com/actions/setup-python/releases)
- [Commits](https://github.com/actions/setup-python/compare/v3...v5)

---
updated-dependencies:
- dependency-name: actions/setup-python
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-03-10 16:59:30 +01:00
dependabot[bot]
1709dc8294 ci: bump actions/checkout from 3 to 4
Bumps [actions/checkout](https://github.com/actions/checkout) from 3 to 4.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v3...v4)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-03-10 16:47:45 +01:00
Heinrich Schuchardt
ccfe4a0abc urlfetcher: add riscv64 architecture for Debian
Add riscv64 to the list of Debian architectures.

Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
2025-03-08 12:59:18 +01:00
Marius Vollmer
92e90e6e27 xmlapi: Don't escape property values
libxml2 does that already.

Fixes #838
2025-03-05 19:20:15 +01:00
Cole Robinson
9137fd26ef Use pre-commit to run black in CI
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2025-03-05 17:16:22 +01:00
Cole Robinson
8d18bdc1e5 Add pre-commit as a runner for black
`pre-commit` provides an easy way for devs to never miss committing
code without running black, and an easy way to to invoke black from
CI. In the future we can use it to run codespell, and new-to-us
tools like flake8

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2025-03-05 17:16:22 +01:00
Cole Robinson
f4c57a4d3b Remove pycodestyle usage
`black` is incharge of style now

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2025-03-05 17:16:22 +01:00
Pavel Hrdina
9558daafd9 Translated using Weblate (Japanese)
Currently translated at 94.3% (1377 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ja/
2025-03-05 17:02:35 +01:00
Remus-Gabriel Chelu
354c1eeb7e Translated using Weblate (Romanian)
Currently translated at 100.0% (1459 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ro/
2025-03-05 17:02:35 +01:00
Nicolás Gal
5c39b38167 Translated using Weblate (Spanish)
Currently translated at 100.0% (1459 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/

Translated using Weblate (Spanish)

Currently translated at 100.0% (1459 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/
2025-03-05 17:02:35 +01:00
Temuri Doghonadze
451b8cf920 Translated using Weblate (Georgian)
Currently translated at 100.0% (1459 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ka/
2025-03-05 17:02:35 +01:00
Cole Robinson
ef41638f5e tests: test_urls: fix dead URL
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2025-03-03 12:40:36 -05:00
Akihiko Odaki
fb54f37b60 tests: Increase virtio-mem block size
virtio-mem block size must be equal to or greater than the transparent
huge page size; otherwise, libvirt raises an error and a test will
fail. For example, on Asahi Linux, the transparent huge page size is 32
MiB, which is greater than 2 MiB, the specified virtio-mem block size.

On Linux 6.13, the configuration with the maximum transparent huge page
size is Arm64 with 64 KiB, and it has 512 MiB transparent huge pages.
Increase the block size to 512 MiB so that the test passes on every
Linux configuration.

Signed-off-by: Akihiko Odaki <akihiko.odaki@daynix.com>
2025-03-03 12:19:33 -05:00
Lin Ma
a0e390b1b6 man/virt-install: Document pstore device
Signed-off-by: Lin Ma <lma@suse.de>
2025-03-03 12:01:09 -05:00
Lin Ma
6c43ab3863 tests: add pstore test
Signed-off-by: Lin Ma <lma@suse.de>
2025-03-03 12:01:09 -05:00
Lin Ma
b5f6569bc0 virtinst: add --pstore backend=acpi-erst,path=XX,size=YY support
Libvirt since v10.6.0 introduces pstore pci device for storing oops/panic
logs in nvram storage.

Let's add it into virt-install, It has 3 suboptions:
* backend: The desired backend, by far only 'acpi-erst' is accepted.
* path:    Represents a path in the host that backs the pstore device in
           the guest. It is optional, If not specified the libvirt will
           auto generates one.
* size:    Configures the size of the persistent storage available to the
           guest. It is mandatory, unit is kilobytes.

Eg:
virt-install --pstore backend=acpi-erst,path=/tmp/guest_acpi_esrt,size=8

Signed-off-by: Lin Ma <lma@suse.de>
2025-03-03 12:01:09 -05:00
Pino Toscano
af07c39b13 chore: format the code with black
(crobinso: compress to one commit, and adjust string concat issues)

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2025-03-03 11:40:37 -05:00
Pino Toscano
768390e505 chore: add configuration for black
Add a pyproject.toml file with the configuration for the "black" tool,
to prepare reformatting the whole codebase with it:
- extend the line length from the default 88 characters to 100, more
  suitable for the virt-manager codebase
- set a custom regexp for the files to format, so also the wrapper
  scripts are handled

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2025-03-03 11:40:07 -05:00
Cole Robinson
6f188482b2 tests: uitests: handle linux2020 going EOL
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2025-03-03 10:39:12 -05:00
Heinrich Schuchardt
6c6c39be2f createvm: prioritize riscv64
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>
2025-03-03 10:13:14 -05:00
Pavel Hrdina
5ddd3456a0 virtManager: domain: fix indentation
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2025-01-29 10:50:03 +01:00
Lin Ma
9ef77c1892 tests: skip some hyperv feature tests for libvirt older than 10.7.0/11.0.0
Signed-off-by: Lin Ma <lma@suse.de>
2025-01-29 10:48:57 +01:00
Lin Ma
81c873ba36 cli: Add --features hyperv.tlbflush.extended.state=on/off
Signed-off-by: Lin Ma <lma@suse.de>
2025-01-29 10:48:57 +01:00
Lin Ma
5f2a2dbd0a cli: Add --features hyperv.tlbflush.direct.state=on/off
Signed-off-by: Lin Ma <lma@suse.de>
2025-01-29 10:48:57 +01:00
Lin Ma
1f43c0d1d9 cli: Add --features hyperv.emsr_bitmap.state=on/off
Signed-off-by: Lin Ma <lma@suse.de>
2025-01-29 10:48:57 +01:00
Lin Ma
5617330513 cli: Add --features hyperv.xmm_input.state=on/off
Signed-off-by: Lin Ma <lma@suse.de>
2025-01-29 10:48:57 +01:00
Lin Ma
dc89a02c75 cli: Add nvram.templateFormat to indicate template format
Signed-off-by: Lin Ma <lma@suse.de>
2025-01-29 10:48:57 +01:00
Lin Ma
f278c89b49 cli: Add --tpm backend.profile.{source,removeDisabled} support
Swtpm since v0.10 supports to configure a TPM2 with a profile from file.
eg:

root@localhost:~ # cat /etc/swtpm/profiles/mytest.json
{
      "Name": "custom:test",
      "Algorithms":"rsa,rsa-min-size=1024,......"
}

root@localhost:~ # swtpm_setup --tpm2 --print-profiles | jq
{
  "local": [
    {
      "Name": "mytest",
      "Algorithms": "rsa,rsa-min-size=1024,......"
    }
  ],
  "builtin": [
    {
      "Name": "default-v1",
      "StateFormatLevel": 7,
      "Commands": "......",
      "Algorithms": "rsa,rsa-min-size=1024,......",
      "Description": "......"
    },
    {
      "Name": "null",
      "StateFormatLevel": 1,
      "Commands": "......",
      "Algorithms": "rsa,rsa-min-size=1024,......",
      "Description": "......"
    },
    {
      "Name": "custom",
      "StateFormatLevel": 2,
      "Commands": "......",
      "Algorithms": "rsa,rsa-min-size=1024,......",
      "Description": "......"
    }
  ]
}

Libvirt supports it since v10.10.0

Let's add this feature into virt-install, eg:

root@localhost:~ # virt-install \
......\
--tpm model=tpm-tis,backend.version=2.0,\
backend.profile.source=local:mytest,backend.profile.removeDisabled=check

Signed-off-by: Lin Ma <lma@suse.de>
2025-01-29 10:48:57 +01:00
Lin Ma
9263859944 .gitignore: Ignore coverage.xml
Signed-off-by: Lin Ma <lma@suse.de>
2025-01-29 10:48:57 +01:00
Lin Ma
006ce41576 test_cli: Fix a pycodestyle E261 issue
root@localhost:~ # meson test -C build

==================================== 1/3 =========================
test:         pycodestyle
start time:   14:08:14
duration:     5.80s
result:       exit status 1
command:      MSAN_OPTIONS=halt_on_error=1:abort_on_error=1:...... \
/usr/bin/pycodestyle \
--config setup.cfg --format pylint tests virtinst virtManager
----------------------------------- stdout -----------------------------------
tests/test_cli.py:1157: [E261] at least two spaces before inline comment
......

Signed-off-by: Lin Ma <lma@suse.de>
2025-01-29 10:48:57 +01:00
Lin Ma
a7c455f460 cli: Add 'poll' settings for iothread
Since libvirt v9.4.0, It introduces 'poll' settings in domain XML to
override the hypervisor-default interval of polling for iothread.

Let's add it into virt-install.
Eg:
virt-install \
...... \
--iothreads iothreads=2,\
iothreadids.iothread0.id=1,\
iothreadids.iothread1.id=2,\
iothreadids.iothread1.poll.max=123,\
iothreadids.iothread1.poll.grow=456,\
iothreadids.iothread1.poll.shrink=789

It results in the following domain XML snippet:
  <iothreads>2</iothreads>
  <iothreadids>
    <iothread id='1'/>
    <iothread id='2'>
      <poll max='123' grow='456' shrink='789'/>
    </iothread>
  </iothreadids>

Signed-off-by: Lin Ma <lma@suse.de>
2025-01-29 10:25:37 +01:00
Lin Ma
36d00e0e79 cli: Add --disk driver.queue_size support
Eg:
virt-install \
......
--disk /tmp/disk0.qcow2,size=10,driver.type=qcow2,\
driver.queues=4,driver.queue_size=256 \
......

It results in the following domain XML snippet:
    <disk type='file' device='disk'>
      <driver name='qemu' type='qcow2' queues='4' queue_size='256'/>
      <source file='/tmp/disk0.qcow2' index='2'/>
      <backingStore/>
      <target dev='vda' bus='virtio'/>
      <address type='pci' domain='0x0000' bus='0x05' slot='0x00' function='0x0'/>
    </disk>

Signed-off-by: Lin Ma <lma@suse.de>
2025-01-29 10:25:37 +01:00
Lin Ma
79c333e364 cli: add target.memReserve for pci-bridge and pcie-root-port controllers
Libvirt(since v10.3.0) supports setting memReserve attribute to pci-bridge
and pcie-root-port, Let's add it into virt-install. Eg:

virt-install \
......
--controller pci,index=0,model=pcie-root \
--controller pci,index=1,model=pcie-root-port,target.memReserve=8196 \
--controller pci,index=2,model=dmi-to-pci-bridge \
--controller pci,index=3,model=pci-bridge,target.memReserve=8196 \
......

It results in the following domain XML snippet:
    <controller type='pci' index='0' model='pcie-root'>
      <alias name='pcie.0'/>
    </controller>
    <controller type='pci' index='1' model='pcie-root-port'>
      <model name='pcie-root-port'/>
      <target chassis='1' port='0x10' memReserve='8196'/>
      <alias name='pci.1'/>
      <address type='pci' ....../>
    </controller>
    <controller type='pci' index='2' model='dmi-to-pci-bridge'>
      <model name='i82801b11-bridge'/>
      <alias name='pci.2'/>
      <address type='pci' ....../>
    </controller>
    <controller type='pci' index='3' model='pci-bridge'>
      <model name='pci-bridge'/>
      <target chassisNr='3' memReserve='8196'/>
      <alias name='pci.3'/>
      <address type='pci' ....../>
    </controller>

Signed-off-by: Lin Ma <lma@suse.de>
2025-01-29 10:25:37 +01:00
Lin Ma
8564ace73a cli: Add --memdev target.dynamicMemslots support for virtio-mem
Libvirt supports setting dynamicMemslots attribute for virtio-mem since
v10.1.0, Let's add it into virt-install. Eg:

virt-install \
......
--vcpu 2 \
--cpu cell0.cpus=0,cell0.memory=4194304,\
cell1.cpus=1,cell1.memory=4194304 \
--memory maxMemory=65536,maxMemory.slots=8 \
--memdev model=virtio-mem,\
target.node=0,\
target.block=2048,\
target.size=8192,\
target.dynamicMemslots=yes \
......

It results in the following domain XML snippet:
    <memory model='virtio-mem'>
      <target dynamicMemslots='yes'>
        ......
    </memory>

Signed-off-by: Lin Ma <lma@suse.de>
2025-01-29 10:25:37 +01:00
Pavel Hrdina
54dc858f79 snapshots: warn users to not mix snapshot modes
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2025-01-27 22:59:56 +01:00
Pavel Hrdina
40d86086b6 snapshots: default to same snapshot mode as currently used snapshot
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>
2025-01-27 22:59:56 +01:00
Pino Toscano
83f391961a chore: stop excluding NEWS.md in codespell configuration
There are no issues now.

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2025-01-27 09:59:51 +01:00
Pino Toscano
1af0ec1b4c chore: typo fixes in NEWS.md
- "graphcis" -> "graphics"
- "improvments" -> "improvements"
- "swtich" -> "switch"

Found using codespell.

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2025-01-27 09:59:51 +01:00
Temuri Doghonadze
2dc9c7b770 Translated using Weblate (Georgian)
Currently translated at 98.4% (1437 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ka/
2025-01-24 21:09:17 +01:00
Temuri Doghonadze
b7879cc19e Translated using Weblate (Georgian)
Currently translated at 97.9% (1429 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ka/
2025-01-24 21:09:17 +01:00
Temuri Doghonadze
f359fc72e5 Translated using Weblate (Georgian)
Currently translated at 97.5% (1423 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ka/
2025-01-24 21:09:17 +01:00
Temuri Doghonadze
ccaa7a5ac5 Translated using Weblate (Georgian)
Currently translated at 97.2% (1419 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ka/
2025-01-24 21:09:17 +01:00
Temuri Doghonadze
63798e18d9 Translated using Weblate (Georgian)
Currently translated at 96.5% (1409 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ka/
2025-01-24 21:09:17 +01:00
Temuri Doghonadze
8a69419baf Translated using Weblate (Georgian)
Currently translated at 94.5% (1379 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ka/
2025-01-24 21:09:17 +01:00
Temuri Doghonadze
6b69c652e1 Translated using Weblate (Georgian)
Currently translated at 94.3% (1377 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ka/
2025-01-24 21:09:17 +01:00
Temuri Doghonadze
bc4dd1e900 Translated using Weblate (Georgian)
Currently translated at 94.2% (1375 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ka/
2025-01-24 21:09:17 +01:00
Nicolas Gal
b5ca83c4a9 Translated using Weblate (Spanish)
Currently translated at 100.0% (1459 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/
2025-01-24 21:09:17 +01:00
Ricky Tigg
270e8f136b Translated using Weblate (Finnish)
Currently translated at 100.0% (1459 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fi/
2025-01-24 21:09:17 +01:00
Nicolas Gal
9447b51a01 Translated using Weblate (Spanish)
Currently translated at 100.0% (1459 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/
2025-01-24 21:09:17 +01:00
Nicolas Gal
5f94cb86aa Translated using Weblate (Spanish)
Currently translated at 100.0% (1459 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/
2025-01-24 21:09:17 +01:00
Nicolas Gal
a6b97cf089 Translated using Weblate (Spanish)
Currently translated at 100.0% (1459 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/
2025-01-24 21:09:17 +01:00
Nicolas Gal
fd3c7febdb Translated using Weblate (Spanish)
Currently translated at 100.0% (1459 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/
2025-01-24 21:09:17 +01:00
Nicolas Gal
dd06b6081c Translated using Weblate (Spanish)
Currently translated at 100.0% (1459 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/
2025-01-24 21:09:17 +01:00
Temuri Doghonadze
e5312173c2 Translated using Weblate (Georgian)
Currently translated at 93.5% (1365 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ka/
2025-01-24 21:09:17 +01:00
Moises Tamaalit
c8fa4bf1ea Translated using Weblate (Spanish)
Currently translated at 99.9% (1458 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/
2025-01-24 21:09:17 +01:00
Nicolas Gal
3b43498bfd Translated using Weblate (Spanish)
Currently translated at 99.9% (1458 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/

Translated using Weblate (Spanish)

Currently translated at 99.9% (1458 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/

Translated using Weblate (Spanish)

Currently translated at 99.9% (1458 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/

Translated using Weblate (Spanish)

Currently translated at 99.9% (1458 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/
2025-01-24 21:09:17 +01:00
Ettore Atalan
fdcbfeaa10 Translated using Weblate (German)
Currently translated at 89.5% (1307 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/de/
2025-01-24 21:09:17 +01:00
Nicolas Gal
5a08f96f01 Translated using Weblate (Spanish)
Currently translated at 100.0% (1459 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/

Translated using Weblate (Spanish)

Currently translated at 100.0% (1459 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/

Translated using Weblate (Spanish)

Currently translated at 93.5% (1365 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/

Translated using Weblate (Spanish)

Currently translated at 93.0% (1358 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/
2025-01-24 21:09:17 +01:00
christian hartmann
514ff85b42 Translated using Weblate (German)
Currently translated at 88.8% (1297 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/de/
2025-01-24 21:09:17 +01:00
Salvatore Cocuzza
6f06d0fead Translated using Weblate (Italian)
Currently translated at 100.0% (1459 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2025-01-24 21:09:17 +01:00
Ricky Tigg
adb04c31f2 Translated using Weblate (Finnish)
Currently translated at 100.0% (1459 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fi/
2025-01-24 21:09:17 +01:00
ButterflyOfFire
113320c19a Translated using Weblate (Kabyle)
Currently translated at 4.5% (67 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/kab/
2025-01-24 21:09:17 +01:00
Andi Chandler
22dce0d244 Translated using Weblate (English (United Kingdom))
Currently translated at 100.0% (1459 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/en_GB/
2025-01-24 21:09:17 +01:00
Jarne Förster
b1c912117e Translated using Weblate (German)
Currently translated at 88.5% (1292 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/de/
2025-01-24 21:09:17 +01:00
Geraldo S. Simião Kutz
ca62c09324 Translated using Weblate (Portuguese (Brazil))
Currently translated at 100.0% (1459 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/
2025-01-24 21:09:17 +01:00
Moises Tamaalit
9d4961bd36 Translated using Weblate (Spanish)
Currently translated at 92.8% (1355 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/
2025-01-24 21:09:17 +01:00
Andika Triwidada
183525243a Translated using Weblate (Indonesian)
Currently translated at 97.2% (1419 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/

Translated using Weblate (Indonesian)

Currently translated at 93.6% (1367 of 1459 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/
2025-01-24 21:09:17 +01:00
Pino Toscano
da2f65f926 ci: add a simple codespell job
Add a simple workflow that runs codespell on the sources.

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2025-01-09 16:17:28 +01:00
Pino Toscano
3cfd2e2dab chore: drop codespell excluded word
'matchs' does not appear anywhere in the sources, so stop excluding it.

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2025-01-09 16:17:28 +01:00
Pino Toscano
e1340f73cb chore: tell codespell to ignore the whole 'po' subdirectory
The 'po' subdirectory contains mostly the translation template, the
translations, and other metadata related to translations, and all of
them are not to be fixed directly.

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2025-01-09 16:17:28 +01:00
Pino Toscano
2724194c87 chore: move codespell configuration in its own file
Rather than passing the various bits for codespell when running it via
meson, create a configuration file for them. This way it will be
possible to run codespell manually getting the same results.

There is no change to the actual codespell configuration.

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2025-01-09 16:17:28 +01:00
tinyboxvk
412c5d1ad3 Fix typos
Signed-off-by: tinyboxvk <13696594+tinyboxvk@users.noreply.github.com>
2025-01-09 15:45:48 +01:00
Andrea Bolognani
c3debb4eda cli, man: Always list --osinfo before --os-variant
The former is the preferred spelling and it should always be
presented first to the user.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2024-12-10 14:06:12 +01:00
Lin Ma
f92c25749b addhardware: panic: Fill in model combo with advertised values by libvirt
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>
2024-12-10 14:05:20 +01:00
Lin Ma
f9ceec2b14 tests: Update capabilities for advertisting panic device models
Signed-off-by: Lin Ma <lma@suse.de>
2024-12-10 14:05:20 +01:00
Lin Ma
c859c7acec domcaps: get list of supported panic device models
libvirt commit a52cd504 added support for advertisting panic device models.
Let's use it in domcapabilities.

Signed-off-by: Lin Ma <lma@suse.de>
2024-12-10 14:05:20 +01:00
Andrea Bolognani
8af438dd58 cpu: Prefer maximum mode for many emulated guests
The actual default CPU at the QEMU level is often a relatively
poor choice, which is stuck with just baseline functionality
and can sometimes not run modern guests at all.

Whenever possible, prefer maximum mode for a much nicer out of
the box experience.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2024-12-10 14:01:32 +01:00
Andrea Bolognani
11b70218d3 gui: Support maximum CPU mode
Allow the user to set it and recognize it correctly when the
domain is already using it.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2024-12-10 14:01:32 +01:00
Andrea Bolognani
fca41cfaa9 cli: Support --cpu maximum
This mode has been introduced in libvirt 7.1.0 (March 2021) and
can be already used today with

  --cpu mode=maximum

This is however slightly inconvenient to type and is not
consistent with the special treatment that the other modes
(host-passthrough, host-model) get.

Introduce a proper special mode for it.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2024-12-10 14:01:32 +01:00
Cole Robinson
ebf5d5f491 spec: rhel: drop spice dep, default to VNC
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-12-09 13:53:55 +01:00
Cole Robinson
ffc7d2bb1b spec: Remove unused with_guestfs
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-12-09 13:53:55 +01:00
Cole Robinson
94271b429e spec: Skip dconf dep if building for flatpak
Host dconf is apparently used in this case, and installing dconf
inside the flatpak is not necessary

https://src.fedoraproject.org/rpms/virt-manager/pull-request/4

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-12-09 13:53:55 +01:00
Cole Robinson
a4c84aa1bb spec: Add /usr/share/virt-manager/ui/ to RPM database (bz 2283244)
Using *.ui wildcard isn't necessary, just include the dir and all
its subfiles

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-12-09 13:53:55 +01:00
Pavel Hrdina
b74730ebb6 spec: update link to virt-manager sources
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-12-02 13:52:47 +01:00
dependabot[bot]
40d5804cdd ci: bump codecov/codecov-action from 4 to 5
Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from 4 to 5.
- [Release notes](https://github.com/codecov/codecov-action/releases)
- [Changelog](https://github.com/codecov/codecov-action/blob/main/CHANGELOG.md)
- [Commits](https://github.com/codecov/codecov-action/compare/v4...v5)

---
updated-dependencies:
- dependency-name: codecov/codecov-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-11-29 18:36:38 +01:00
Pavel Hrdina
d17731aea1 Release of virt-manager 5.0.0
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-11-26 20:53:59 +01:00
Pavel Hrdina
cb2e5aa782 tests: urls: update old and obsolete OS versions
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-11-26 15:57:05 +01:00
Pavel Hrdina
06265f8013 tests: urls: replace Scientific Linux with AlmaLinux
Scientific Linux is no longer supported as it ended with version 7 so
change it to AlmaLinux that is mentioned to be used instead.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-11-26 15:54:45 +01:00
Weblate
4aa80f4c20 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2024-11-26 14:17:35 +01:00
Ettore Atalan
9efd05753d Translated using Weblate (German)
Currently translated at 88.0% (1300 of 1476 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/de/
2024-11-26 14:17:35 +01:00
Jiri Grönroos
1ba412f362 Translated using Weblate (Finnish)
Currently translated at 98.7% (1457 of 1476 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fi/
2024-11-26 14:17:35 +01:00
Piotr Drąg
ff0b17e0b8 Translated using Weblate (Polish)
Currently translated at 100.0% (1476 of 1476 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pl/
2024-11-26 14:17:35 +01:00
김인수
cc6ddf4f43 Translated using Weblate (Korean)
Currently translated at 100.0% (1476 of 1476 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/
2024-11-26 14:17:35 +01:00
Yuri Chornoivan
160b8be21e Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1476 of 1476 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2024-11-26 14:17:35 +01:00
Oğuz Ersen
34f990e32f Translated using Weblate (Turkish)
Currently translated at 100.0% (1476 of 1476 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/tr/
2024-11-26 14:17:35 +01:00
Temuri Doghonadze
a6b6558cdb Translated using Weblate (Georgian)
Currently translated at 93.2% (1376 of 1476 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ka/
2024-11-26 14:17:35 +01:00
aa75b492a2 Translated using Weblate (Russian)
Currently translated at 100.0% (1476 of 1476 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ru/
2024-11-26 14:17:35 +01:00
Remus-Gabriel Chelu
89c98cdb97 Translated using Weblate (Romanian)
Currently translated at 100.0% (1476 of 1476 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ro/
2024-11-26 14:17:35 +01:00
Andika Triwidada
03e5e5369a Translated using Weblate (Indonesian)
Currently translated at 93.2% (1376 of 1476 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/

Translated using Weblate (Indonesian)

Currently translated at 89.8% (1326 of 1476 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/

Translated using Weblate (Indonesian)

Currently translated at 86.4% (1276 of 1476 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/

Translated using Weblate (Indonesian)

Currently translated at 84.7% (1251 of 1476 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/

Translated using Weblate (Indonesian)

Currently translated at 83.0% (1226 of 1476 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/

Translated using Weblate (Indonesian)

Currently translated at 79.6% (1176 of 1476 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/

Translated using Weblate (Indonesian)

Currently translated at 76.2% (1126 of 1476 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/

Translated using Weblate (Indonesian)

Currently translated at 72.7% (1074 of 1476 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/
2024-11-26 14:17:35 +01:00
Pavel Borecki
0a6cb73e90 Translated using Weblate (Czech)
Currently translated at 100.0% (1476 of 1476 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/cs/
2024-11-26 14:17:35 +01:00
Luna Jernberg
d9b3b4dfd0 Translated using Weblate (Swedish)
Currently translated at 100.0% (1476 of 1476 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sv/

Translated using Weblate (Swedish)

Currently translated at 99.7% (1472 of 1476 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sv/
2024-11-26 14:17:35 +01:00
Pino Toscano
c70d8d6c06 Translated using Weblate (Italian)
Currently translated at 99.7% (1472 of 1476 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2024-11-26 14:17:35 +01:00
Weblate
e9ee09d8d1 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2024-11-26 14:17:35 +01:00
Pavel Hrdina
58c93f0e54 po: Refresh translation template
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-11-26 14:03:34 +01:00
Pavel Hrdina
14a6bd64ed po: meson: drop --join-existing from gettext arguments
With setup.py we cleared po/virt-manager.pot file and created a new
fresh content using gettext.

I missed that fact when converting to meson and with the --join-existing
argument the comments for each msgid were growing with references to
their location in source files.

There is no need to clear the file and generate it again because
removing the --join-existing will end up with the same result.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-11-26 14:03:26 +01:00
Cole Robinson
17f171cdb7 cli: add --network passt,portForward=8080:80 convenience syntax
Roughly mirroring `podman run -p` syntax. Examples:

--network passt,portForward=8080:80
--network passt,portForward0=7000-8000/udp,portForward1=127.0.0.1:2222:22

Resolves: https://github.com/virt-manager/virt-manager/issues/751

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-21 21:59:44 +01:00
Cole Robinson
2f8f0e8151 virt-xml: implement --edit --boot uefi=off
Disable all UEFI config bits for an existing VM

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-21 21:51:24 +01:00
Cole Robinson
cfcd63b74e virt-install: implement --boot uefi=off
Tells virt-install to not use UEFI, if it would normally default
to it.

This likely isn't too useful in practice, since all occasions we
default to UEFI require it. But it future proofs opt out in case
we ever start defaulting to UEFI in cases where BIOS still works.

Resolves: https://github.com/virt-manager/virt-manager/issues/692

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-21 21:51:24 +01:00
Cole Robinson
f082087348 cli: Add stub support for --boot uefi=on|off
The way `--boot uefi` is implemented allows a value to be passed,
but the value is completely ignored. So `--boot uefi=off` or
`--boot uefi=FOOBAR` is treated the same as `--boot uefi`

Lets fix this by making `--boot uefi` and `--boot uefi=on` the same,
`--boot uefi=off` will be implemented later, but any other value
throws an error. This is technically an CLI break but I don't
think it's anything to worry about

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-21 21:51:24 +01:00
Cole Robinson
f3aa24bd5d virt-install: use default --cpu mode more often
Currently we will only apply the default `--cpu mode=host-passthrough`
config when _no_ `--cpu` config is passed. But this means if a user
configures ex. cpu `<topology>`, we don't set `host-passthrough` and
they get the libvirt/qemu default baseline CPU.

Instead, only skip the default config if the user manually
specified a `mode` or `model` value directly

https://issues.redhat.com/browse/RHEL-65371

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-19 21:21:25 +01:00
Cole Robinson
8fb78739e7 virt-clone: try harder to allow nonexisting images with --preserve
Input XML can have non-existent disk images as long as `--preserve`
is used, or those disks are skipped for any reason. We already
handle that correctly in some cases, but others we fail. This
covers another one.

Resolves: https://github.com/virt-manager/virt-manager/issues/563

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-19 21:19:25 +01:00
Cole Robinson
058d8b4ccd storage: Add testsuite way to trigger StoragePool.install error
With the libvirt testdriver, we can create+start a directory
pool that points to any arbitrary host path. But this doesn't
match the behavior of the real storage driver, where pool start
will fail if the source directory doesn't exist.

Let's mock this by raising an exception if we are inside the
test suite and we see a special string in the pool XML

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-19 21:19:25 +01:00
Cole Robinson
3e47db67de virt-clone: document limits of --replace
`--replace` will attempt to remove any existing VM with the new
clone name before performing the clone operation. There's a report
that it will fail for an existing VM with nvram, since we need
aren't doing the equivalent of `virsh undefine --nvram`

https://issues.redhat.com/browse/RHEL-65105

Making `--replace` remove nvram is easy, but it kinda breaks some
Cloner assumptions about determining ahead of time whether we
need to clone nvram or not. It's fixable but it's messy.

Also, making changes here raises the question about how we should be
handling all the other `virsh undefine` flags that have appeared over
the years.

I think it's better to leave `--replace` as is, and just document
that it's doing the simplest equivalent of
`virsh destroy` + `virsh undefine`. Anything more complicated
than that will cause the clone operation to fail, the user needs
to handle VM removal themselves.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-19 21:19:25 +01:00
Cole Robinson
8eb87af411 cloner: Handle .qcow2 nvram extension
We were hardcoding .fd extension, but it can be different nowadays

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-19 21:19:25 +01:00
Cole Robinson
276aa4a72e virt-clone: only attempt --reflink for raw images
--reflink only works with raw images, since copying anything else
will hit the qemu-img code path in libvirt storage driver.
This can pop up more nowadays since UEFI support is using qcow2 as
well.

Let's only attempt --reflink for raw disk images. It's basically
an optimization anyways

https://bugzilla.redhat.com/show_bug.cgi?id=2256285

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-19 21:19:25 +01:00
Cole Robinson
a22ac0932e man: virt-clone: Fix typo
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-19 21:19:25 +01:00
Cole Robinson
625c99fbf4 guest: refactor _add_default_input_device
Default to adding tablet+keyboard if graphics and usb are configured.
This saves us from having to duplicate the arch list.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-19 19:41:19 +01:00
Cole Robinson
2835c250c7 virt-install: support --input none
Disables adding any default input devices

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-19 19:41:19 +01:00
Cole Robinson
c78ec96933 virt-install: let libvirt handle --input bus=default
Our logic here is poorly duplicating libvirt's postparse logic.
Notably it will try to add bus=ps2 on non-x86, and misses obscure
cases like parallels.

https://issues.redhat.com/browse/RHEL-66768

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-19 19:41:19 +01:00
Tomas Dabašinskas
fa927c7836 add a note that tpm can be effectively disabled by passing none 2024-11-19 10:24:33 -05:00
Emmanuel Ferdman
f211e1a566 update virt-manager.spec.in reference
Signed-off-by: Emmanuel Ferdman <emmanuelferdman@gmail.com>
2024-11-14 17:17:39 +01:00
Cole Robinson
d93e3cb8d4 ci: fix libvirt upstream job after meson
Was erroring with 'Dist currently only works with Git or Mercurial
repos'. Seems like something about the libvirt checkout ordering
caused problems

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-13 10:49:38 -05:00
Lin Ma
301423b83a virt-install: Fix the active_pcr_banks issue for TPM emulator
The commit 6baa327d added active_pcr_banks support, but put it under the child
element <tpm>, which is wrong, It should be under sub child element <backend>.

Before:
  --tpm model=tpm-tis,backend.type=emulator,backend.version=2.0,\
      active_pcr_banks.sha1=on,\
	  active_pcr_banks.sha256=yes,\
	  active_pcr_banks.sha384=yes,\
	  active_pcr_banks.sha512=yes

  It results in the following domain xml:
    <tpm model='tpm-tis'>
      <backend type='emulator' version='2.0'/>
      <alias name='tpm0'/>
    </tpm>

After:
  --tpm model=tpm-tis,backend.type=emulator,backend.version=2.0,\
      backend.active_pcr_banks.sha1=on,\
	  backend.active_pcr_banks.sha256=yes,\
	  backend.active_pcr_banks.sha384=yes,\
	  backend.active_pcr_banks.sha512=yes

  It results in the following domain xml:
    <tpm model='tpm-tis'>
      <backend type='emulator' version='2.0'>
        <active_pcr_banks>
          <sha1/>
          <sha256/>
          <sha384/>
          <sha512/>
        </active_pcr_banks>
      </backend>
      <alias name='tpm0'/>
    </tpm>

Signed-off-by: Lin Ma <lma@suse.de>
2024-11-13 11:29:09 +01:00
Lin Ma
fd48e0be57 virt-install: Add --tpm backend.source support
E.g.
    virt-install \
    ... \
    --tpm model=tpm-tis,backend.type=emulator,backend.version=2.0,\
          backend.source.type=dir,backend.source.path=/some/dir

  It results in the following domain xml:
  <backend type="emulator" version="2.0">
    <source type="dir" path="/some/dir"/>
  </backend>

Signed-off-by: Lin Ma <lma@suse.de>
2024-11-13 11:29:09 +01:00
Lin Ma
7e4f7ae3d8 virt-install: Add support for 'debug' parameter on TPM emulator
E.g.
    virt-install \
    ... \
    --tpm model=tpm-tis,backend.type=emulator,backend.version=2.0,backend.debug=3

  It results in the following domain xml:
  <tpm model="tpm-tis">
    <backend type="emulator" version="2.0" debug="3"/>
  </tpm>

Signed-off-by: Lin Ma <lma@suse.de>
2024-11-13 11:29:09 +01:00
Lin Ma
1219030319 virt-install: Add support for streams attribute for 'virtio' sound card
E.g.
    virt-install \
    ... \
    --sound model=virtio,streams=4

  It results in the following domain xml:
  <sound model="virtio" streams="4"/>

Signed-off-by: Lin Ma <lma@suse.de>
2024-11-13 11:29:09 +01:00
Lin Ma
e883e7d525 virt-install: Add support for multi-channel mode for 'usb' sound card
E.g.
    virt-install \
    ... \
    --sound model=usb,multichannel=yes

  It results in the following domain xml:
  <sound model="usb" multichannel="yes"/>

Signed-off-by: Lin Ma <lma@suse.de>
2024-11-13 11:29:09 +01:00
Lin Ma
1c0f7f62e8 virt-install: Add support for blockio.discard_granularity
E.g.
    virt-install \
    ... \
    --disk /tmp/disk0.qcow2,size=16,driver.type=qcow2,blockio.discard_granularity=4096

  It results in the following domain xml:
  <disk type='file' device='disk'>
    <driver name='qemu' type='qcow2' discard='unmap'/>
    <source file='/tmp/disk0.qcow2'/>
    <target dev='vda' bus='virtio'/>
    <blockio discard_granularity="4096"/>
  </disk>

Signed-off-by: Lin Ma <lma@suse.de>
2024-11-13 11:29:09 +01:00
Lin Ma
0054b71dd7 virt-install: Fix a typo
Signed-off-by: Lin Ma <lma@suse.de>
2024-11-13 11:29:09 +01:00
Pino Toscano
50b6a90a88 po: Refresh translation template
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2024-11-13 08:12:10 +01:00
Ettore Atalan
819b746ddd Translated using Weblate (German)
Currently translated at 88.4% (1292 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/de/
2024-11-13 08:09:13 +01:00
Léane GRASSER
991355efcc Translated using Weblate (French)
Currently translated at 92.1% (1346 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fr/
2024-11-13 08:09:13 +01:00
Jiri Grönroos
d1fce2ff2d Translated using Weblate (Finnish)
Currently translated at 99.7% (1456 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fi/
2024-11-13 08:09:13 +01:00
ButterflyOfFire
ea7306b0ca Translated using Weblate (Kabyle)
Currently translated at 4.5% (66 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/kab/

Translated using Weblate (Kabyle)

Currently translated at 4.5% (66 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/kab/

Translated using Weblate (Kabyle)

Currently translated at 4.4% (65 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/kab/
2024-11-13 08:09:13 +01:00
Rachida SA
a05298f920 Translated using Weblate (Kabyle)
Currently translated at 2.2% (33 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/kab/
2024-11-13 08:09:13 +01:00
Adolfo Jayme Barrientos
123978ce6f Translated using Weblate (Spanish)
Currently translated at 93.7% (1369 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/

Translated using Weblate (Spanish)

Currently translated at 93.7% (1369 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/

Translated using Weblate (Spanish)

Currently translated at 92.1% (1346 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/

Translated using Weblate (Spanish)

Currently translated at 92.1% (1345 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/
2024-11-13 08:09:13 +01:00
Remus-Gabriel Chelu
8b787b9486 Translated using Weblate (Romanian)
Currently translated at 100.0% (1460 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ro/

Translated using Weblate (Romanian)

Currently translated at 84.7% (1237 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ro/
2024-11-13 08:09:13 +01:00
Lucas Fernandes
3f9398e362 Translated using Weblate (Portuguese (Brazil))
Currently translated at 99.3% (1451 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/
2024-11-13 08:09:13 +01:00
Moises Tamaalit
69a91e86d5 Translated using Weblate (Spanish)
Currently translated at 93.7% (1369 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/

Translated using Weblate (Spanish)

Currently translated at 89.7% (1311 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/

Translated using Weblate (Spanish)

Currently translated at 89.7% (1311 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/

Translated using Weblate (Spanish)

Currently translated at 89.7% (1310 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/

Translated using Weblate (Spanish)

Currently translated at 89.0% (1300 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/
2024-11-13 08:09:13 +01:00
Omar TS
dfbc705b39 Translated using Weblate (Arabic)
Currently translated at 4.0% (59 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ar/

Translated using Weblate (Arabic)

Currently translated at 2.4% (36 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ar/
2024-11-13 08:09:13 +01:00
Pino Toscano
42074a0f19 Translated using Weblate (Italian)
Currently translated at 100.0% (1460 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2024-11-13 08:09:13 +01:00
Pavel Borecki
2c12dd385f Translated using Weblate (Czech)
Currently translated at 100.0% (1460 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/cs/
2024-11-13 08:09:13 +01:00
Andika Triwidada
1b9df22a87 Translated using Weblate (Indonesian)
Currently translated at 72.6% (1060 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/

Translated using Weblate (Indonesian)

Currently translated at 71.2% (1040 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/

Translated using Weblate (Indonesian)

Currently translated at 69.1% (1010 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/

Translated using Weblate (Indonesian)

Currently translated at 65.7% (960 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/

Translated using Weblate (Indonesian)

Currently translated at 62.3% (910 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/

Translated using Weblate (Indonesian)

Currently translated at 58.9% (860 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/

Translated using Weblate (Indonesian)

Currently translated at 53.1% (776 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/

Translated using Weblate (Indonesian)

Currently translated at 50.0% (730 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/

Translated using Weblate (Indonesian)

Currently translated at 41.2% (602 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/
2024-11-13 08:09:13 +01:00
Göran Uddeborg
a774a5354e Translated using Weblate (Swedish)
Currently translated at 100.0% (1460 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sv/
2024-11-13 08:09:13 +01:00
Piotr Drąg
712fc0d481 Translated using Weblate (Polish)
Currently translated at 100.0% (1460 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pl/
2024-11-13 08:09:13 +01:00
jianqing yan
11f91c63ae Translated using Weblate (Chinese (Simplified) (zh_CN))
Currently translated at 99.4% (1452 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_CN/
2024-11-13 08:09:13 +01:00
Hoppár Zoltán
8a7b0de5b8 Translated using Weblate (Hungarian)
Currently translated at 55.9% (817 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/hu/
2024-11-13 08:09:13 +01:00
96e37d2b77 Translated using Weblate (Russian)
Currently translated at 100.0% (1460 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ru/

Translated using Weblate (Italian)

Currently translated at 99.5% (1453 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2024-11-13 08:09:13 +01:00
Temuri Doghonadze
8c61113f96 Translated using Weblate (Georgian)
Currently translated at 93.1% (1360 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ka/
2024-11-13 08:09:13 +01:00
Yuri Chornoivan
e3a4c1506e Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1460 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2024-11-13 08:09:13 +01:00
Oğuz Ersen
bdeb440421 Translated using Weblate (Turkish)
Currently translated at 100.0% (1460 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/tr/
2024-11-13 08:09:13 +01:00
Luna Jernberg
d728725281 Translated using Weblate (Swedish)
Currently translated at 100.0% (1460 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sv/

Translated using Weblate (Swedish)

Currently translated at 99.9% (1459 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sv/
2024-11-13 08:09:13 +01:00
김인수
db5ccb0585 Translated using Weblate (Korean)
Currently translated at 100.0% (1460 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/
2024-11-13 08:09:13 +01:00
Andi Chandler
47518b136a Translated using Weblate (English (United Kingdom))
Currently translated at 100.0% (1460 of 1460 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/en_GB/
2024-11-13 08:09:13 +01:00
Weblate
145a476df2 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2024-11-13 08:09:13 +01:00
Pavel Hrdina
1f8c61cddc ci: update .packit.yaml to use meson
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-11-12 23:18:32 +01:00
Pavel Hrdina
c385cd4eb7 ci: update github workflows to use meson
Running `meson dist` requires working git but that doesn't seem to be the
default in github actions when running jobs inside container. Any git
invocation fails with the following error:

fatal: detected dubious ownership in repository at '/__w/virt-manager/virt-manager'
To add an exception for this directory, call:

	git config --global --add safe.directory /__w/virt-manager/virt-manager

So that's what this patch does to make `meson dist` work correctly.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-11-12 23:18:32 +01:00
Pavel Hrdina
cbd2a7ef92 update setup.py usage and docs to meson
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-11-12 23:18:32 +01:00
Pavel Hrdina
31cb321909 remove remaining setuptools files
We will no longer have `rpm` target with meson. That should not be an
issue as users can run `meson dist -C build` and
`rpmbuild -tb build/meson-dist/virt-manager-{version}.tar.xz`.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-11-12 23:18:32 +01:00
Pavel Hrdina
5f34dea0ed meson: add tests
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-11-12 23:18:32 +01:00
Pavel Hrdina
f41deedd52 meson: add build config and its options
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-11-12 23:18:32 +01:00
Pavel Hrdina
54aadf0169 meson: add icons and schemas options
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-11-12 23:18:32 +01:00
Pavel Hrdina
0f9d89e069 meson: build and install bin wrappers
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-11-12 23:18:32 +01:00
Pavel Hrdina
01acaa3836 meson: add po files
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-11-12 23:18:32 +01:00
Pavel Hrdina
3247dab74c meson: add virtManager files
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-11-12 23:18:32 +01:00
Pavel Hrdina
03e35a7c29 meson: add virtinst files
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-11-12 23:18:32 +01:00
Pavel Hrdina
ff1fa4cc38 meson: add ui files
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-11-12 23:18:32 +01:00
Pavel Hrdina
2abd3e7565 meson: add icons
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-11-12 23:18:32 +01:00
Pavel Hrdina
dd909f20bc meson: add data files
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-11-12 23:18:32 +01:00
Pavel Hrdina
6a462a3f60 meson: add man pages
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-11-12 23:18:32 +01:00
Pavel Hrdina
1f80a62239 meson: rename and modify spec file
We will create the final spec file by meson to have virt-manager version
in single place.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-11-12 23:18:32 +01:00
Pavel Hrdina
d803491c47 introduce meson.build file
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-11-12 23:18:32 +01:00
Cole Robinson
0755711372 tests: uitests: cover cli changes
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-12 23:12:36 +01:00
Cole Robinson
408a39a777 virt-manager: Switch to --no-fork by default
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>
2024-11-12 23:12:36 +01:00
Cole Robinson
028fdf2c35 man: virt-manager: document fork behavior and VIRT_MANAGER_DEFAULT_FORK
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-12 23:12:36 +01:00
Cole Robinson
5de632700f virt-manager: add VIRT_MANAGER_DEFAULT_FORK=yes|no env variable
Allows users to choose default fork behavior via an environment
variable.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-12 23:12:36 +01:00
Cole Robinson
7ff899b85e virt-manager: Add --fork option
This is a no-op for now, since this is already the default behavior

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-12 23:12:36 +01:00
Cole Robinson
17e39de021 virt-manager: Set SSH_ASKPASS_REQUIRE=force
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>
2024-11-12 23:12:36 +01:00
Pino Toscano
6c9842a158 ci: tweak Packit configuration
- drop all the architectures (and thus building only on x86_64):
  virt-manager has no architecture-specific installation bits, and thus
  it builds in the same way on every architecture; hence no need to
  explicitly test on various architectures
- test on all the supported Fedora versions (Rawhide included): this way
  it is possible to check that older versions are still supported, at
  least when building

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2024-11-12 22:37:39 +01:00
Pino Toscano
d46674b822 fix: improve translatable message
- use a single translatable message, instead of splitting the text in
  two; it helps translators to have the full context/text
- improve the language a bit

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2024-11-12 22:36:00 +01:00
Pavel Hrdina
5126c007ec tests: update tests to reflect the latest panic device changes
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-11-12 19:15:04 +01:00
Pavel Hrdina
2ce04b7cf6 virtinst.cli: replace DevicePanic.MODEL_ISA with "isa"
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-11-12 19:14:51 +01:00
Cole Robinson
48ec63cce2 tests: uitests: tweak for panic dev changes
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-12 09:57:47 -05:00
Cole Robinson
c5a4664676 addhardware: panic: default to asking libvirt for default model
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>
2024-11-12 09:55:20 -05:00
Cole Robinson
ebeb80073e devices: panic: let libvirt fill in model default
Currently `--panic default` for aarch64 doesn't even request
a `<panic/>` device due to quirky xmlbuilder behavior. Fix that,
but more generally just leave model empty and let libvirt fill it
in for us.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-12 09:44:37 -05:00
Cole Robinson
afa8231525 virt-install: add --network hostdev=HOSTDEV
This is a special convenience option for filling in `type=hostdev`
config using the same format of lookup string that can be
passed to `--hostdev`

Fixes: https://github.com/virt-manager/virt-manager/issues/500

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-11 15:30:25 -05:00
Cole Robinson
300f934cae virt-install: add --network type=hostdev,source.address.X= pci options
This just covers the common PCI case with these new options

source.address.type=
source.address.domain=
source.address.bus=
source.address.slot=
source.address.function=

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-11 14:26:47 -05:00
Cole Robinson
315b340fc4 virt-install: add --features msrs.unknown=ignore
Fixes: https://github.com/virt-manager/virt-manager/issues/570

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-11 14:13:59 -05:00
Cole Robinson
7dd7383bcb tests: uitests: cover serial autoconnect bug fix
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-11 14:06:42 -05:00
Cole Robinson
dc1c998265 console: Handle autoconnect=off for serial console too
Fixes: https://github.com/virt-manager/virt-manager/issues/584

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-11 14:06:42 -05:00
Cole Robinson
97ab16a73d uitests: fix coverage with scaling default change
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-11 14:55:26 +01:00
Cole Robinson
715acbf541 console: Default to scaling=Always
I think this is a better default than the current `Only when
Fullscreen`, which is the same as `Never` for VM windowed mode.

I wrote my reasoning here:
https://github.com/virt-manager/virt-manager/issues/747

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-11-11 14:55:26 +01:00
Jose
5875019b2d Update installertreemedia.py
Removing duplicated verb "be"
2024-11-11 14:27:22 +01:00
Grzegorz Szymaszek
c99b64725c man: update libvirt.org links
Fix no longer valid URL fragments, wrap at 80th column, remove dots that
follow only a few links.

Signed-off-by: Grzegorz Szymaszek <gszymaszek@short.pl>
2024-10-29 07:57:56 +01:00
Cole Robinson
8f75ac4e6e virt-install: implement --osinfo require=no as fallback name=generic
This is essentially what it has always behaved as, but making it
explicit in the code will now trigger the extra warnings when
detect=on is also used.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-14 15:21:15 +02:00
Cole Robinson
e02607766c virt-install: Warn if --osinfo detect=on,name=OSNAME detection fails
Using `detect=on,name=OSNAME` is good for CI safety, incase
a new distro tree has a regression with detection, or if testing
against a new distro that osinfo-db doesn't know about.

But virt-install should still try to inform the user that detection
failed, and suggest filing a bug if the user expected it to work.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-14 15:21:15 +02:00
Cole Robinson
e3da4337f6 cli: --osinfo detect=on shouldn't default to require=off
The require= behavior should be AUTO for this case, but the
way we were previously initializing variables made this OFF.
I don't think this was intentional. We should have changed
this when we started defaulting to `detect=on`

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-14 15:21:15 +02:00
Cole Robinson
1487dbd200 cli: --osinfo: clean up require= handling
It's kinda hard to follow the logic here. cli require= can only be
on|off or unset, but we use an internal 'auto' value which seems
like it can come from the cli.

Try to clean it up with enum like values.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-14 15:21:15 +02:00
Cole Robinson
a28401cb12 tests: Test that --osinfo detect=on implies require=off
This is current behavior, but it was unintentional and we will
change it.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-14 15:21:15 +02:00
Pavel Hrdina
3006c5a1d5 virtManager: drop libappindicator usage
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>
2024-10-14 08:51:07 +02:00
Pavel Hrdina
31eab9b46a pylint: fix false positive errors
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-10-13 17:11:06 +02:00
Pavel Hrdina
d4194c134b misc: codespell fixes
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-10-13 15:26:08 +02:00
Cole Robinson
a9a78f45cf installer: rename has_install_phase to requires_postboot_xml_changes
has_install_phase is an ambiguous name for its intended purpose.
Really this is so API users have a way of knowing if the VM `install`
process requires 2 XML phases or not. Make that naming explicit

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-11 14:40:03 +02:00
Cole Robinson
1c8e6f8428 virt-install: Make --cloud-init reboot by default (again)
This basically reverts this commit from virt-manager 4.0.0

```
commit 825ec644b859b99d6f9f155b04ef3ac07eca1fc2
Author: Cole Robinson <crobinso@redhat.com>
Date:   Tue Mar 1 10:32:01 2022 -0500

    installer: Do not force reboot with --cloud-init

    Resolves: https://github.com/virt-manager/virt-manager/issues/189
```

After that commit, using `--cloud-init` or `--unattended` would
basically imply `--noreboot`

For some usage of `--cloud-init`, like in the initial report, this
makes sense to do. virt-install will drop you into the cloud image,
you mess without, run `poweroff`, and are surprised when virt-install
reboots the VM. I agreed, and made the change

But changing this was a bad idea.

cloud-init and unattended VMs have 2 XML phases. First XML is booting
off temporary media (the generated cloudinit iso), second XML is the
permanent boot config (booting off disk). We need to force the VM
to fully poweroff, so that the second XML config takes effect. We
make that happen with `<on_reboot>destroy</on_reboot>`, which tells
libvirt/qemu to poweroff the VM when it receives a guest reboot
notification. virt-install then defaults to restarting the VM when
it detects shutdown, to manually replicate the VM requested reboot,
but still get the second XML config to take effect.

The perennial problem with this is that, from outside the VM, we
don't know if the user inside the VM requested `poweroff` or `reboot`.
virt-install emulates the reboot behavior, and provides `--noreboot`
to override it. It's still confusing if a user puts a `poweroff`
command at the end of an anaconda kickstart file, and sees the VM
reboot, but it's been that way forever.

Except with that commit above, we flipped it for --cloud-init and
--unattended. Now, users who do `poweroff` are getting expected
behavior, but users who request `reboot` are not.

We could go further and add a `--yesreboot` option or similar. But
for consistency sake I think we should just revert that behavior,
and tell users to use --noreboot like usual.

Resolves: https://github.com/virt-manager/virt-manager/issues/497

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-11 14:40:03 +02:00
Cole Robinson
351233f8ec vmwindow: Default new window viewer size to 1280x800
This is qemu's default nowadays for modern video configs

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-10 11:21:56 -04:00
Cole Robinson
d231e66a96 console: Fix resize_to_vm with host fractional scaling
Trying to size the window based on VM desktop resolution does
not do the correct thing when host fractional scaling is enabled
and using spice.

The best we can do here is ask the viewer widget for its
preferred size

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-10 11:15:35 -04:00
Cole Robinson
2ee224193d console: drop manual size request, let widgets do it for us
_adjust_viewer_size has one remaining function: when scaling and
resizeguest is disabled, do
viewer.set_size_request(*desktop_resolution), so the viewer fills
out the scrolled window and scrollbars show up.

After playing with this all a bunch, I discovered two things

* spice already behaves the way we want, so we don't need to
  manually intervene. so all that is unnecessary
* vnc has an option to behave the way we want, via the
  set_force_size knob

So instead lets rip it all out, and implement the VNC piece by
toggling set_force_size based on whether scaling+resizeguest is
enabled.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-10 11:15:35 -04:00
Cole Robinson
1d7fcac3df viewers: simplify shared self._display handling
* Move shared init to `_set_display`
* Move per class init to `_init_display`
* Move per class signal setup to `_connect_display_signals`
* Make base class call cleanup of child class via `_close`
* Drop unnecessary spice `_display_channel` handle

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-10 11:15:35 -04:00
Cole Robinson
7e79023b09 viewers: Share most of _refresh_grab_keys implementation
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-10 11:15:35 -04:00
Cole Robinson
51c3f1c687 virt-xml: Add --edit --convert-to-vnc
This wires up the guest.convert_to_vnc function to command line,
and documents it.

There's one suboption `qemu-vdagent=on|off`, defaulting to `off`

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-09 11:03:43 +02:00
Cole Robinson
f7988a94e6 guest: convert_to_vnc: optionally add qemu-vdagent
Disabled by default, but maybe we turn it on in the future
when qemu-vdagent supports migration.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-09 11:03:43 +02:00
Cole Robinson
d58299ee6b guest: convert_to_vnc: convert video device
This is mostly about stripping out spice references. All qxl devices
are converted to app defaults

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-09 11:03:43 +02:00
Cole Robinson
f0078a179d guest: remove spiceport devices when spice is removed
serial/console type='spiceport' is another spice specific device,
so remove that too

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-09 11:03:43 +02:00
Cole Robinson
229b905053 guest: add convert_to_vnc()
This is the beginnings of support for a `virt-xml --convert-to-vnc`
option. Take an existing VM, strip out most of the previous graphics
config, and add VNC graphics.

We try to convert over some of the shared graphic bits, like listen
and port settings, if they were previously specified.

If spice GL was enabled, we convert to egl-headless config

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-09 11:03:43 +02:00
Cole Robinson
c498c519ed virt-install: Exit gracefully when VM is undefined behind our back
We still error, but don't throw a traceback.

Resolves: #455

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-08 13:40:30 -04:00
Cole Robinson
dd354e8b72 virt-xml: add --edit --convert-to-q35
Wire up guest.convert_to_q35 to the CLI. We add one suboptions,
`num_pcie_root_ports=X`, matching the pre-existing
`--controller num_pcie_root_ports=X` option

Nothing fancy here. See man page docs for details

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-03 14:20:12 -04:00
Cole Robinson
454aad78a4 guest: add convert_to_q35
This function converts a PC/i400FX XML config to Q35. Mostly
this is deleting any plain PCI addresses and controllers, adding
pcie-root-ports, convert IDE -> SATA, and let libvirt fill in
the rest.

This the implementation piece. CLI additions come later

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-03 14:20:12 -04:00
Cole Robinson
fe09e8f47e viewers: add explicit signal for desktop resize
this doesn't change any behavior, but it makes things cleaner
by not overloading the size-allocate signal

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-02 13:34:47 -04:00
Cole Robinson
f140ff1836 console: drop the scroll size-allocate callback
This does not seem to be required anymore. We get notified on
viewer size-allocate already, which seems like enough.

Rename the function to _adjust_viewer_size which is more accurate
to what it does, and adjust the callers

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-02 13:34:47 -04:00
Cole Robinson
e5208adc32 console: drop the console_size_allocate call
This mattered when we were doing widget adjustments to maintain
scaling ratio. But nowadays it seems totally redundant: we are
basically trying to set an allocation that already happened via
the normal chain of widget events, so it's a no-op.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-02 13:34:47 -04:00
Cole Robinson
24324bb6f5 console: Leave scroll policy as AUTOMATIC
We shouldn't need to forcibly set it to NEVER. It doesn't seem to
be required in my testing

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-02 13:34:47 -04:00
Cole Robinson
95006f42ba console: Clean up get_desktop_resolution usage
Checking for resolution = None is a roundabout way to check if
the console was already opened. Make that more clear

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-02 13:34:47 -04:00
Cole Robinson
371cd1ad60 console: Simplify usbredir menu handling
+ Don't check for redirdev devices, let the spice widget tell
  us if things aren't configured correctly.

+ Remove some duplication

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-02 13:34:47 -04:00
Cole Robinson
4cc52de8bb console: Fix widget size with scaling=never and host fractional scaling
We can not reliably use VM desktop resolution for host widget
sizes when the host is using desktop scaling, so don't even try.

This fixes the black bars around the VM console when scaling=never
and autoresize is disabled

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-02 13:34:47 -04:00
Cole Robinson
6b944ef6b8 console: Add a comment about _set_size_to_vm and fractional scaling
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-02 13:34:47 -04:00
Cole Robinson
bd0d0920ec console: Add logging to _set_size_to_vm
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-02 13:34:47 -04:00
Cole Robinson
dfb1f33040 connection: handle disappearing obj in agent handler
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-02 12:35:05 -04:00
Cole Robinson
2ee2dda124 virt-xml: Fix cli_arg_name vs cli_flag_name() usage
Most of the time these strings are the same, but not when
a command line argument has a dash in it

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-01 12:30:34 -04:00
Cole Robinson
f66cca92a9 cli: Make --xml option parsing less special
We can make `--xml` fit the common xml cli option paradigm, which
less us drop a whole bunch of special handling in virt-xml

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-01 12:30:34 -04:00
Cole Robinson
76f4599460 virtxml: Don't require options at XML action time
Adjust cli.py `run_parser` and similar functions to take the
parservalue directly, rather than passing in the whole `options`
structure.

This makes it easier to reason about what the virt-xml action
functions are actually working with.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-01 12:30:34 -04:00
Cole Robinson
455b38f724 virtxml: Add Action class to track action + option pairs
This adds an Action class which is a container for (most) of the
data we need to perform a virt-xml operation. Basically an instance
of the class represents a pairing like

    --edit 1 --disk path=/foo    or
    --add-device --network wibble,model=virtio
    etc

This is a functional no-op, but it moves the code closer to
an architecture that will allow us to perform multiple actions
with a single virt-xml command.

While doing this, we centralize most of the cli validation that is
scattered around, since it's now easier to do it in one place.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-01 12:30:34 -04:00
Cole Robinson
b7c72af73d virtxml: move some functions
Move the validation functions out from amongst the functional XML
editing code, and into their own section. We will be adding more
code alongside in future patches.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-10-01 12:30:34 -04:00
Cole Robinson
4941bb922f testmock: Remove some console mocking that's no longer required
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-26 09:19:57 -04:00
Cole Robinson
2c9f219450 console: Remove needless console scale comparison
This doesn't seem to serve any purpose

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-26 09:19:57 -04:00
Cole Robinson
babeb1516f console: Cleanup _scroll_size_allocate
Remove some duplication and make the remaining functionality
more clear. This should be a no-op

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-25 16:39:20 -04:00
Cole Robinson
8e551f514a console: Remove our custom aspect ratio handling
Spice has maintained aspect ratio for us forever.
GtkVnc was added in previous commit, provided since May 2021.

If user is running on an old GtkVnc, they just get potentially
stretched out viewing when scaling is enabled, so the fallback
scenario is no big deal IMO

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-25 16:39:20 -04:00
Cole Robinson
9929f2d676 vmwindow: Disable 'Resize to VM' menu when VM is offline
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-25 16:39:20 -04:00
Cole Robinson
20000fb313 vmwindow: Don't desensitive Auto resize
Right now you can select the option for an offline VM, but once
it starts up, and no spice agent is detected, the option is
set insensitive. This is a pain.

Keep the tooltip, but keep the option always selectable

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-25 16:39:20 -04:00
Cole Robinson
289a993af4 viewers: spice: hook into display-primary-create
We can use this signal to be notified when VM resolution changes.

Log when we actually detect a resolution change

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-25 16:39:20 -04:00
Cole Robinson
70861c507e viewers: vnc: use set_keep_aspect_ratio(True)
Maintains aspect ratio when scaling.

Added by v1.2.0 in March 2021

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-25 11:07:16 -04:00
Cole Robinson
3ee677c2de viewers: Log once when checking vnc set_allow_resize support
For debugging purposes. But we will use this pattern in upcoming
patches too

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-25 11:03:29 -04:00
Cole Robinson
d79d4633c8 snapshots: Don't save outdated screenshot data
Current code will take a screenshot when the 'New Snapshot'
dialog is initially launched, and then use that cached content
as the screenshot for the snapshot... which may be totally out
of date by the time the user enters all the snapshot info.

Instead, drop the snapshot preview UI in the 'New Snapshot' wizard
entirely, and use a screenshot that is fetched after the user actually
clicks 'Finish'

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-25 10:18:38 +02:00
Cole Robinson
1f448a1953 virt-manager: Stop blocking SIGHUP
This is from when we used to support directly connecting to
serial console /dev/pty devices. Nowadays all serial connections
are mediated through libvirt stream APIs and we don't need to
care about SIGHUP

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-24 12:42:42 -04:00
Cole Robinson
683b486c46 ui: snapshots: Fix button placement when resizing 'New' dialog
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-23 19:31:36 -04:00
Cole Robinson
de00ff7661 virt-xml: Fix --define with stdin XML
And rework the `refresh-machine-type` testcase to trigger it

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-23 10:37:16 -04:00
Cole Robinson
b83a1b0d0f domain: Use KEEP_TPM flag for domain rename
If the VM has implicit TPM state, use the VIR_DOMAIN_UNDEFINE_KEEP_TPM
flag to preserve that state when renaming the VM (if libvirt is new
enough).

The state is stored based on VM UUID and nothing else, and the UUID
is preserved during rename, so we don't need to do any of the same
trickery that's required for nvram duplication.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-19 05:48:01 +02:00
Cole Robinson
c6bc3a8667 tests: uitests: test localhost tcp graphics
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-11 12:17:06 -04:00
Sami Loone
380af310e7 console: allow localhost connections over TCP
Fix console config validation for an edge case where both libvirt and
Spice/VNC TCP connection are on localhost. Transport over TCP does not
necessarily mean that libvirt connection is to a remote host.

Compare libvirt and graphics device addresses to localhost individually.
Raise an error only when guest device is bound to localhost but libvirt
connection is non-local (remote).

Validation that prevents fully local TCP seems to go back all the way to
bc13c302de4 ("console: Warn if qemu+tcp URI and listen == 127.0.0.1").

Signed-off-by: Sami Loone <sloone@forcepoint.com>
2024-09-11 12:16:33 -04:00
Cole Robinson
258df88eab domain: tweak q35 <-> pc editing
* add_q35_pcie_controllers already skips adding controllers if
  any type=pci already exist, so delete the extra checking
* be more paranoid and only run the live edits when the machine
  type actually changed from an expected config

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-10 16:35:03 -04:00
Lin Ma
78064728e6 domain: Remove the pcie-root and ports for i440fx in customized dialog
The commit db8305ad explicitly adds pcie-root and pcie root ports for q35.
If the user selects i440FX chipset instead of Q35(default) from customize
dialog, The pre-defined pcie-root and ports cause failure when starting
i440fx VM installation because they're not applicable to i440fx.

It fails with below error message:

summary=Unable to complete install: 'XML error: The PCI controller with index='0'
must be model='pci-root' for this machine type, but model='pcie-root' was found instead'
details=Traceback (most recent call last):
  File "/usr/share/virt-manager/virtManager/asyncjob.py", line 72, in cb_wrapper
    callback(asyncjob, *args, **kwargs)
  File "/usr/share/virt-manager/virtManager/createvm.py", line 2088, in _do_async_install
    installer.start_install(guest, meter=meter)
  File "/usr/share/virt-manager/virtinst/install/installer.py", line 737, in start_install
    domain = self._create_guest(
  File "/usr/share/virt-manager/virtinst/install/installer.py", line 679, in _create_guest
    domain = self.conn.createXML(initial_xml or final_xml, 0)
  File "/usr/lib64/python3.10/site-packages/libvirt.py", line 4442, in createXML
    raise libvirtError('virDomainCreateXML() failed')
libvirt.libvirtError: XML error: The PCI controller with index='0' must be
model='pci-root' for this machine type, but model='pcie-root' was found instead

This patch fixes it by removing the pcie-root and ports for i440fx in
apply_overview.

Resolves: https://github.com/virt-manager/virt-manager/issues/444

Signed-off-by: Lin Ma <lma@suse.com>
2024-09-10 13:27:08 -04:00
Lin Ma
2d94e92d80 guest: Drop the '_' prefix for _add_q35_pcie_controllers
We will use it in domain.py as well.

Signed-off-by: Lin Ma <lma@suse.com>
2024-09-10 13:27:08 -04:00
Cole Robinson
9813dc3b4f capabilities: Exclude a line from code coverage
updated test suite capabilities XML doesn't hit this line anymore.
Just exclude it

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-10 13:13:46 -04:00
Andrea Bolognani
e1468c04aa tests: Add testDomainCapabilitiesLoongArch64()
Inspired by the x86_64 counterpart.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2024-09-10 12:56:38 -04:00
Andrea Bolognani
2a52d77096 domcapabilities: Add firmware patterns for loongarch64
Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2024-09-10 12:56:38 -04:00
Andrea Bolognani
5419524f7b tests: Add testDomainCapabilitiesRISCV64()
Inspired by the x86_64 counterpart.

We're using TCG in this case, so things like host-passthrough
are not available.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2024-09-10 12:56:38 -04:00
Andrea Bolognani
dc603792bf domcapabilities: Add firmware patterns for riscv64
Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2024-09-10 12:54:35 -04:00
Andrea Bolognani
cf0b6cd78f tests: Add testDomainCapabilitiesPPC64le()
Inspired by the x86_64 counterpart.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2024-09-10 12:53:36 -04:00
Andrea Bolognani
01a451e7d9 tests: Update ppc64le capabilities
The old capabilities are extremely outdated. The new ones were
captured on an IBM POWER8 machine running Fedora 40.

A few new features are advertised, and the details of the
machine are significantly different, but not much of this is
reflected in the output XML files.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2024-09-10 12:53:36 -04:00
Andrea Bolognani
5d5da5ff6e domcapabilities: Update comment
Fedora uses the same paths as Gerd's packages these days.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2024-09-10 10:54:53 +02:00
Andrea Bolognani
579eb3e91e tests: Extend testDomainCapabilitiesAArch64()
Bring it closer to the x86_64 counterpart.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2024-09-10 10:54:53 +02:00
Andrea Bolognani
38906948c6 tests: Update aarch64 capabilities
The old capabilities are extremely outdated. The new ones were
captured on an Ampere Mt. Jade machine running Fedora 40.

Notable differences that are reflected in the output XML files
include the availability of SPICE, as well as EFI firmware and
ACPI support being advertised.

The test script had to be updated too, since both virtiofs and
memfd are now available.

Closes: #714

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2024-09-10 10:54:53 +02:00
Cole Robinson
07ae6da38a domain: don't attempt to predict if VM supports snapshots
internal snapshots largely only work if the VM is backed by a single
qcow2 disk. But newly supported external snapshots support other
disk formats, and multiple disks.

Drop the old validation checking. Let's just leave it up to libvirt
to give us an error at snapshot creation time

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-10 10:27:29 +02:00
Cole Robinson
e412ecf1f7 domain: log object XML after snapshot creation
Libvirt fills in a lot of XML bits automatically, it's helpful
to see the final result in the logs

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-10 10:27:29 +02:00
Lin Ma
4782dd1cce cli: Add --disk driver.discard_no_unref=on|off
E.g.
  virt-install \
  ... \
  --disk /tmp/disk0.qcow2,size=16,driver.type=qcow2,driver.discard=unmap,\
  driver.discard_no_unref=on

It results in the following domain xml:
    <disk type='file' device='disk'>
      <driver name='qemu' type='qcow2' discard='unmap' discard_no_unref='on'/>
      <source file='/tmp/disk0.qcow2'/>
      <target dev='vda' bus='virtio'/>
    </disk>

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Lin Ma <lma@suse.de>
2024-09-08 11:25:32 -04:00
Lin Ma
6a65def684 cli: Add --video model.blob=on|off
Libvirt enables blob resources for the virtio video device since 9.2.0.
It accelerates the display path due to less or no copying of pixel data.

E.g.
  virt-install \
  ... \
  --video model.type=virtio,blob=on

It results in the following domain xml:

    <video>
      <model type="virtio" blob="on"/>
    </video>

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Lin Ma <lma@suse.de>
2024-09-08 11:25:32 -04:00
Lin Ma
febddd4b01 cli: Add --memdev target.address_base for virtio-mem and virtio-pmem
Libvirt(since 9.4.0) allows to control this attribute for virtio-{mem,pmem}.
Now add it into virt-install.

Example:
virt-install \
--name test \
--os-variant opensusetumbleweed \
--cdrom /isos/openSUSE-Tumbleweed-DVD-x86_64-Current.iso \
--disk /vms/tw/disk0.qcow2 \
--vcpu 2 \
--cpu cell0.cpus=0,cell0.memory=4194304,\
cell1.cpus=1,cell1.memory=4194304 \
--memory maxMemory=65536,maxMemory.slots=8 \
--memdev model=virtio-mem,\
target.node=0,\
target.block=2048,\
target.size=8192,\
target.requested=2097152,\
target.address_base=0x280000000 \
--memdev model=virtio-pmem,\
source.path=/tmp/virtio_pmem,\
target.size=4096,\
target.address_base=0x480000000

It results in the following domain XML snippet:
    <memory model='virtio-mem'>
      <target>
        <size unit='KiB'>8388608</size>
        <node>0</node>
        <block unit='KiB'>2048</block>
        <requested unit='KiB'>2097152</requested>
        <current unit='KiB'>0</current>
        <address base='0x280000000'/>
      </target>
      <alias name='virtiomem0'/>
      <address type='pci' domain='0x0000' bus='0x07' slot='0x00' function='0x0'/>
    </memory>
    <memory model='virtio-pmem' access='shared'>
      <source>
        <path>/tmp/virtio_pmem</path>
      </source>
      <target>
        <size unit='KiB'>2097152</size>
        <address base='0x480000000'/>
      </target>
      <alias name='virtiopmem0'/>
      <address type='pci' domain='0x0000' bus='0x08' slot='0x00' function='0x0'/>
    </memory>

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Lin Ma <lma@suse.de>
2024-09-08 11:25:32 -04:00
Lin Ma
7a974a3a72 cli: Add --features kvm.pv-ipi.state=on|off
Set kvm pv-ipi feature by --features argument.

E.g. virt-install --features kvm.pv-ipi.state=off
It results in the following domain xml:

 <features>
   <kvm>
     <pv-ipi state='off'/>
   </kvm>
 </features>

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Lin Ma <lma@suse.de>
2024-09-08 11:25:32 -04:00
Lin Ma
63f8f78e6b tests: Check missing_xorriso in osinfo-netinst-unattended test case
It avoids failure in case of missing xorriso.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Lin Ma <lma@suse.de>
2024-09-08 11:23:22 -04:00
Cole Robinson
9ec9c400f4 tests: add fake-win-multi.iso and test it
This has ambiguous volume labels that will match multiple
osinfo output:

$ osinfo-detect -a tests/data/fakemedia/fake-win-multi.iso
Media is bootable.

Generated by editing `fake-win7.iso` already in tree

$ xorriso -indev fake-win7.iso -outdev test.iso \
    -boot_image isolinux keep \
    -volid SSS_X64CHK_ -volset_id SSS_X64CHK_

Add a simple test case that confirms _some_ os was detected,
and virt-install doesn't totally choke on it

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-07 14:34:43 -04:00
Cole Robinson
f4a9722dc6 uitests: cover serial console changes
+ Drop test_livetests bit which was working around the old behavior
+ Add test_details piece that covers the new behavior, and
  ideal behavior that we maintain the selection across VM restarts.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-07 13:38:42 -04:00
Cole Robinson
6264167cc1 serialcon: Don't disable console menu items for offline VM
Currently, View->Consoles disables the menu items for serial devices
when the VM is offline. This changes that behavior. This is useful,
since it allows you to pre-select serial console before starting the
VM, which can help ensure you don't miss any serial boot output.
It also makes the UI interaction more intuitive.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-07 13:38:42 -04:00
Cole Robinson
2293ec49b2 console: Handle inactive VM when console menu selection changes
Reproducer:
+ Start VM with 1 graphical and 1 serial console
+ Select serial console
+ Power off VM
+ Open console menu, select 'Graphical' option
+ See errors

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-07 13:30:47 -04:00
Cole Robinson
a58223baf9 addhardware: Only set channel clipboard XML if UI is visible
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-07 13:23:38 -04:00
Cole Robinson
adc1948e7b details: only refresh os page if its currently selected
Reproducer:
+ Enable libguestfs inspection
+ Open app and VM details 'Overview' window
+ After some time, the `Apply` button is mysteriously activated
+ Trying to switch away from the page will give 'Unapplied errors'
  warning box

When libguestfs inspection completes, it triggers a signal which
will refresh the OS info details.py page. Which is fine, but we
should be limiting it to only refreshing the page if its the currently
visible one. Otherwise the `Apply` button can be activated, which
messages up app navigation

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-07 13:20:40 -04:00
Cole Robinson
e1798ef8ad Add missing test file
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-06 15:32:04 -04:00
Cole Robinson
83daac0489 domain: os: treat xenpvh as xen PV
Notably, don't try to add a tablet device, this apparently
doesn't work.

https://github.com/virt-manager/virt-manager/issues/448

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-06 15:30:51 -04:00
Cole Robinson
65d568ebf9 Scrub references to virt-tools-list
* Remove .gitpublish, we only use github for patches now
* Drop author* fields entirely from setuptools, that seems fine.
* Drop other references

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-06 15:10:04 -04:00
Cole Robinson
9ad347fd76 tests: test XML generation for --disk path=file://...
Tweak the test case added in ba3a098c3b82d0dcf36198e67ae3bcd6ad7c6d4a
to test XML generation instead, to make sure nothing regresses
weirdly there.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-09-06 14:54:09 -04:00
Pavel Hrdina
67206a858a tests: add more test cases to cover all code paths
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-09-06 14:15:09 -04:00
Pavel Hrdina
74fd503b9e virtinst: enable most Hyper-V features by default
We will not enable hyperv_reset feature as modern Hyper-V versions don't
export it.

We also don't enable hyperv_reenlightenment as it is mostly relevant
when migrating VMs that are running Hyper-V inside and requires other
bits to work correctly.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-09-06 14:15:09 -04:00
Pavel Hrdina
169db9dc5f virtinst.support: drop unused conn_hyperv_vapic function
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-09-06 14:15:09 -04:00
Pavel Hrdina
9e9dbf735c domain.features: use domcapabilities when setting default Hyper-V features
We will no longer enable hyperv features based on libvirt and QEMU
versions.

Some tests don't use the kvm-x86_64-domcaps-latest so the code will now
not enable Hyper-V features. There are still other test cases that cover
Hyper-V features so instead of mangling with URI for these tests update
test data.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-09-06 14:15:09 -04:00
Pavel Hrdina
66bbfa23b2 domain.features: extract setting default hyperv features
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-09-06 14:15:09 -04:00
Pavel Hrdina
c279c17e6c domcapabilities: get list of supported Hyper-V features
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-09-06 14:15:09 -04:00
Pavel Hrdina
bec2d7cb44 tests: update kvm-x86_64-domcaps-latest
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-09-06 14:15:09 -04:00
Pavel Hrdina
139b0e285b cli: add --features hyperv.avic.state=on/off
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-09-06 14:15:09 -04:00
Pavel Hrdina
a06d53596b cli: add --features hyperv.evmcs.state=on/off
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-09-06 14:15:09 -04:00
Pavel Hrdina
5afc6919c9 cli: add --features hyperv.ipi.state=on/off
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-09-06 14:15:09 -04:00
Pavel Hrdina
e3ec248cff cli: add --features hyperv.tblflush.state=on/off
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-09-06 14:15:09 -04:00
Pavel Hrdina
c421ec1b75 cli: add --features hyperv.reenlightenment.state=on/off
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-09-06 14:15:09 -04:00
Pavel Hrdina
2786ea5df2 cli: add --features hyperv.frequencies.state=on/off
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-09-06 14:15:09 -04:00
Pavel Hrdina
6289a1369b cli: add --features hyperv.stimer.direct.state=on/off
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-09-06 14:15:09 -04:00
Pavel Hrdina
1f69795b0a cli: add --features hyperv.stimer.state=on/off
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-09-06 14:15:09 -04:00
Pavel Hrdina
d7976a883a cli: add --features hyperv.runtime.state=on/off
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-09-06 14:15:09 -04:00
Pavel Hrdina
d2a29245cd cli: add --features hyperv.vpindex.state=on/off
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-09-06 14:15:09 -04:00
Pavel Hrdina
1c3fb02543 test_cli: extract hyperv features to separate lines
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-09-06 14:15:09 -04:00
Pavel Hrdina
ac26945c56 domain.features: reorder Hyper-V features
Follow the table from libvirt documentation [1].

[1] <https://libvirt.org/formatdomain.html#hypervisor-features>

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-09-06 14:15:09 -04:00
Cole Robinson
2da4884962 tests: Cover some weird virt-xml corner case behaviors
Examples:

`virt-xml MYVM --add-device --sound FOO1 --sound FOO2` is not rejected
and will add 2 devices.

`virt-xml MYVM --remove-device --sound opt1=FOO1 --sound opt2=FOO2`
is not rejected, only the final `--sound` option is used.

`virt-xml MYVM --edit --sound FOO1 --sound address.type=BAR` is not
rejected. The commandlines will effectively be squashed

`--sound` can be any XML option, but trying to mix and match
options like `--sound` and `--disk` is always rejected.

These bits are unexpected and undocument, but have been around since
the beginning of virt-xml.

I can see us breaking compat on these in the future (particularly the
--remove-device bit), but that would need to be an explicit decision,
and announced appropriately. In the mean time, we should be testing
this so it doesn't accidentally regress.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-08-28 21:09:31 +02:00
Cole Robinson
7e79e064ea Revert virt-xml multiple --edit support
This reverts b34ae0d0c883972d74deef6cdadb29bdd1bbe487 and
1fef5d8661118a4f00a8689b323d275144b39dbe.

Playing with this some more I found some deeper problems. For example

```console
[:~/src/virt-manager] (main) $ ./virt-xml test-for-virtxml --connect test://`pwd`/tests/data/testdriver/testsuite.xml --print-diff --edit 1 --video model=FOO --edit 2 --sound model=BAR
--- Original XML
+++ Altered XML
@@ -180,14 +180,14 @@
     <graphics type="vnc" port="-1" autoport="yes">
       <listen type="address"/>
     </graphics>
-    <sound model="sb16"/>
+    <sound model="BAR"/>
     <sound model="es1370"/>
     <sound model="ich6"/>
     <video>
       <model type="vmvga" vram="16384" heads="1" primary="yes"/>
     </video>
     <video>
-      <model type="cirrus" vram="16384" heads="3"/>
+      <model type="FOO" vram="16384" heads="3"/>
     </video>
     <hostdev mode="subsystem" type="usb" managed="yes">
       <source>
```

There's other weirdness too, though it's mostly strange plays on previous weird behavior

* `--edit --video model=vga --edit --sound model=ich9 --video model=qxl` works
* `--add-device --sound model=foo --video model=bar` was previously rejected but now works
* `--remove-device --video model=vmvga --sound model=sb16` was previously rejected by now works

Fixing all this is not trivial. So I think we need to revert and go back to the drawing board.
2024-08-28 21:09:31 +02:00
Cole Robinson
5fe6dcc6b4 Fix some pylint
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-08-28 11:53:35 -04:00
Daniel P. Berrangé
97469abd8e tests: add tests for AMD SEV-SNP
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2024-08-28 14:38:40 +02:00
Daniel P. Berrangé
3559dcd9de virtinst: add properties for AMD SEV-SNP
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2024-08-28 14:38:40 +02:00
Pavel Hrdina
1fef5d8661 tests: add virt-xml test to demonstrate changing graphics and video at the same time
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-08-26 12:33:51 -04:00
Pavel Hrdina
b34ae0d0c8 virt-xml: allow multiple --edit options
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-08-26 12:33:51 -04:00
Pavel Hrdina
cb6636f4bf virtinst: add getter/setter for video model
This makes it easier for users to change video model from QXL to
different model as QXL is special and uses other attributes that are not
supported by any other model. Without this code libvirt would report
error or user would have to request `clearxml`.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-08-26 12:33:51 -04:00
Pavel Hrdina
093d58fbc8 virtinst: add/remove spice devices when updating graphics type
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-08-26 12:33:51 -04:00
Pavel Hrdina
aaf8551914 virtinst: remove spice devices when removing last spice graphics
When Spice graphics is used QEMU creates a Spice server and communicates
with Spice client using multiple channels. These channels are used by
the spice devices as well. Without the Spice graphics defined there is
no use for the other devices. In addition libvirt will report error for
such configuration.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-08-26 12:33:51 -04:00
Pavel Hrdina
7a03f3efa8 testsuite: add test-spice vm definition
This will test spice related changes. Follow up patches will change this
behavior to remove spice related devices.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-08-26 12:33:51 -04:00
Pavel Hrdina
2a0aa2d56b virtinst: fix compare for audio devices
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-08-26 12:33:51 -04:00
Pavel Hrdina
ef64949e84 virtinst: unify detection of duplicate console when removing device
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-08-26 12:33:51 -04:00
Cole Robinson
29145b9e93 Fix some pylint
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-08-26 11:36:01 -04:00
Pavel Hrdina
90ceb87b7c virt-install: implement passt backend for user network interface
Add new `--network backend.type` attribute, libvirt currently supports
only `passt`. If not network type is specified virt-install will pick
`user` type as it is required for `passt` backend.

This also introduces support to specify portForward and specifying port
range as well.

For more details see [1].

[1] <https://libvirt.org/formatdomain.html#userspace-slirp-or-passt-connection>

Fixes: https://github.com/virt-manager/virt-manager/issues/488
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-08-26 11:27:03 -04:00
Pino Toscano
b1ee4c94c7 po: Refresh translation template
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2024-08-16 22:43:54 +02:00
Omar TS
baa380aae3 Translated using Weblate (Arabic)
Currently translated at 1.9% (28 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ar/
2024-08-16 22:43:04 +02:00
Henning
2d3f3faacd Translated using Weblate (German)
Currently translated at 88.8% (1291 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/de/
2024-08-16 22:43:04 +02:00
Abdul Munif Hanafi
deadb8a5c8 Translated using Weblate (Indonesian)
Currently translated at 39.6% (576 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/
2024-08-16 22:43:04 +02:00
Andika Triwidada
41fa111ceb Translated using Weblate (Indonesian)
Currently translated at 39.4% (573 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/

Translated using Weblate (Indonesian)

Currently translated at 31.1% (453 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/

Translated using Weblate (Indonesian)

Currently translated at 17.2% (251 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/
2024-08-16 22:43:04 +02:00
zhanchun li
276c1c4b0e Translated using Weblate (Chinese (Traditional) (zh_TW))
Currently translated at 100.0% (1453 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_TW/
2024-08-16 22:43:04 +02:00
김인수
383c83afee Translated using Weblate (Korean)
Currently translated at 100.0% (1453 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/
2024-08-16 22:43:04 +02:00
Renan Birck Pinheiro
735a4352f5 Translated using Weblate (Portuguese (Brazil))
Currently translated at 99.9% (1452 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/

Translated using Weblate (Portuguese (Brazil))

Currently translated at 99.7% (1449 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/

Translated using Weblate (Portuguese (Brazil))

Currently translated at 99.5% (1447 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/

Translated using Weblate (Portuguese (Brazil))

Currently translated at 99.2% (1442 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/

Translated using Weblate (Portuguese (Brazil))

Currently translated at 98.7% (1435 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/

Translated using Weblate (Portuguese (Brazil))

Currently translated at 97.7% (1420 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/

Translated using Weblate (Portuguese (Brazil))

Currently translated at 97.6% (1419 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/

Translated using Weblate (Portuguese (Brazil))

Currently translated at 95.9% (1394 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/
2024-08-16 22:43:04 +02:00
Andi Chandler
4e6ce92ed0 Translated using Weblate (English (United Kingdom))
Currently translated at 100.0% (1453 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/en_GB/
2024-08-16 22:43:04 +02:00
stephane blondon
a4adbc1a78 Translated using Weblate (French)
Currently translated at 92.7% (1347 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fr/

Translated using Weblate (French)

Currently translated at 92.7% (1348 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fr/

Translated using Weblate (French)

Currently translated at 92.5% (1345 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fr/

Translated using Weblate (French)

Currently translated at 89.9% (1307 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fr/
2024-08-16 22:43:04 +02:00
Cole Robinson
954c9b6bf7 uitests: createvm: fix case on f40
We should be checking 'selected' here, not 'focused'. This stopped
working on f40 apparently

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-08-14 11:36:13 -04:00
Cole Robinson
2ddbea5d0b uitests: Fix get_text() on fedora40
Seems like some dependent lib started exposing a similarly named
function, so ours stopped working

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-08-14 06:17:10 -04:00
Cole Robinson
0cad0c4dff uitests: force internal snapshots in test_snapshot.py
Incase the libvirt test driver ever starts advertising support

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-08-12 19:55:58 -04:00
Cole Robinson
a00c090022 uitests: handle newer libvirt test driver UpdateDevice support
Make it fail for the cases that expect it

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-08-12 19:55:58 -04:00
Cole Robinson
2e1bacfd33 uitests: Add live external snapshot testing
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-08-12 19:55:58 -04:00
Cole Robinson
95ca39aae8 uitests: test xmleditor textview fallback
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-08-12 19:54:45 -04:00
Cole Robinson
8eb37c0e50 uitests: Add some virtManager coverage exclusions 2024-08-12 19:54:45 -04:00
Cole Robinson
1194f09968 tests: cli: Fix with latest libvirt
The libvirt test driver supports more APIs now, so we are getting
a different error message.

Extend the grep= string to work with both old and new libvirt

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-08-07 11:58:49 -04:00
Cole Robinson
0288e92581 tests: cli: Use regex for grep= and nogrep= args
This will let us match more complex output, and match error message
differences across libvirt versions

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-08-07 11:58:49 -04:00
Natanael Copa
648f52bde0 virt-install: fix cloud-init ssh keys
Fix the cloud-init config file for --clouduser-ssh key.

Also change ssh_authorized_keys to `ssh_authorized_keys`, and make sure
default user is not deleted when setting ssh key for root.

Fixes commit 22478f307dd9 (virt-install: Add --cloud-init clouduser-ssh-key=)

Resolves: https://github.com/virt-manager/virt-manager/issues/452

Signed-off-by: Natanael Copa <ncopa@alpinelinux.org>
2024-07-25 16:50:34 +02:00
Patrice Lacouture
72a74fb1fb virtinstall: Fix --location and --cloud-init conflict
So far, --cloud-init is ignored when --location is specified.

Resolves: virt-manager#469
2024-07-22 16:08:09 +02:00
taoky
0c981eec58 tests: Add test for DeviceDisk.paths_in_use_by 2024-07-22 12:42:10 +02:00
taoky
328cabca8f hoststorage: Use DeviceDisk.paths_in_use_by for performance
When there's a pool with many vols (files), and user clicks on "Browse" in
VM's Virtual Disk details, the UI could stuck for up to several minutes.

By using DeviceDisk.paths_in_use_by() for bulk getting names, it could
show browser much faster.
2024-07-22 12:42:10 +02:00
taoky
cd8eeaf56d virtinst: disk: Add paths_in_use_by()
conn.fetch_all_vols() is slow, taking ~0.03s every time it's used. When
handling with a large number of paths, its performance is too bad and
could stuck UI for a very long time.

DeviceDisk.paths_in_use_by is added to help handle many paths with
only one call to conn.fetch_all_vols().
2024-07-22 12:42:10 +02:00
Pavel Hrdina
8a0e22397d tests: add s390x default test case
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-07-02 15:40:51 +02:00
Pavel Hrdina
43f581c26c virtinst: add graphics to risc-v virt VMs by default
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-07-02 15:40:51 +02:00
Pavel Hrdina
faebce406b virtinst: add graphics to aarch64 virt VMs by default
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-07-02 15:40:51 +02:00
Xianglai Li
9ede5d22d5 Add test cases for loongarch
Add some basic test cases for loongarch.

Signed-off-by: Xianglai Li <lixianglai@loongson.cn>
2024-06-18 12:09:14 +02:00
Xianglai Li
ea3cae4dc9 Add some default device support for loongarch
Add adaptations for loongarch with the following features:
Default video Support
UEFI prefer
Usb tablet and usb keyboard
rng and memballoon
sound device
Usb controller

Signed-off-by: Xianglai Li <lixianglai@loongson.cn>
2024-06-18 12:09:14 +02:00
Xianglai Li
d2cf01b3eb Add loongarch support
Define the judgment function of
loongarch architecture.

Signed-off-by: Xianglai Li <lixianglai@loongson.cn>
2024-06-18 12:09:14 +02:00
Andrea Bolognani
eee8d09dfe cli: Deprecate --cpu host
While the shorthand saves a tiny bit of typing, it is confusing
to people coming from QEMU, where -cpu host is the equivalent
of our --cpu host-passthrough. It's better to stick with the
unambiguous names used by libvirt.

Besides, the GUI already uses "host-model" throughout, so
advocating its use in the CLI too increases the internal
consistency.

https://issues.redhat.com/browse/RHEL-40003

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2024-06-11 16:35:26 +02:00
Andrea Bolognani
8b5f73e96b cli: Don't suggest --cpu host
Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2024-06-11 16:35:26 +02:00
Andrea Bolognani
0530df767a man: Don't suggest --cpu host
Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2024-06-11 16:35:26 +02:00
scarf
ba3a098c3b virtinst: disk: strip away file:// protocol 2024-06-10 17:43:35 +02:00
Pavel Hrdina
5fcf506e08 tests: skip mdev tests for libvirt older than 10.4.0
The test driver was broken for some time and our mdev tests were failing
on most libvirt versions. Recently this was fixed in libvirt 10.4.0 so
skip these tests unless we have new enough libvirt.

This requires extracting some mdev devices from many-devices test case.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-06-06 14:11:34 +02:00
Jonathon Jongsma
6a85d79a31 xmleditor: make gtksourceview optional
The only thing that GtkSourceView gives us is syntax highlighting and
auto-indent. When this library is not available, we can still offer xml
editing with a plain textview with very little lost functionality.

Signed-off-by: Jonathon Jongsma <jjongsma@redhat.com>
2024-06-06 10:25:26 +02:00
Andrea Bolognani
a91e23c858 install: Use virtio-scsi for unattended installations
This won't make any difference on x86, where either SATA or IDE
is used depending on the machine type, but on other architectures
we want virtio-scsi for a reasonable chance that the guest OS
will recognize the disk.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2024-05-30 22:10:05 +02:00
Andrea Bolognani
7f8230a158 guest: Prefer UEFI for riscv64
Most existing disk images expect UEFI; those that don't, require
either using direct kernel boot or manually providing a firmware
image, both of which imply user intervention.

Using UEFI by default means that at least images belonging to
the first group, of which more are going to pop up as the
ecosystem matures further, can work out of the box.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2024-05-30 22:10:05 +02:00
Andrea Bolognani
6fca91f286 tests: Add more riscv64 tests
Cover additional scenarios: direct kernel boot, use of cloud-init,
installation from CDROM and unattended installation.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2024-05-30 22:10:05 +02:00
Andrea Bolognani
3b09701f6b tests: Use SPICE graphics on riscv64
Provides more coverage, specifically the sound part.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2024-05-30 22:10:05 +02:00
Andrea Bolognani
9ec5852591 tests: Switch to --osinfo for riscv64
It's the preferred name, and it's shorter to boot.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2024-05-30 22:10:05 +02:00
Andrea Bolognani
0612dca8ee tests: Drop precompare_check from riscv64
We're using data from a much newer version of libvirt now.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2024-05-30 22:10:05 +02:00
Andrea Bolognani
094a81201a tests: Update riscv64 capabilities
The new capabilities reflect the status of riscv64
virtualization as of Fedora 40, which comes with libvirt
10.1.0 and QEMU 8.2.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2024-05-30 22:10:05 +02:00
Cole Robinson
1261666cf4 ci: Add test-against-libvirt-git.yml
Periodic job to run the test suite against libvirt.git

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-04-08 10:34:12 -04:00
Cole Robinson
ca25b41adc ci: clarify comment about what fedora packages we test against
it hasn't been virt-preview for a long while

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-04-07 16:46:40 -04:00
Cole Robinson
738a8d9f54 uitests: Fix with GtkFileChooserNative
Bring back the `Open` label for `Browse Local` option, but
preserver the SAVE dialog behavior (can enter a manual path)

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-04-07 15:55:48 -04:00
Michael Weghorn
db1b2fbce3 Use GtkFileChooserNative
Use GtkFileChooserNative [1] instead of GtkFileChooserDialog [2]
to integrate better with the platform (e.g. use the portal
implementation when run with GTK_USE_PORTAL=1, resulting in
the KDE Frameworks implementation being used when
xdg-desktop-portal-kde is in use). Quoting from
the GtkFileChooserDialog doc [2]:

> If you want to integrate well with the platform you should use the
> GtkFileChooserNative API, which will use a platform-specific dialog if
> available and fall back to GtkFileChooserDialog otherwise.

Also replace the use of GTK_STOCK_CANCEL [3] and GTK_STOCK_OPEN [4]
which were deprecated in GTK 3.10:

Both, the `accept_label` and `cancel_label` params of
`Gtk.FileChooserNative.new` can be `None` to use the default
text ("Open", "Cancel"). [5]

Adjust the only caller (in `vmmVMWindow#_takeScreenshot`)
that was passing an explicit label/icon name for the
accept button to pass `_("_Save")` as label, rather than
the also deprecated Gtk.STOCK_SAVE [6].
(GtkFileChooserDialog has special handling for Gtk.STOCK_SAVE
etc., but that's not generally the case for native dialogs).

Rename the method param from `choose_button` to `choose_label`
to make clearer that this is a label.

[1] https://docs.gtk.org/gtk3/class.FileChooserNative.html
[2] https://docs.gtk.org/gtk3/class.FileChooserDialog.html
[3] https://docs.gtk.org/gtk3/const.STOCK_CANCEL.html
[4] https://docs.gtk.org/gtk3/const.STOCK_OPEN.html
[5] http://pygobject-doc.gitee.io/pgi-docs/Gtk-3.0/classes/FileChooserNative.html#Gtk.FileChooserNative.new
[6] https://docs.gtk.org/gtk3/const.STOCK_SAVE.html

Fixes #315
2024-04-07 15:54:47 -04:00
Pino Toscano
231a3dbc87 build: use setuptools.command.build when available
Setuptools 62.4.0 adds setuptools.command.build to transparently replace
the old distutils equivalent; hence, use it when available to fully
switch away from distutils.

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2024-04-07 14:29:48 -04:00
Pino Toscano
4f4e73d017 build: use super()
... rather than explicitly calling the parent class; this will make
further changes easier.

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2024-04-07 14:29:48 -04:00
Cole Robinson
17d9f339d1 Tweak for codecov v4 2024-04-07 14:27:17 -04:00
dependabot[bot]
68efec21a7 ci: bump codecov/codecov-action from 3 to 4
Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from 3 to 4.
- [Release notes](https://github.com/codecov/codecov-action/releases)
- [Changelog](https://github.com/codecov/codecov-action/blob/main/CHANGELOG.md)
- [Commits](https://github.com/codecov/codecov-action/compare/v3...v4)

---
updated-dependencies:
- dependency-name: codecov/codecov-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-04-07 14:27:17 -04:00
Pino Toscano
8f8a1b9b43 ci: checkout the code after installing git-core
This makes sure that the actions/checkout action uses git to fetch the
sources (and thus resulting in a git repository), rather than using the
REST API (and get a simple directory with sources).

This may be useful to certain services (e.g. newer version of
codecov-cli) as they need to have the sources as proper git repository.

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2024-04-07 14:27:17 -04:00
Pino Toscano
14c5684f25 ci: split base dependency and build dependency installation
Split the installation of the base dependencies & the RPM build
dependencies in two steps, so they can be reordered as needed later on.

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2024-04-07 14:27:17 -04:00
Pino Toscano
3f79e76e58 ci: install git-core as well
It will be needed by codecov/codecov-action v4.

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2024-04-07 14:27:17 -04:00
Cole Robinson
e21129aebe ci: Rename CI workflow to Test on fedora:latest
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-04-06 16:14:46 -04:00
Cole Robinson
dce9de481f hostdev: Fix error when mdev type_id is missing
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-04-06 15:54:09 -04:00
Cole Robinson
8b6db203f7 tests: Fix host-copy XML with libvirt 10.1.0
New `clusters` changes XML output

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-04-06 15:48:46 -04:00
tuksgig
4ffbc0d904 Allow serial console resize to beyond 80 columns.
Replace Gtk.Box.add() with Gtk.Box.pack_start() to place the VTE terminal widget. This enables horizontal expansion/filling the terminal widget when resizing the serial console window.
2024-03-26 17:34:50 +01:00
Pavel Hrdina
e95ca453c4 virtManager: ignore agen livecycle event for shutoff VMs
This event is mainly to refresh the VM XML to figure out the state of
virtio channels and that should happen only for running VMs.

This affects external snapshot behavior in virtManager. If the VM is
offline and user deletes external snapshot libvirt needs to start QEMU
process to delete the snapshot. The QEMU process is started with stopped
CPUs so it is visible as online and paused. It also emits the agent
lifecycle event but there is no other domain lifecycle event so after
the snapshot deletion the VM stays paused in virtManager even if it is
already offline in libvirt.

To mitigate this behavior we can ignore agent lifecycle event for
shutoff VMs.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-03-25 13:21:50 +01:00
Pavel Hrdina
5488ff4773 virtManager: add support to create external snapshots
Add new 2 rows into the snapshotsnew windows, one to select if the
snapshot mode is `internal` or `external` and memory state location when
making external snapshot for running VM.

We will check if libvirt fully supports external snapshots by consulting
host capabilities and add `external` to snapshot mode only if it is
supported.

For external snapshots the memory state is stored in separate file but
libvirt doesn't have any default location so virtManager will get path
to all usable disks and create a dropdown menu for it, but user is still
allowed to modify that path to use whatever path they prefer.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-03-25 13:21:50 +01:00
Pavel Hrdina
f1ba012e8f virtManager: domain: allow disk only snapshots
This is used for external snapshots when the VM is offline.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-03-25 13:21:50 +01:00
Pavel Hrdina
d8565ac533 virtinst: snapshot: add memory file attribute
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-03-25 13:21:50 +01:00
Pavel Hrdina
3cde1acbb6 virtinst: add external snapshot capability
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2024-03-25 13:21:50 +01:00
Pino Toscano
dadb9a0d6f po: sort LINGUAS
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2024-03-04 06:26:27 +01:00
eirik song
55b4c1bc9e Translated using Weblate (Chinese (Simplified) (zh_CN))
Currently translated at 100.0% (1453 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_CN/
2024-03-04 06:23:39 +01:00
김인수
1be248e645 Translated using Weblate (Korean)
Currently translated at 100.0% (1453 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/
2024-03-03 20:09:43 +01:00
Rafael Fontenelle
e4e406e386 Translated using Weblate (Portuguese (Brazil))
Currently translated at 95.8% (1393 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/
2024-03-03 20:09:43 +01:00
Temuri Doghonadze
9c4b789510 Translated using Weblate (Georgian)
Currently translated at 93.1% (1353 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ka/

Translated using Weblate (Georgian)

Currently translated at 88.3% (1283 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ka/
2024-03-03 20:09:43 +01:00
Geraldo S. Simião Kutz
c8c37cb0cd Translated using Weblate (Portuguese (Brazil))
Currently translated at 95.8% (1392 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/
2024-03-03 20:09:43 +01:00
Cole Robinson
a6b62a20b6 systray: Cleanups and improvements for --show-systray
- Add UI coverage
- Drop redundant systray_instance caching
- Tweaks help test and docs
- Show an error if the systray doesn't embed

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-03-03 14:18:04 -05:00
Cole Robinson
2043847ade uitests: More handling for slow startup on f39
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-03-03 14:18:04 -05:00
Cole Robinson
75e4d1dd29 baseclass: Avoid glib Source ID XX not found at app shutdown
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-03-03 14:18:04 -05:00
Gustavo Costa
6c9774267f man: document --show-systray option 2024-03-03 14:17:54 -05:00
Gustavo Costa
69290e0526 cli: add --show-systray option 2024-03-03 14:17:54 -05:00
Cole Robinson
014d1ef99b console: Cleanup and improve console menu handling
- Rework the ConsolePages abstraction to carry the Gtk.Menu. makes
  it all less messy

- Make the console menu the single source of truth for console
  embeddability, and error message reporting

- Small misc cleanups here and there

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-03-03 12:52:37 -05:00
Feng Jiang
409e4bf2d1 console: Select the first embeddable graphics device as graphical console
Currently, when there are multiple graphics devices, the first graphics
device is always selected as the graphical console. For the following
configuration:

    <graphics type="egl-headless">
      <gl rendernode="/dev/dri/renderD128"/>
    </graphics>
    <graphics type="spice" autoport="yes">
      <listen type="address"/>
      <image compression="off"/>
      <gl enable="no"/>
    </graphics>

virt-manager will report an error:

    Cannot display graphical console type 'egl-headless'

The patch will iterate through all graphics devices to try to select the
first embeddable graphics device as graphical console.

Signed-off-by: Feng Jiang <jiangfeng@kylinos.cn>
Signed-off-by: Liming Sun <sunliming@kylinos.cn>
Reviewed-by: Cole Robinson <crobinso@redhat.com>
2024-03-03 12:52:20 -05:00
Feng Jiang
d83074a001 domain: Add idx parameter to open_graphics_fd()
Now open_graphics_fd() always opens the 1st graphic device, when
there are multiple graphic devices (e.g. spice + egl-headless),
we need to specify the index number for libvirt.

Signed-off-by: Feng Jiang <jiangfeng@kylinos.cn>
Signed-off-by: Ming Xie <xieming@kylinos.cn>
Reviewed-by: Cole Robinson <crobinso@redhat.com>
2024-03-03 12:52:20 -05:00
Feng Jiang
9c242ef79c console: Move embeddable_graphics() to console.py
Signed-off-by: Feng Jiang <jiangfeng@kylinos.cn>
Signed-off-by: Weishi Li <liweishi@kylinos.cn>
Reviewed-by: Cole Robinson <crobinso@redhat.com>
2024-03-03 12:52:20 -05:00
Cole Robinson
0d3b7f673f Fix pylint 3.1.0 issues
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-03-03 10:43:30 -05:00
Cole Robinson
a52ab24ec4 createvm: Replace deprecated pkgutil.find_loader
importlib.util.find_spec is around since python 3.4

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-03-03 10:43:30 -05:00
Cole Robinson
0c899a7ccd uitests: Handle slow app launch on fedora 39
Not quite sure what's going on here, I think it has something to
do with slowness when the accessibility bus is being polled.

Add some infrastructure to increase the timeout while we wait for
the app to pop up

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-03-03 10:43:30 -05:00
Cole Robinson
a05ab5cdb4 uitests: Fix walkUI flakyness
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-03-03 10:43:30 -05:00
nose-gnome
bb86721352 ui: details: Increased scrolledview6's height request
Increased the height of scrolledview6 to make viewing applications  easier in os info
2024-03-02 14:19:28 -05:00
nose-gnome
04cc489529 ui: details: fix Applications width.
In OS info the applications tree view was too narrow to read the contents, so I enabled expanding horizontally for scrolledwindow6
2024-03-02 14:19:28 -05:00
Cole Robinson
7ae3e10bc4 netlist: Fix UI error when virtual network doesn't exist
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-03-02 13:22:45 -05:00
Cole Robinson
cf172c8e57 testdriver: Add portgroups example to test-many-devices
This helps hit some uitests code coverage

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-03-02 13:22:40 -05:00
Cole Robinson
82f1c4495e domain: rename: handle firmware ending with .qcow2
Newer libvirt + edk2 will default to nvram in qcow2 format, but
our domain rename code had some .fd assumptions baked in.

Adjust uitests to handle it too

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-03-02 13:22:37 -05:00
Iain Buclaw
78f7797c13 Support creating sparse volumes on ZFS pools
Closes #487

Signed-off-by: Iain Buclaw <ibuclaw@gdcproject.org>
2024-03-02 11:37:45 -05:00
Cole Robinson
6710ca6969 setup: Allow pylint -j0
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-02-14 12:34:27 -05:00
Cole Robinson
135cf17072 tests: Add unittest coverage for qemu hvf VMs
I have no idea if the generated config is optimal, but this
at least provides a base for us to confirm when defaults change.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-02-05 14:42:49 -05:00
Mohamed Akram
b9f9f768fc Add support for hvf domain type 2024-02-05 14:42:40 -05:00
Cole Robinson
4e2bec5b14 tests: ui: make creatnet test start less flakey
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-01-23 13:28:07 -05:00
Cole Robinson
acf3cedbbf tests: ui: make newvm test start less flakey
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-01-23 09:07:29 -05:00
Cole Robinson
c399353e00 Fix some pylint
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-01-22 17:15:11 -05:00
Cole Robinson
83fcc5b2e8 tests: cli: Adjust hotplug test for latest libvirt
The libvirt test driver now has implementations for hotplug routines,
which broke string matching for one case.

Loosen it up to work for old and new libvirt versions.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-01-22 17:10:41 -05:00
Cole Robinson
2e3db754d1 uri: Mock domcaps returning NO_SUPPORT
With libvirt 9.8.0, the test driver now has a stub getDomainCapabilities
implementation. But we still have some code that needs to handle
a driver with missing domcaps.

Make our magicuri mock return NO_SUPPORT for domcaps, when the URI
doesn't have any domcaps XML passed in. This is enough for our test
purposes.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2024-01-22 17:07:31 -05:00
Pino Toscano
dfc484b2d5 docs: update flow of translations from Weblate
Fixes #614

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2024-01-02 10:58:39 +01:00
joo es
e6c0687485 Translated using Weblate (Arabic)
Currently translated at 0.2% (3 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ar/

Added translation using Weblate (Arabic)
2024-01-02 10:55:05 +01:00
Oğuz Ersen
fe528e6054 Translated using Weblate (Turkish)
Currently translated at 100.0% (1453 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/tr/
2024-01-02 10:55:05 +01:00
Göran Uddeborg
9bafde610b Translated using Weblate (Swedish)
Currently translated at 100.0% (1453 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sv/
2024-01-02 10:55:05 +01:00
Fabio Tomat
9855a71137 Translated using Weblate (Friulian)
Currently translated at 100.0% (1453 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fur/
2024-01-02 10:55:05 +01:00
Luna Jernberg
e09fa6e380 Translated using Weblate (Swedish)
Currently translated at 99.8% (1451 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sv/
2024-01-02 10:55:05 +01:00
Sergey A
8b1d8a3304 Translated using Weblate (Russian)
Currently translated at 100.0% (1453 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ru/

Translated using Weblate (Russian)

Currently translated at 100.0% (1453 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ru/

Translated using Weblate (Russian)

Currently translated at 100.0% (1453 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ru/
2024-01-02 10:55:05 +01:00
Jan Kuparinen
58806e189b Translated using Weblate (Finnish)
Currently translated at 100.0% (1453 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fi/
2024-01-02 10:55:05 +01:00
Temuri Doghonadze
387125d104 Translated using Weblate (Georgian)
Currently translated at 87.6% (1274 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ka/
2024-01-02 10:55:05 +01:00
김인수
bd65c28672 Translated using Weblate (Korean)
Currently translated at 100.0% (1453 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/

Translated using Weblate (Korean)

Currently translated at 100.0% (1453 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/
2024-01-02 10:55:05 +01:00
Pavel Borecki
2a5464afbe Translated using Weblate (Czech)
Currently translated at 100.0% (1453 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/cs/
2024-01-02 10:55:05 +01:00
Yuri Chornoivan
eee9a7a88e Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1453 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2024-01-02 10:55:05 +01:00
Piotr Drąg
190046e934 Translated using Weblate (Polish)
Currently translated at 100.0% (1453 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pl/

Translated using Weblate (Polish)

Currently translated at 100.0% (1453 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pl/
2024-01-02 10:55:05 +01:00
Pino Toscano
af46c23529 Translated using Weblate (Italian)
Currently translated at 100.0% (1453 of 1453 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2024-01-02 10:55:05 +01:00
Weblate
dce7348688 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2024-01-02 10:55:05 +01:00
Jonathon Jongsma
40b73fec1b Fix filesystem socket.source
When specifying the socket.source option for filesystem devices, like
this:
  --filesystem type=mount,driver.type=virtiofs,source.socket=/xyz.sock,target.dir=tag1

virt-install is writing the xml as:

    <filesystem type="mount">
      <source>
        <socket>/xyz.sock</socket>
      </source>
      <target dir="tag1"/>
      <driver type="virtiofs"/>
    </filesystem>

This produces an error such as:

  ERROR missing source information for device mount_tag1

But the socket should be an attribute of source rather than a child
element. After this patch, the same command results in the following XML
and no error is produced:

    <filesystem type="mount">
      <source socket="/xyz.sock"/>
      <target dir="tag1"/>
      <driver type="virtiofs"/>
    </filesystem>

Resolves: RHEL-1126

Signed-off-by: Jonathon Jongsma <jjongsma@redhat.com>
2023-10-24 10:30:37 +02:00
Pino Toscano
0fb7377abb po: Refresh translation template
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2023-09-25 07:47:27 +02:00
Cheng-Chia Tseng
2b657c7538 Translated using Weblate (Chinese (Traditional) (zh_TW))
Currently translated at 100.0% (1454 of 1454 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_TW/

Translated using Weblate (Chinese (Traditional) (zh_TW))

Currently translated at 100.0% (1454 of 1454 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_TW/
2023-09-25 07:46:37 +02:00
Jan Kuparinen
5dd54a6220 Translated using Weblate (Finnish)
Currently translated at 100.0% (1454 of 1454 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fi/
2023-09-25 07:46:37 +02:00
Temuri Doghonadze
4c4fa968cd Translated using Weblate (Georgian)
Currently translated at 87.6% (1274 of 1454 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ka/

Translated using Weblate (Georgian)

Currently translated at 87.4% (1271 of 1454 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ka/
2023-09-25 07:46:37 +02:00
Oğuz Ersen
da66e0ebdb Translated using Weblate (Turkish)
Currently translated at 100.0% (1454 of 1454 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/tr/
2023-09-25 07:46:37 +02:00
Sergey A
232730b850 Translated using Weblate (Russian)
Currently translated at 100.0% (1454 of 1454 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ru/

Translated using Weblate (Russian)

Currently translated at 100.0% (1454 of 1454 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ru/
2023-09-25 07:46:37 +02:00
김인수
15430240d6 Translated using Weblate (Korean)
Currently translated at 100.0% (1454 of 1454 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/
2023-09-25 07:46:37 +02:00
Yuri Chornoivan
b4df3b074d Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1454 of 1454 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2023-09-25 07:46:37 +02:00
Piotr Drąg
300b4fb851 Translated using Weblate (Polish)
Currently translated at 100.0% (1454 of 1454 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pl/
2023-09-25 07:46:37 +02:00
Pino Toscano
e85ff421ae Translated using Weblate (Italian)
Currently translated at 100.0% (1454 of 1454 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2023-09-25 07:46:37 +02:00
Pavel Borecki
d0ae9e4162 Translated using Weblate (Czech)
Currently translated at 100.0% (1454 of 1454 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/cs/
2023-09-25 07:46:37 +02:00
Weblate
882b3d14a6 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2023-09-25 07:46:37 +02:00
Cole Robinson
ab0a318a46 delete: Fix ambiguity that confused pylint
virtManager/delete.py:219:11: E0601: Using variable 'error' before assignment (used-before-assignment)

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2023-09-24 16:31:58 -04:00
Cole Robinson
775edfd5dc connectauth: Drop sanity checking for libvirtd
Nowadays with libvirt split daemons, libvirtd isn't required to
be installed for a first run local connection to succeed, so we
are needlessly blocking the app from 'just working' in many cases.
Especially considering that many distros often have libvirt running
out of the box due to gnome-boxes pulling it in.

Drop the daemon checking entirely.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2023-09-24 16:31:58 -04:00
Pino Toscano
17dc777481 po: Refresh translation template
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2023-09-12 20:01:42 +02:00
zk dc
94ea9af720 Translated using Weblate (Chinese (Simplified) (zh_CN))
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_CN/
2023-09-12 19:57:16 +02:00
Temuri Doghonadze
d3288b9a0a Translated using Weblate (Georgian)
Currently translated at 87.7% (1270 of 1448 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ka/
2023-09-12 19:57:16 +02:00
김인수
247d9516d4 Translated using Weblate (Korean)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/
2023-09-12 19:57:16 +02:00
Anna Nym
8b7ab45e7b Translated using Weblate (German)
Currently translated at 83.4% (1211 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/de/
2023-09-12 19:57:16 +02:00
连 浩鑫
a021d07284 Translated using Weblate (Chinese (Simplified) (zh_CN))
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_CN/
2023-09-12 19:57:16 +02:00
김인수
291fb1649d Translated using Weblate (Korean)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/
2023-09-12 19:57:16 +02:00
Temuri Doghonadze
a97d6a2500 Translated using Weblate (Georgian)
Currently translated at 87.5% (1268 of 1448 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ka/
2023-09-12 19:57:16 +02:00
Cheng-Chia Tseng
1510e6dfdf Translated using Weblate (Chinese (Traditional) (zh_TW))
Currently translated at 99.8% (1449 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_TW/
2023-09-12 19:57:16 +02:00
Lucas Fernandes
4418c84c14 Translated using Weblate (Portuguese)
Currently translated at 67.7% (983 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt/
2023-09-12 19:57:16 +02:00
Toby Foster
3decf996e2 Translated using Weblate (Vietnamese)
Currently translated at 0.1% (1 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/vi/
2023-09-12 19:57:16 +02:00
Toby Foster
8e8a412ebc Added translation using Weblate (Vietnamese) 2023-09-12 19:57:16 +02:00
Dankaházi (ifj.) István
67bd0433bf Translated using Weblate (Hungarian)
Currently translated at 56.3% (817 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/hu/
2023-09-12 19:57:16 +02:00
Dankaházi (ifj.) István
744a2484af Translated using Weblate (Hungarian)
Currently translated at 55.8% (811 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/hu/
2023-09-12 19:57:16 +02:00
Miguel Ángel Sánchez
844cba7c8e Translated using Weblate (Spanish)
Currently translated at 86.8% (1260 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/
2023-09-12 19:57:16 +02:00
zk dc
109dd6e617 Translated using Weblate (Chinese (Simplified) (zh_CN))
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_CN/
2023-09-12 19:57:16 +02:00
김인수
0e36a1e2a8 Translated using Weblate (Korean)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/
2023-09-12 19:57:16 +02:00
Fabio Tomat
f30bf6897d Translated using Weblate (Friulian)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fur/
2023-09-12 19:57:16 +02:00
Pavel Borecki
001351bd96 Translated using Weblate (Czech)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/cs/
2023-09-12 19:57:16 +02:00
김인수
f90f4604a5 Translated using Weblate (Korean)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/
2023-09-12 19:57:16 +02:00
Luke Na
6a25eb847d Translated using Weblate (Chinese (Simplified) (zh_CN))
Currently translated at 97.5% (1416 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_CN/
2023-09-12 19:57:16 +02:00
Temuri Doghonadze
7735a608f4 Translated using Weblate (Georgian)
Currently translated at 87.2% (1263 of 1448 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ka/
2023-09-12 19:57:16 +02:00
grimst
7e9ef3b4dc Translated using Weblate (French)
Currently translated at 89.0% (1292 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fr/
2023-09-12 19:57:16 +02:00
Dankaházi (ifj.) István
6c41927c3e Translated using Weblate (Hungarian)
Currently translated at 55.6% (808 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/hu/
2023-09-12 19:57:16 +02:00
Hoppár Zoltán
4f595e72d3 Translated using Weblate (Hungarian)
Currently translated at 55.6% (808 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/hu/
2023-09-12 19:57:16 +02:00
Gustavo Costa
5cc60212ab Translated using Weblate (Portuguese (Brazil))
Currently translated at 95.5% (1387 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/
2023-09-12 19:57:16 +02:00
Hoppár Zoltán
11c8880d90 Translated using Weblate (Hungarian)
Currently translated at 53.4% (776 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/hu/
2023-09-12 19:57:16 +02:00
Dankaházi (ifj.) István
5d61c47c32 Translated using Weblate (Hungarian)
Currently translated at 53.4% (776 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/hu/
2023-09-12 19:57:16 +02:00
Sergey A
6076fc6911 Translated using Weblate (Russian)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ru/
2023-09-12 19:57:16 +02:00
Fabio Tomat
4c734efb70 Translated using Weblate (Italian)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2023-09-12 19:57:16 +02:00
Fabio Tomat
e892003502 Translated using Weblate (Friulian)
Currently translated at 99.9% (1450 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fur/
2023-09-12 19:57:16 +02:00
Fabio Tomat
a9cc2a38f2 Translated using Weblate (Friulian)
Currently translated at 89.8% (1303 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fur/
2023-09-12 19:57:16 +02:00
Andi Chandler
0f72c4964b Translated using Weblate (English (United Kingdom))
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/en_GB/
2023-09-12 19:57:16 +02:00
Andi Chandler
7d5308a51e Translated using Weblate (English (United Kingdom))
Currently translated at 84.7% (1229 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/en_GB/
2023-09-12 19:57:16 +02:00
Cheng-Chia Tseng
fc22531e4d Translated using Weblate (Chinese (Traditional) (zh_TW))
Currently translated at 99.8% (1449 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_TW/
2023-09-12 19:57:16 +02:00
Teknős Ferenc
a38953849e Translated using Weblate (Hungarian)
Currently translated at 53.2% (773 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/hu/
2023-09-12 19:57:16 +02:00
Pedro Luis Valades Viera
169631b812 Translated using Weblate (Spanish)
Currently translated at 86.6% (1258 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/
2023-09-12 19:57:16 +02:00
Xi Lu
0361ebca4d Translated using Weblate (Chinese (Simplified) (zh_CN))
Currently translated at 97.5% (1415 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_CN/
2023-09-12 19:57:16 +02:00
Xi Lu
28cecfdd61 Translated using Weblate (Chinese (Simplified) (zh_CN))
Currently translated at 97.5% (1415 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_CN/
2023-09-12 19:57:16 +02:00
Alejandro Vazquez
d8dac9fb2c Translated using Weblate (Galician)
Currently translated at 0.2% (3 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/gl/
2023-09-12 19:57:16 +02:00
Alejandro Vazquez
7c3d0ea23d Added translation using Weblate (Galician) 2023-09-12 19:57:16 +02:00
Andi Chandler
50e91c75d0 Translated using Weblate (English (United Kingdom))
Currently translated at 73.5% (1067 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/en_GB/
2023-09-12 19:57:16 +02:00
Andi Chandler
e8ded16f06 Translated using Weblate (English (United Kingdom))
Currently translated at 73.1% (1061 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/en_GB/
2023-09-12 19:57:16 +02:00
Andi Chandler
8a3fd77b2b Translated using Weblate (English (United Kingdom))
Currently translated at 72.3% (1050 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/en_GB/
2023-09-12 19:57:16 +02:00
Ville-Pekka Vainio
e5c76941f7 Translated using Weblate (Finnish)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fi/
2023-09-12 19:57:16 +02:00
Ettore Atalan
ca76deb467 Translated using Weblate (German)
Currently translated at 83.4% (1211 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/de/
2023-09-12 19:57:16 +02:00
Whired Planck
43c8651e15 Translated using Weblate (Chinese (Simplified) (zh_CN))
Currently translated at 97.4% (1414 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_CN/
2023-09-12 19:57:16 +02:00
Miguel Ángel Sánchez
cb6127eccd Translated using Weblate (Spanish)
Currently translated at 85.8% (1246 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/
2023-09-12 19:57:16 +02:00
김인수
909cbb9eeb Translated using Weblate (Korean)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/
2023-09-12 19:57:16 +02:00
Andi Chandler
c03f64d525 Translated using Weblate (English (United Kingdom))
Currently translated at 71.9% (1044 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/en_GB/
2023-09-12 19:57:16 +02:00
Andika Triwidada
38d71faad6 Translated using Weblate (Indonesian)
Currently translated at 17.0% (247 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/
2023-09-12 19:57:16 +02:00
Temuri Doghonadze
647b2193b1 Translated using Weblate (Georgian)
Currently translated at 86.7% (1256 of 1448 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ka/
2023-09-12 19:57:16 +02:00
Flo H
5cc26d8583 Translated using Weblate (German)
Currently translated at 83.4% (1211 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/de/
2023-09-12 19:57:16 +02:00
김인수
5776d4fb55 Translated using Weblate (Korean)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/
2023-09-12 19:57:16 +02:00
Andi Chandler
dbe7a6cf2c Translated using Weblate (English (United Kingdom))
Currently translated at 71.8% (1043 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/en_GB/
2023-09-12 19:57:16 +02:00
sajad mirzaei
1a3e029d7b Translated using Weblate (Persian)
Currently translated at 0.1% (2 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fa/
2023-09-12 19:57:16 +02:00
sajad mirzaei
7553d9dbcb Added translation using Weblate (Persian) 2023-09-12 19:57:16 +02:00
Vincenzo Reale
6c5754b81b Translated using Weblate (Italian)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2023-09-12 19:57:16 +02:00
Oğuz Ersen
eba882c160 Translated using Weblate (Turkish)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/tr/
2023-09-12 19:57:16 +02:00
Olga Smirnova
f32b3d98b7 Translated using Weblate (Occidental)
Currently translated at 41.9% (609 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ie/
2023-09-12 19:57:16 +02:00
Olga Smirnova
ad4398801e Translated using Weblate (Occidental)
Currently translated at 35.6% (518 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ie/
2023-09-12 19:57:16 +02:00
Olga Smirnova
76f0f79838 Translated using Weblate (Russian)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ru/
2023-09-12 19:57:16 +02:00
Olga Smirnova
ae01c46680 Added translation using Weblate (Occidental) 2023-09-12 19:57:16 +02:00
Alexey Rubtsov
487df549c3 Translated using Weblate (Russian)
Currently translated at 98.6% (1431 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ru/
2023-09-12 19:57:16 +02:00
V I
a1289356bf Translated using Weblate (Russian)
Currently translated at 98.6% (1431 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ru/
2023-09-12 19:57:16 +02:00
Gogo Gogsi
55982a5da0 Translated using Weblate (Croatian)
Currently translated at 72.8% (1057 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/hr/
2023-09-12 19:57:16 +02:00
V I
c8518cc068 Translated using Weblate (Russian)
Currently translated at 97.2% (1411 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ru/
2023-09-12 19:57:16 +02:00
Alexey Rubtsov
7e3bb7c185 Translated using Weblate (Russian)
Currently translated at 97.2% (1411 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ru/
2023-09-12 19:57:16 +02:00
V I
73e5b61cfc Translated using Weblate (Russian)
Currently translated at 96.1% (1395 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ru/
2023-09-12 19:57:16 +02:00
Alexey Rubtsov
1cad0be302 Translated using Weblate (Russian)
Currently translated at 96.1% (1395 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ru/
2023-09-12 19:57:16 +02:00
Andi Chandler
b9f31bb9b8 Translated using Weblate (English (United Kingdom))
Currently translated at 70.7% (1027 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/en_GB/
2023-09-12 19:57:16 +02:00
Temuri Doghonadze
79b457338e Translated using Weblate (Georgian)
Currently translated at 85.8% (1243 of 1448 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ka/
2023-09-12 19:57:16 +02:00
Pino Toscano
f05a1609d8 Translated using Weblate (Italian)
Currently translated at 97.9% (1421 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/

Translated using Weblate (Italian)

Currently translated at 97.7% (1418 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2023-09-12 19:57:16 +02:00
dependabot[bot]
fcfad47328 ci: bump codecov/codecov-action from 1 to 3
Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from 1 to 3.
- [Release notes](https://github.com/codecov/codecov-action/releases)
- [Changelog](https://github.com/codecov/codecov-action/blob/main/CHANGELOG.md)
- [Commits](https://github.com/codecov/codecov-action/compare/v1...v3)

---
updated-dependencies:
- dependency-name: codecov/codecov-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-09-12 18:58:59 +02:00
dependabot[bot]
c56c17bef4 ci: bump actions/checkout from 2 to 4
Bumps [actions/checkout](https://github.com/actions/checkout) from 2 to 4.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v2...v4)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-09-12 18:47:15 +02:00
Pino Toscano
4bc194ab92 ci: add dependabot config for GitHub Actions
Enable dependabot for the "main" branch, letting it scan for outdated
GitHub Actions used in workflows on a weekly base.

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2023-09-12 12:33:25 -04:00
Cole Robinson
ec434948a8 installer: drop default TPM for --cloud-init install phase
When shim in the guest sees unpopulated EFI NVRAM, like when
we create a new UEFI VM, it invokes fallback.efi to populate
initial NVRAM boot entries. When the guest also has a TPM device,
shim will do a one time VM reset. This reset throws off the
reboot detection that is central to virt-install's install
process.

The main install case that this will usually be relevant is
the combo of UEFI and --cloud-init. The latter usually implies
use of a distro cloud image, which will be using shim, and the
--cloud-init process requires a multi stage install compared
to just a plain import install.

For that case, we disable the default TPM device for the first
boot.

https://bugzilla.redhat.com/show_bug.cgi?id=2133525

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2023-09-12 12:04:49 -04:00
Cole Robinson
fca6de3950 tests: Add more cloud-init and TPM test cases
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2023-09-12 12:03:40 -04:00
Cole Robinson
0f706cf874 Fix some pylint
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2023-09-12 11:54:04 -04:00
Pino Toscano
ccd4757533 data: appstream: add launchable tag
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2023-09-10 11:20:29 -04:00
Martin Kletzander
9f8da1f666 virt-clone: Copy disk permissions as well
When cloning using libvirt APIs the function virStorageVolCreateXMLFrom
is used.  However name and permissions are taken from the new XML [1].
By copying the permissions (only the mode is used) we can avoid some
unexpected issues.

[1] https://libvirt.org/html/libvirt-libvirt-storage.html#virStorageVolCreateXMLFrom

Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=2115153
Signed-off-by: Martin Kletzander <mkletzan@redhat.com>
2023-09-10 11:19:31 -04:00
Laszlo Ersek
2ebbdb2797 fix indentation of multiline log.exception() invocations
Commit f107e3998908 ("Switch to more traditional logging structure",
2019-06-17) replaced "logging.exception" with "log.exception", effectively
shifting the argument lists 4 characters to the left. The second and
further lines of multiline invocations were not accordingly unindented,
however, which ended up setting a suboptimal precedent as well. Unindent
those lines now.

Reported-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
2023-08-30 10:48:54 +02:00
Cole Robinson
19b0f3f446 tests: Add unit test coverage for #539
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2023-08-29 12:27:40 -04:00
Laszlo Ersek
6e5c1db6b4 tests/data: refresh Fedora tree URLs in virt-install-osinfo* expected XMLs
Libosinfo seems to generate Fedora tree URLs using the "https", not
"http", scheme now; which breaks CI. Update the expected outputs
accordingly.

Signed-off-by: Laszlo Ersek <lersek@redhat.com>
2023-08-29 13:24:52 +02:00
Laszlo Ersek
7dbe973b3f virtinst: suppress "lookup_capsinfo" exception in machine type alias check
Just to be sure, this patch implements the second approach (described in
the previous patch) as well.

Note that there is precedent for suppressing "guest_lookup" exceptions:
refer to the "Error determining machine list" branch from commit
ae7ebc220b15 ("details: Properly limit machine type list by guests
arch/type", 2013-09-01).

(

In fact, that branch gets activated when opening the details window for a
domain that uses a non-default emulator; the "virt-manager --debug" log
contains:

> ERROR (details:613) Error determining machine list
> Traceback (most recent call last):
>   File "virtManager/details/details.py", line 605, in _init_details
>     capsinfo = caps.guest_lookup(
>   File "virtinst/capabilities.py", line 319, in guest_lookup
>     raise ValueError(msg)
> ValueError: Host does not support domain type kvm with machine
> 'pc-q35-8.1' for virtualization type 'hvm' with architecture 'x86_64'

)

Fixes: #539
Fixes: 05fcc7410eee ("virtinst: fix caching of domain capabilities", 2022-07-27)
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
2023-08-29 13:24:52 +02:00
Laszlo Ersek
4ead4acb44 virtinst: delay "lookup_capsinfo" until we really need it
When I try to open the details window for a domain that does not use the
system default emulator, I get the following exception:

> Traceback (most recent call last):
>   File "virtManager/vmwindow.py", line 40, in get_instance
>     cls._instances[key] = vmmVMWindow(vm)
>   File "virtManager/vmwindow.py", line 83, in __init__
>     self._details = vmmDetails(self.vm, self.builder, self.topwin,
>   File "virtManager/details/details.py", line 389, in __init__
>     self._init_details()
>   File "virtManager/details/details.py", line 807, in _init_details
>     vmmAddHardware.build_video_combo(self.vm, video_dev)
>   File "virtManager/addhardware.py", line 816, in build_video_combo
>     default = DeviceVideo.default_model(vm.xmlobj)
>   File "virtinst/devices/video.py", line 47, in default_model
>     if (guest.lookup_domcaps().supports_video_virtio() and
>   File "virtinst/guest.py", line 656, in lookup_domcaps
>     if not self._domcaps or not _compare(self._domcaps):
>   File "virtinst/guest.py", line 646, in _compare
>     if self.os.machine and not _compare_machine(domcaps):
>   File "virtinst/guest.py", line 633, in _compare_machine
>     capsinfo = self.lookup_capsinfo()
>   File "virtinst/guest.py", line 674, in lookup_capsinfo
>     self._capsinfo = self.conn.caps.guest_lookup(
>   File "virtinst/capabilities.py", line 319, in guest_lookup
>     raise ValueError(msg)
> ValueError: Host does not support domain type kvm with machine
> 'pc-q35-8.1' for virtualization type 'hvm' with architecture 'x86_64'

This is a regression; according to git-bisect, it was introduced in commit
05fcc7410eee ("virtinst: fix caching of domain capabilities", 2022-07-27).

"lookup_capsinfo" (and "guest_lookup" called by it) are unsuitable for
machine type alias checking (or for anything else) if the domain uses an
emulator that differs from the system default emulator. The information
returned by virConnectGetCapabilities() pertains to the system default
emulator. Thus, when using a non-default emulator, we should either not
call "lookup_capsinfo" for machine type alias checking, *or* we should
suppress the exception, and pretend that the alias check was a mismatch.

It turns out that we can avoid the "lookup_capsinfo" call (and thereby the
exception) in practice if we just delay the call until after the direct
(non-alias) comparison.

Fixes: #539
Fixes: 05fcc7410eee ("virtinst: fix caching of domain capabilities", 2022-07-27)
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
2023-08-29 13:24:52 +02:00
Cole Robinson
7cd6151a21 uitests: Drop hotplug work around, f38 libvirt is fixed now
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2023-05-24 12:49:02 -04:00
Daniel P. Berrangé
6258d53689 rpm: convert license to SPDX format
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2023-05-07 12:40:05 -04:00
Cole Robinson
64bd6ba53e tests: uitests: make menu operations more robust
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2023-05-06 19:43:24 -04:00
Cole Robinson
509c95ddb9 uitests: More attempts at making manager reposition test reliable
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2023-05-06 19:43:24 -04:00
Cole Robinson
75422ec75e uitests: Make hotplug test pass on both f37 and f38
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2023-05-06 19:43:24 -04:00
Cole Robinson
a9cf4945b1 tests: Default --uitests to --verbosity=2
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2023-05-06 16:50:20 -04:00
Cole Robinson
6030049cd7 tests: uitests: Fix manager window repositioning test
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2023-05-05 15:48:24 -04:00
Cole Robinson
7f83d23f4f tests: livetests: work around qemu media change regression
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2023-05-05 15:47:25 -04:00
Cole Robinson
909c8aa880 tests: uitests: Fix window reposition on f38
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2023-05-05 14:54:31 -04:00
Thomas Huth
102fe52165 man/virt-install: Add a note about different behavior of --boot on s390x
It is common on x86 and other architectures to install a guest from
network by using "--boot hd,network" with virt-install - as long as
the hard disk is not bootable yet, the installation will be started
via network, and once it finished, the guest can boot from hd during
the next reboot.

However, this does not work on s390x since this architecture only
supports one single boot device to be passed to the guest. Thus add
a note to the documentation to avoid that people are running again
into this common pitfall.

Buglink: https://bugzilla.redhat.com/show_bug.cgi?id=2032472
Signed-off-by: Thomas Huth <thuth@redhat.com>
2023-03-22 17:45:31 -04:00
Oleg Vasilev
7769548411 tests: cli: test serial file clone
Previous commit added serial file clone, now we test it.

Signed-off-by: Oleg Vasilev <oleg.vasilev@virtuozzo.com>
2023-03-22 17:44:06 -04:00
Oleg Vasilev
b2f6e95383 cloner: clone serial files
Before this, on clone the serial file would remain the same for the cloned
domain. This doesn't make much sense as the output would be an intermix of two
unrelated output sequences.

Here we apply the the same filename changing algorithm, as with disk files.

Signed-off-by: Oleg Vasilev <oleg.vasilev@virtuozzo.com>
2023-03-22 17:44:06 -04:00
Andrea Bolognani
33ff193ee9 virt-install: Document Secure Boot setups
Provide ready to use recipes for explicitly enabling and
explicitly disabling Secure Boot, as well as a pointer to
the more extensive information found on the libvirt website.

Setting loader_secure=yes is only one part of a proper Secure
Boot setup, so stop documenting it in the section about manual
firmware selection to avoid confusion.

https://bugzilla.redhat.com/show_bug.cgi?id=2112154
https://bugzilla.redhat.com/show_bug.cgi?id=2149971

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2023-02-09 11:41:00 -05:00
Andrea Bolognani
f2b5aaf458 virt-install: Recommend '--boot uefi'
Firmware autoselection is the way to go in most cases, so
recommend that instead of telling users that they should provide
all information manually.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2023-02-09 11:41:00 -05:00
Lokesh Mandvekar
a63b40aae3 Packit: initial enablement
This commit enables Packit `copr_build` tasks which will run on every PR
and build RPMS using the spec file present upstream with Source0 as
the archive created from HEAD commit of the PR.

Signed-off-by: Lokesh Mandvekar <lsm5@fedoraproject.org>
2023-01-19 14:04:42 -05:00
Cole Robinson
fe86f4639f asyncjob: Remove unused import
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2023-01-19 11:59:20 -05:00
Cole Robinson
5c49151df9 tests: test win11 XML generation
And drop the futureproofing workaround now that it's no longer
required

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2023-01-19 11:54:03 -05:00
Cole Robinson
cc4a39ea94 asyncjob: Fix backtrace when no cursor theme installed
Fixes: https://github.com/virt-manager/virt-manager/issues/479

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2023-01-19 11:40:37 -05:00
Toshiki Sonoda
6ec00474a6 virtinstall: Hide total_size in the progress bar if it doesn't need
virt-install prints the total_size value to the progress bar even if it
is meaningless.
This value can be confusing to user, so for execute prosess that doesn't
copy files (total_size = 0B), we hide the total_size value.
For example, 'Creating domain...' doesn't need to print the total_size
value.

Signed-off-by: Toshiki Sonoda <sonoda.toshiki@fujitsu.com>
Signed-off-by: Haruka Ohata <ohata.haruka@fujitsu.com>
2022-12-14 13:18:36 -05:00
Toshiki Sonoda
39c7a44314 virtinstall: Fix the allocating disk size printed by the progress bar
When a sparse file is created during a disk allocation,
virt-install prints not the created disk size but a sparse file size.

Therefore, we fix to print the created disk size during disk allocation
instead of the size of the sparse file by updating the meter with the
self.capacity.

Signed-off-by: Toshiki Sonoda <sonoda.toshiki@fujitsu.com>
Signed-off-by: Haruka Ohata <ohata.haruka@fujitsu.com>
2022-12-14 13:07:26 -05:00
Cole Robinson
4114fa1aa8 progress: Fix showing correct final total
Reproducer:
Reproducer:
./virt-install --connect test:///default \
               --location tests/data/fakemedia/fake-f26-netinst.iso

Before:
Starting install...
Retrieving 'vmlinuz'                            |    0 B  00:00:00 ...
Retrieving 'initrd.img'                         |    0 B  00:00:00 ...

After:
Starting install...
Retrieving 'vmlinuz'                            |    9 B  00:00:00 ...
Retrieving 'initrd.img'                         |    9 B  00:00:00 ...

progress.end() currently only reports the total amount of bytes
that were last written to the UI. It should report the total amount
that's been passed to update().

Reported-by: Toshiki Sonoda <sonoda.toshiki@fujitsu.com>
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-12-14 13:01:48 -05:00
Cole Robinson
b5d6dfaa0d tests: Update to latest kvm domcaps
And add some test coverage exclusions, needed for previous patches

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-12-14 12:45:05 -05:00
Lin Ma
c313209455 tests: Add domcaps coverage for usb-redir/spicevmc channel checks
Signed-off-by: Lin Ma <lma@suse.com>
2022-12-14 12:44:54 -05:00
Lin Ma
180154d752 guest: Query availability of spicevmc channels in domcaps
Signed-off-by: Lin Ma <lma@suse.com>
2022-12-14 12:44:54 -05:00
Lin Ma
8cc6ee8da3 guest: Query availability of usb redirdevs in domcaps
Signed-off-by: Lin Ma <lma@suse.com>
2022-12-14 12:44:54 -05:00
Cole Robinson
cbc5b89707 Clean up FileChooser usage a bit
* Move browse_reason handling entirely into storagebrowser.py
* Open code some of the browse_local logic at the few callers

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-12-14 12:31:17 -05:00
Cole Robinson
67832d3097 addhardware: Fix backtrace when controller.index is None
When creating a new VM, in the customize wizard we can't depend on
index= value being set (virtinst doesn't do it for example).

For example, this causes a backtrace when adding two virtio-scsi
controllers via the Customize wizard, or adding an extra
virtio-scsi controller to an aarch64 CDROM install.

Reported-by: Charles Arnold <carnold@suse.com>
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-12-13 13:49:35 -05:00
Weijia Wang
75a25e3766 tests: cpio: set owner to 0:0 2022-12-13 13:45:16 -05:00
Cole Robinson
bb1afaba29 Fix pylint/pycodestyle warnings with latest versions
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-12-13 11:23:45 -05:00
Lin Ma
4a2df06483 diskbackend: Drop support for sheepdog
The sheepdog project is no longer actively developed, Libvirt removed
the support for sheepdog storage backend since v8.8.0, Let's drop it.

Signed-off-by: Lin Ma <lma@suse.com>
2022-11-07 10:10:00 -05:00
Cole Robinson
15ddeae6cb cli: support --boot loader.stateless=
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-10-17 11:54:37 -04:00
Cole Robinson
1d64a678d3 virt-install: Reuse cli.fail_conflicting
For the --unattended + --cloud-init conflict

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-08-22 10:16:19 -04:00
Cole Robinson
999ccb85e3 virt-install: --unattended and --cloud-init conflict
Make it an explicit error, otherwise unattended is preferred and
cloud-init is ignored

https://bugzilla.redhat.com/show_bug.cgi?id=2117157

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-08-21 16:47:26 -04:00
Cole Robinson
b0d0516736 cloner: Sync <uuid> and <sysinfo> system uuid
Otherwise libvirt errors like:

ERROR    UUID mismatch between <uuid> and <sysinfo>

https://bugzilla.redhat.com/show_bug.cgi?id=2038040

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-08-21 16:21:10 -04:00
Cole Robinson
a254ece0f0 virt-install: --help required options are wrong
Nowadays it could be as simple as `virt-install --install fedora36`.

Trying to represent the interdepencies here is not worth it, but
let's keep a simple string around to avoid the default parser
usage string, which is huge

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-08-21 16:10:55 -04:00
Lin Ma
fbdf051626 cli: --cpu: Add maxphysaddr.{mode,bits} options
This commit added support for cpu physical address bits control, It's
useful for VMs with huge amount of ram.

E.g.
--cpu Cascadelake-Server,maxphysaddr.mode=emulate,maxphysaddr.bits=46

Signed-off-by: Lin Ma <lma@suse.com>
2022-08-20 10:03:11 -04:00
Lin Ma
c22a876e9a tests: Add a compat check for linux2020 in amd-sev test case
It avoids amd-sev test failure if using older osinfo-db.

Signed-off-by: Lin Ma <lma@suse.com>
2022-08-20 09:59:27 -04:00
Cole Robinson
e94786c066 virtinstall: fix regression with --boot and no install method
Anything passed to --boot should imply --install no_install=yes
in the absence of other --install options. This is historically
what we've done but we regressed in 4.1.0

Resolves: https://github.com/virt-manager/virt-manager/issues/426

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-08-20 09:54:01 -04:00
Cole Robinson
1cb0be4002 virtinstall: split no_install conditional apart to track code coverage
Each bit here is part of the CLI API, we need to be sure we are
covering each one. Extend the test suite to hit one case we are missing

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-08-20 09:47:49 -04:00
Cole Robinson
1b87e3e54c tests: testdriver: Add filesystem socket example
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-08-17 10:29:31 -04:00
Cole Robinson
4b15073572 cli: Drop unnecessary --disk prop aliases
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-08-17 10:27:36 -04:00
Lin Ma
58f5e36da7 fsdetails: Fix an error with source.socket of virtiofs
Using the source.socket of virtiofs needs a virtiofsd daemon launched
outside of libvirtd, So the filesystem UI doesn't support it yet. If
users need it they can set it manually in the XML editor.
But if we view the filesystem info of such a VM on the details page,
It fails with this error message:

Traceback (most recent call last):
  File "/usr/share/virt-manager/virtManager/details/details.py", line 1713, in _refresh_page
    self._refresh_filesystem_page(dev)
  File "/usr/share/virt-manager/virtManager/details/details.py", line 2241, in _refresh_filesystem_page
    self.fsDetails.set_dev(dev)
  File "/usr/share/virt-manager/virtManager/device/fsdetails.py", line 193, in set_dev
    self.widget("fs-source").set_text(dev.source)
TypeError: Argument 1 does not allow None as a value

This patch fixes above issue by leaving the 'source path' info blank in
case of source.socket.
In this case, Considering that showing 'target path' info without source
info is kind of meaningless, So this patch leaves the 'target path' info
blank as well.

Signed-off-by: Lin Ma <lma@suse.com>
2022-08-17 10:24:10 -04:00
Cole Robinson
7295ebfb02 tests: cli: Fix test output after previous commit
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-08-17 10:21:31 -04:00
Lin Ma
11a887ece5 cli: --disk: Add driver.metadata_cache options
Properly setting the metadata cache size can provide better performance
in case of using big qcow2 images.

This patch introduces two driver options:
* driver.metadata_cache.max_size
* driver.metadata_cache.max_size.unit

E.g. --disk ...,driver.type=qcow2,\
     driver.metadata_cache.max_size=2,\
     driver.metadata_cache.max_size.unit=MiB

BTW, Metadata cache size control is currently supported only for qcow2.
Regarding how to properly caluclate the cache size of qcow2, Please refer
to qemu's documentation.

Signed-off-by: Lin Ma <lma@suse.com>
2022-08-17 09:57:29 -04:00
Cole Robinson
8ca7c91697 Prep for release 4.1.0
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-08-04 15:53:33 -04:00
Cole Robinson
661408bcc7 po: Refresh translation template
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-08-04 15:14:20 -04:00
Gogo Gogsi
7177223716 Translated using Weblate (Croatian)
Currently translated at 38.2% (555 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/hr/

Translated using Weblate (Croatian)

Currently translated at 8.6% (125 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/hr/
2022-08-04 15:07:50 -04:00
Kisaragi Hiu
95779a6350 Translated using Weblate (Chinese (Traditional) (zh_TW))
Currently translated at 99.7% (1447 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_TW/

Translated using Weblate (Chinese (Traditional) (zh_TW))

Currently translated at 99.7% (1447 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_TW/

Translated using Weblate (Chinese (Traditional) (zh_TW))

Currently translated at 98.7% (1433 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_TW/
2022-08-04 15:07:50 -04:00
Ettore Atalan
bd7adae146 Translated using Weblate (German)
Currently translated at 82.1% (1192 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/de/
2022-08-04 15:07:50 -04:00
김인수
73a12f8c98 Translated using Weblate (Korean)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/

Translated using Weblate (Korean)

Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/
2022-08-04 15:07:50 -04:00
Morten Abildgaard
1953847807 Translated using Weblate (Danish)
Currently translated at 18.3% (266 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/da/
2022-08-04 15:07:50 -04:00
R Toda
69ce106681 Translated using Weblate (Japanese)
Currently translated at 96.7% (1404 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ja/
2022-08-04 15:07:50 -04:00
Gustavo Costa
2d3812bd43 Translated using Weblate (Portuguese (Brazil))
Currently translated at 95.5% (1386 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/

Translated using Weblate (Portuguese (Brazil))

Currently translated at 95.5% (1386 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/
2022-08-04 15:07:50 -04:00
Alexey Rubtsov
e05fd9d1f7 Translated using Weblate (Russian)
Currently translated at 95.8% (1391 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ru/
2022-08-04 15:07:50 -04:00
Miguel Ángel Sánchez
e60063f0ee Translated using Weblate (Spanish)
Currently translated at 85.8% (1246 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/
2022-08-04 15:07:50 -04:00
Jan Kuparinen
951df8a803 Translated using Weblate (Finnish)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fi/
2022-08-04 15:07:50 -04:00
Nicholas Di Nicola
3182b7edb5 Translated using Weblate (Spanish)
Currently translated at 85.8% (1246 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/
2022-08-04 15:07:50 -04:00
Pavel Borecki
b475bd933b Translated using Weblate (Czech)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/cs/

Translated using Weblate (Czech)

Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/cs/

Translated using Weblate (Czech)

Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/cs/
2022-08-04 15:07:50 -04:00
Temuri Doghonadze
c92b300984 Translated using Weblate (Georgian)
Currently translated at 85.5% (1239 of 1448 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ka/

Translated using Weblate (Georgian)

Currently translated at 80.9% (1172 of 1448 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ka/

Translated using Weblate (Georgian)

Currently translated at 80.8% (1170 of 1448 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ka/

Translated using Weblate (Georgian)

Currently translated at 78.7% (1141 of 1448 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ka/

Added translation using Weblate (Georgian)
2022-08-04 15:07:50 -04:00
Hela Basa
809a34a5eb Translated using Weblate (Sinhala)
Currently translated at 0.1% (1 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/si/
2022-08-04 15:07:50 -04:00
Anonymous
7cac6793a5 Translated using Weblate (Sinhala)
Currently translated at 0.1% (1 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/si/
2022-08-04 15:07:50 -04:00
Anonymous
b09b210f46 Translated using Weblate (Kabyle)
Currently translated at 0.0% (0 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/kab/
2022-08-04 15:07:50 -04:00
Whired Planck
9d763b07c6 Translated using Weblate (Chinese (Traditional) (zh_TW))
Currently translated at 95.5% (1387 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_TW/
2022-08-04 15:07:50 -04:00
Anonymous
1eb0e11a24 Translated using Weblate (Chinese (Traditional) (zh_TW))
Currently translated at 95.5% (1387 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_TW/
2022-08-04 15:07:50 -04:00
Pavel Hrdina
182a37f0d3 Translated using Weblate (Chinese (Simplified) (zh_CN))
Currently translated at 95.9% (1392 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_CN/
2022-08-04 15:07:50 -04:00
Anonymous
d8f39762cb Translated using Weblate (Chinese (Simplified) (zh_CN))
Currently translated at 95.9% (1392 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_CN/
2022-08-04 15:07:50 -04:00
Whired Planck
228add0750 Translated using Weblate (Chinese (Simplified) (zh_CN))
Currently translated at 95.9% (1392 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_CN/
2022-08-04 15:07:50 -04:00
Kim InSoo
cc6cdb619c Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2022-08-04 15:07:50 -04:00
Taras Panchenko
edf2e81fa0 Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2022-08-04 15:07:50 -04:00
Anonymous
3ede889a36 Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2022-08-04 15:07:50 -04:00
Yuri Chornoivan
61da05c7c1 Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2022-08-04 15:07:50 -04:00
Anonymous
0e3a42c9fa Translated using Weblate (Turkish)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/tr/
2022-08-04 15:07:50 -04:00
Oğuz Ersen
57f0f6fc7e Translated using Weblate (Turkish)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/tr/
2022-08-04 15:07:50 -04:00
Anonymous
6486168eac Translated using Weblate (Telugu)
Currently translated at 56.5% (820 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/te/
2022-08-04 15:07:50 -04:00
Anonymous
4fb4c14889 Translated using Weblate (Tamil)
Currently translated at 56.5% (820 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ta/
2022-08-04 15:07:50 -04:00
Jonatan Nyberg
5588d4eca1 Translated using Weblate (Swedish)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sv/
2022-08-04 15:07:50 -04:00
Luna Jernberg
be9f9ff45f Translated using Weblate (Swedish)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sv/
2022-08-04 15:07:50 -04:00
Göran Uddeborg
00be3a6ab1 Translated using Weblate (Swedish)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sv/
2022-08-04 15:07:50 -04:00
Anonymous
935697a4c5 Translated using Weblate (Swedish)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sv/
2022-08-04 15:07:50 -04:00
Anonymous
434322d5d7 Translated using Weblate (Serbian (latin))
Currently translated at 5.4% (79 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sr_Latn/
2022-08-04 15:07:50 -04:00
Марко Костић (Marko Kostić)
9f2ed4ac6a Translated using Weblate (Serbian)
Currently translated at 19.8% (288 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sr/
2022-08-04 15:07:50 -04:00
Anonymous
75f85d616b Translated using Weblate (Serbian)
Currently translated at 19.8% (288 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sr/
2022-08-04 15:07:50 -04:00
Anonymous
c987410779 Translated using Weblate (Slovak)
Currently translated at 42.5% (618 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sk/
2022-08-04 15:07:50 -04:00
Alexey Rubtsov
283bb0a882 Translated using Weblate (Russian)
Currently translated at 95.7% (1390 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ru/
2022-08-04 15:07:50 -04:00
Dmitry Astankov
dbc6437c83 Translated using Weblate (Russian)
Currently translated at 95.7% (1390 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ru/
2022-08-04 15:07:50 -04:00
0784b69ea5 Translated using Weblate (Russian)
Currently translated at 95.7% (1390 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ru/
2022-08-04 15:07:50 -04:00
Anonymous
3710a03d5b Translated using Weblate (Russian)
Currently translated at 95.7% (1390 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ru/
2022-08-04 15:07:50 -04:00
Anonymous
53874bdecc Translated using Weblate (Romanian)
Currently translated at 3.0% (44 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ro/
2022-08-04 15:07:50 -04:00
José Lemos
2d9b92e6a3 Translated using Weblate (Portuguese (Brazil))
Currently translated at 91.5% (1329 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/
2022-08-04 15:07:50 -04:00
Renan Birck Pinheiro
553ccba2ea Translated using Weblate (Portuguese (Brazil))
Currently translated at 91.5% (1329 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/
2022-08-04 15:07:50 -04:00
Lucas Fernandes
adad21fb40 Translated using Weblate (Portuguese (Brazil))
Currently translated at 91.5% (1329 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/
2022-08-04 15:07:50 -04:00
Rodrigo Tavares
cd4587844e Translated using Weblate (Portuguese (Brazil))
Currently translated at 91.5% (1329 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/
2022-08-04 15:07:50 -04:00
Gustavo Costa
f5d483c7c6 Translated using Weblate (Portuguese (Brazil))
Currently translated at 91.5% (1329 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/
2022-08-04 15:07:50 -04:00
Anonymous
1901408c14 Translated using Weblate (Portuguese (Brazil))
Currently translated at 91.5% (1329 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/
2022-08-04 15:07:50 -04:00
Anonymous
6172218280 Translated using Weblate (Portuguese)
Currently translated at 67.6% (982 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt/
2022-08-04 15:07:50 -04:00
Piotr Drąg
d6d1acfa9d Translated using Weblate (Polish)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pl/
2022-08-04 15:07:50 -04:00
Anonymous
7674cd2989 Translated using Weblate (Polish)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pl/
2022-08-04 15:07:50 -04:00
Anonymous
c1ef4d889b Translated using Weblate (Punjabi)
Currently translated at 45.7% (664 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pa/
2022-08-04 15:07:50 -04:00
Anonymous
05ba21c2a8 Translated using Weblate (Odia)
Currently translated at 40.5% (588 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/or/
2022-08-04 15:07:50 -04:00
Geert Warrink
312cf4bbdd Translated using Weblate (Dutch)
Currently translated at 47.8% (694 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/nl/
2022-08-04 15:07:50 -04:00
Anonymous
098acb65ab Translated using Weblate (Dutch)
Currently translated at 47.8% (694 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/nl/
2022-08-04 15:07:50 -04:00
Anonymous
293d5c760e Translated using Weblate (Norwegian Bokmål)
Currently translated at 3.0% (44 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/nb_NO/
2022-08-04 15:07:50 -04:00
Anonymous
346a819356 Translated using Weblate (Malay)
Currently translated at 1.4% (21 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ms/
2022-08-04 15:07:50 -04:00
Anonymous
3571f11193 Translated using Weblate (Marathi)
Currently translated at 56.5% (820 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/mr/
2022-08-04 15:07:50 -04:00
Anonymous
c5a94b4681 Translated using Weblate (Malayalam)
Currently translated at 51.8% (752 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ml/
2022-08-04 15:07:50 -04:00
Seungyeon Choi
0a749ce1c3 Translated using Weblate (Korean)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/
2022-08-04 15:07:50 -04:00
Anonymous
540e189885 Translated using Weblate (Korean)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/
2022-08-04 15:07:49 -04:00
Kim InSoo
17169b1681 Translated using Weblate (Korean)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/
2022-08-04 15:07:49 -04:00
Anonymous
a6188adf31 Translated using Weblate (Kannada)
Currently translated at 56.5% (820 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/kn/
2022-08-04 15:07:49 -04:00
Anonymous
ef8fe43d30 Translated using Weblate (Japanese)
Currently translated at 96.1% (1395 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ja/
2022-08-04 15:07:49 -04:00
Yasuhiko Kamata
d4e5dbd294 Translated using Weblate (Japanese)
Currently translated at 96.1% (1395 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ja/
2022-08-04 15:07:49 -04:00
Frediano Ziglio
dbcb72aa54 Translated using Weblate (Italian)
Currently translated at 96.0% (1393 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2022-08-04 15:07:49 -04:00
Fabio Tomat
ad733e8aa0 Translated using Weblate (Italian)
Currently translated at 96.0% (1393 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2022-08-04 15:07:49 -04:00
Pino Toscano
eaa9dfb5a6 Translated using Weblate (Italian)
Currently translated at 96.0% (1393 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2022-08-04 15:07:49 -04:00
Anonymous
deb7ac3191 Translated using Weblate (Italian)
Currently translated at 96.0% (1393 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2022-08-04 15:07:49 -04:00
Anonymous
3682d9c212 Translated using Weblate (Icelandic)
Currently translated at 1.0% (15 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/is/
2022-08-04 15:07:49 -04:00
Anonymous
b94630e534 Translated using Weblate (Indonesian)
Currently translated at 13.9% (202 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/
2022-08-04 15:07:49 -04:00
Andika Triwidada
5b3e463ff5 Translated using Weblate (Indonesian)
Currently translated at 13.9% (202 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/
2022-08-04 15:07:49 -04:00
Kukuh Syafaat
ad3f2fa1a6 Translated using Weblate (Indonesian)
Currently translated at 13.9% (202 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/
2022-08-04 15:07:49 -04:00
Teknős Ferenc
d2e276474e Translated using Weblate (Hungarian)
Currently translated at 52.9% (768 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/hu/
2022-08-04 15:07:49 -04:00
Dankaházi (ifj.) István
0d2ed0ac6d Translated using Weblate (Hungarian)
Currently translated at 52.9% (768 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/hu/
2022-08-04 15:07:49 -04:00
Anonymous
1ac2d7a11b Translated using Weblate (Hungarian)
Currently translated at 52.9% (768 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/hu/
2022-08-04 15:07:49 -04:00
Anonymous
3266630980 Translated using Weblate (Croatian)
Currently translated at 4.4% (64 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/hr/
2022-08-04 15:07:49 -04:00
Anonymous
ac3f2387e5 Translated using Weblate (Hindi)
Currently translated at 38.2% (555 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/hi/
2022-08-04 15:07:49 -04:00
Anonymous
02832d6c11 Translated using Weblate (Gujarati)
Currently translated at 54.8% (796 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/gu/
2022-08-04 15:07:49 -04:00
Fabio Tomat
aa8e0f5974 Translated using Weblate (Friulian)
Currently translated at 87.5% (1270 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fur/
2022-08-04 15:07:49 -04:00
Anonymous
f16594e32d Translated using Weblate (Friulian)
Currently translated at 87.5% (1270 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fur/
2022-08-04 15:07:49 -04:00
Github Actions
d29ea36d92 Refresh translation .pot template 2022-08-04 15:07:49 -04:00
Cole Robinson
e132cb6fcd tests: test_inject: Drop --debug usage
Otherwise it scrolls output too fast and user doesn't notice the
instructions

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-08-04 15:06:17 -04:00
Cole Robinson
5e48307e9d virtinstall: Set VM name earlier so disks are named correctly
We need to change the flow from

  * parse all the strings
  * set capabilities defaults
  * build installer
  * fill in all guest defaults

To

  * parse boot and metadata strings
  * set capabilities defaults
  * build installer
  * set --name default
  * parse all the remaining strings
  * fill in all guest defaults

Because --disk parsing depends on --name for some path generation.
So this fixes --disk names when --name is implicitly specified by
--install or --osinfo

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-08-03 12:34:47 -04:00
Cole Robinson
02e6abad48 cli: Break up parse_option_strings
Into run_parser and run_all_parsers. Opencode some of the special
case handling in virtxml

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-08-03 12:34:47 -04:00
Cole Robinson
e2dfbf9bd9 virt-xml: Simplify --build-xml parse_option_strings usage
parse_option_strings will do the right thing for us already

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-08-03 12:34:47 -04:00
Cole Robinson
bfa37d0065 xmlutil: Take unindent_device_xml from details.py
We will use this in virt-xml soon

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-08-03 12:34:47 -04:00
Cole Robinson
d2b346370a virtxml: Remove redundant listify calls
parse_option_strings always returns a list

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-08-03 12:34:47 -04:00
Cole Robinson
4ca0d2c29b tests: More trailing newline fixes
The diff_compare rstrip() should never have been added, let's fix
it once and for all but dealing with missing newlines in the diff
helper

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-08-03 12:34:47 -04:00
Cole Robinson
effe274a9b tests: test_urls: Update fedora links
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-08-03 11:44:25 -04:00
Charles Arnold
424283ad1d launch_security: Use SEV-ES policy=0x07 if host supports it 2022-08-03 08:47:35 -04:00
Lin Ma
2984c13cff cli: Add --iothreads defaultiothread.thread_pool_{min,max}
It allows to set the thread pool size to optimize spawning worker threads
for the default event loop in real time environment. For example:

--iothreads defaultiothread.thread_pool_min=8,\
defaultiothread.thread_pool_max=16

Signed-off-by: Lin Ma <lma@suse.com>
2022-08-02 14:56:09 -04:00
Miro Hrončok
90e13549b4 Fix build with setuptools 61+
+ ./setup.py configure --default-hvs qemu,xen,lxc
    error: Multiple top-level packages discovered in a flat-layout: ['po', 'ui', 'man', 'data', 'virtinst', 'virtManager'].
    To avoid accidental inclusion of unwanted files or directories,
    setuptools will not proceed with this build.
    If you are trying to create a single distribution with multiple packages
    on purpose, you should not rely on automatic discovery.
    Instead, consider the following options:
    1. set up custom discovery (`find` directive with `include` or `exclude`)
    2. use a `src-layout`
    3. explicitly set `py_modules` or `packages` with a list of names
    To find more information, look for "package discovery" on setuptools docs.

Downstream bug report: https://bugzilla.redhat.com/2113754
2022-08-02 12:05:39 -04:00
Lin Ma
0d84bcfbfa cli: Add iothreadids attributes thread_pool_min and thread_pool_max
These two optional attributes allow setting lower and upper boundary for
number of worker threads for given IOThread. For example:

--iothreads iothreads=2,\
iothreadids.iothread0.id=1,\
iothreadids.iothread1.id=2,\
iothreadids.iothread1.thread_pool_min=8,\
iothreadids.iothread1.thread_pool_max=16

Signed-off-by: Lin Ma <lma@suse.com>
2022-08-01 11:32:23 -04:00
Cole Robinson
58ffe7fa7a tests: uitests: livetests: Fix LXC domain cleanup
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-08-01 10:38:01 -04:00
Lin Ma
b8a77805b0 domain: cpu: Clear 'migratable' when changing to custom cpu
Otherwise going host-passthrough -> custom can cause libvirt validation
error due to libvirt fills the default value(migratable='on') for the
host-passthrough in domain XML.

Signed-off-by: Lin Ma <lma@suse.com>
2022-08-01 10:11:43 -04:00
Feng Jiang
cf2c28ada1 ui: Fix too wide lables
When some lables have too much content, they will become very wide,
causing the window to widen.

Signed-off-by: Feng Jiang <jiangfeng@kylinos.cn>
2022-08-01 10:10:41 -04:00
Cole Robinson
e7c936f16e vmwindow: Customize window should not be 'deletable'
This forces the user to use the 'Cancel' button, which gives a warning
about the install being aborted

Resolves: https://github.com/virt-manager/virt-manager/issues/416

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-08-01 09:44:48 -04:00
Cole Robinson
6287760ed0 tests: Fix memdev uuid testing with libvirt.git
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-08-01 06:46:41 -04:00
Cole Robinson
35871fe96b capabilities: Remove noisy alias debugging
our debugging output is not this fine grained, so this crowds out
more interesting messages

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-08-01 06:04:48 -04:00
Cole Robinson
8079c421bd connection: De-duplicate ui and cli version logging
Remove the open coded version logging in cli.py and virt-manager
connection.py, and move it into virtinst connection open

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-08-01 06:04:48 -04:00
Cole Robinson
aeffa4f711 guest: Check coverage for more of domcaps caching
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-07-27 18:07:05 -04:00
Daniel P. Berrangé
92ba8e5d35 virtinst: log libvirt version numbers after connecting
The various version numbers reported by libvirt are all relevant pieces
of information when debugging problem reports.

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2022-07-27 17:53:14 -04:00
Daniel P. Berrangé
01ff867f56 virtinst: include the version number in first log message
Knowledge of the version number is not always available from the user
bug report. They may merely have a log file from an automated system.
Including the version number in the log message is key information.

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2022-07-27 17:53:14 -04:00
Daniel P. Berrangé
b5e8e58d74 virtinst: include host capbilities in debug log
This is critical information when debugging many user problems.

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2022-07-27 17:53:14 -04:00
Daniel P. Berrangé
fec5fd84a7 virtinst: include domain capbilities in debug log
This is critical information when debugging many user problems.

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2022-07-27 17:53:14 -04:00
Daniel P. Berrangé
05fcc7410e virtinst: fix caching of domain capabilities
The domain capabilities XML always contains the canonical machine name.
When the selected machine type for a guest is an alias, the check
comparing it to the domain capabilities machine will always fail. This
prevents the domain capabilities result from being cached.

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2022-07-27 17:53:14 -04:00
Cole Robinson
a4a5c1529a tests: Fix with latest libvirt
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-07-27 17:51:21 -04:00
Cole Robinson
7ae10b5566 cli: Add --serial source.tls=on|off
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-06-20 18:06:40 -04:00
Cole Robinson
137cfdc347 cli: Add --serial source.channel
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-06-20 18:03:55 -04:00
Cole Robinson
d0e6213643 cli: Add --memorybacking allocation.threads
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-06-20 17:54:50 -04:00
Cole Robinson
d51541e155 Fix UI rename with firmware='efi'
Our code to duplicate nvram wasn't expecting the XML to be devoid
of an nvram path.

Resolves: https://github.com/virt-manager/virt-manager/issues/372

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-06-20 09:37:26 -04:00
Cole Robinson
9da917b8ac connection: Add get_libvirt_data_root_dir()
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-06-20 09:10:59 -04:00
Cole Robinson
280c30736f tests: Fix test skipping with old osinfo-db
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-06-18 17:42:44 -04:00
Cole Robinson
48f66f27fd domcaps: armv7l doesn't support tpm-tis
Libvirt domcaps can advertise armv7l support for tpm-tis, even though
it will explicitly reject that config:

https://gitlab.com/libvirt/libvirt/-/issues/329

Work around that in domcaps. Without this, UEFI arm32 VMs generate
default configs that libvirt will reject

https://bugzilla.redhat.com/show_bug.cgi?id=2078995

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-06-17 13:09:39 -04:00
Ryan Schmidt
49c2e046a1 Install before updating cache & compiling schemas
Closes #400
2022-06-13 15:18:19 -04:00
Cole Robinson
3db783dab2 tests: caps: Update with newer amd sev caps
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-06-13 14:32:02 -04:00
Cole Robinson
686603eabe tests: Add an explicit test for old host-model default
when caps does not report that libvirt is new enough to default
to host-passthrough

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-06-13 14:29:18 -04:00
Cole Robinson
eb613283d5 Update mailmap
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-06-13 13:49:54 -04:00
Cole Robinson
64dfb6c595 details: Go back to old Channel naming format
The new format is too long and wordy IMO. It was added to handle
qemu-vdagent ambiguity, since without it we would print the same string
for spicevmc and qemu-vgagent channel. Let's just special case
qemu-vdagent to solve that problem

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-06-13 13:49:08 -04:00
Cole Robinson
bfe17ce627 osdict: Fix test coverage with latest libosinfo
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-06-13 13:49:08 -04:00
Jonathon Jongsma
caa99a6001 virt-manager: add support for qemu-vdagent channel
This provides the UI support for the qemu-vdagent channel which allows
 clipboard sharing with VNC graphics (see previous commit for more
 information).

 The channel name in the device list was changed slightly in order to
 avoid confusion. Due to the fact that both the spice-vdagent and the
 qemu-vdagent specify the same virtio name (com.redhat.spice.0), both of
 these channels were showing up in the device list as "Channel spice",
 which is a bit confusing.

 In order to disambiguate these, channels now show up in the device list
 as "Channel {type} ({name})" instead of "Channel {name}". So for
 example, a qemu-vdagent channel would show up as:
    Channel Qemu vdagent (spice)
Whereas a spice-vdagent channel would show up as:
    Channel Spice agent (spice)

Signed-off-by: Jonathon Jongsma <jjongsma@redhat.com>
2022-06-13 13:49:08 -04:00
Jonathon Jongsma
44355e5ed0 virt-install: add support for qemu-vdagent channel
This allows support for host/guest clipboard sharing when using vnc
guests (and possibly other graphics types in the future). This channel
is similar to the spicevmc channel, but it contains a couple additional
options to enable/disable clipboard sharing and specify the mouse mode.
In the case of spice, these settings are specified on the 'graphics'
element, but for qemu-vdagent, they are specified on the channel. For
example:

   --channel=qemu-vdagent,source.clipboard.copypaste=on,source.mouse.mode=client

Signed-off-by: Jonathon Jongsma <jjongsma@redhat.com>
2022-06-13 13:49:08 -04:00
Cole Robinson
0533bb8189 tests: Fix with latest osinfo-db
linux2020 is now reporting virtio-gpu support, adjust output and
add a compat check

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-06-13 13:20:01 -04:00
Cole Robinson
34662fecc9 tests: Fix with latest argcomplete
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-06-13 13:20:01 -04:00
Cole Robinson
ddead32287 virtmanager: Remove executable bit
rpmbuild complains about it

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-04-13 08:36:05 -04:00
Martin Kletzander
a62e3df72f Add support for URL query with disks
Signed-off-by: Martin Kletzander <mkletzan@redhat.com>
2022-04-13 08:35:50 -04:00
Cole Robinson
9ac94ef739 tests: Fix another sgio=filtered case
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-04-13 08:35:50 -04:00
Peter Alfredsen
46dc061630 setup: add bits for setuptools-61
Quoting https://github.com/pypa/setuptools/issues/3227
"Setuptools >= 61, intentionally changes the way packages are built in the
 sensec that it will try to find files and fail if something is weird.

 Empty packages (like this one), are asked to explicitly add packages=[]
 to their configuration.

 This intentional change in behaviour is described in
 https://setuptools.pypa.io/en/latest/history.html#v61-0-0."

Bug: https://bugs.gentoo.org/836645
Signed-off-by: Peter Alfredsen <crabbedhaloablution@icloud.com>
2022-04-13 08:35:40 -04:00
Cole Robinson
c61074191d tests: Drop usage of sgio=unfiltered
libvirt 8.1.0+ rejects it, so it breaks the testsuite

Fixes: #382

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-04-13 07:00:37 -04:00
Cole Robinson
d12be94f40 DESIGN.md: disk serial is back, but disk detect zeroes is gone
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-03-09 13:30:16 -05:00
Cole Robinson
e924dfb389 Prep for release 4.0.0
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-03-02 12:44:04 -05:00
Weblate
05136e3843 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2022-03-02 12:26:50 -05:00
Oğuz Ersen
54dff28b38 Translated using Weblate (Turkish)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/tr/
2022-03-02 12:26:50 -05:00
Göran Uddeborg
6ec0774d92 Translated using Weblate (Swedish)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sv/
2022-03-02 12:26:50 -05:00
Kim InSoo
afe5527071 Translated using Weblate (Korean)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/
2022-03-02 12:26:50 -05:00
Piotr Drąg
907ab9eee5 Translated using Weblate (Polish)
Currently translated at 99.9% (1450 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pl/
2022-03-02 12:26:50 -05:00
Kim InSoo
7c443dd9e8 Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1451 of 1451 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2022-03-02 12:26:50 -05:00
Weblate
2672296713 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2022-03-02 12:26:50 -05:00
Yuri Chornoivan
c0433e7aa1 Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1449 of 1449 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2022-03-02 12:26:50 -05:00
Oğuz Ersen
373357e3fe Translated using Weblate (Turkish)
Currently translated at 100.0% (1449 of 1449 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/tr/
2022-03-02 12:26:50 -05:00
Göran Uddeborg
37ef41cc7c Translated using Weblate (Swedish)
Currently translated at 100.0% (1449 of 1449 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sv/
2022-03-02 12:26:50 -05:00
Kim InSoo
f2459d6857 Translated using Weblate (Korean)
Currently translated at 100.0% (1449 of 1449 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/
2022-03-02 12:26:50 -05:00
Jan Kuparinen
fc02eb8383 Translated using Weblate (Finnish)
Currently translated at 100.0% (1449 of 1449 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fi/
2022-03-02 12:26:50 -05:00
Weblate
22cf6aea4e Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2022-03-02 12:26:50 -05:00
Göran Uddeborg
5502ba846a Translated using Weblate (Swedish)
Currently translated at 100.0% (1432 of 1432 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sv/
2022-03-02 12:26:50 -05:00
Yuri Chornoivan
a808a68079 Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1432 of 1432 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2022-03-02 12:26:50 -05:00
Oğuz Ersen
f104569e80 Translated using Weblate (Turkish)
Currently translated at 100.0% (1432 of 1432 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/tr/
2022-03-02 12:26:50 -05:00
Kim InSoo
04242d5e18 Translated using Weblate (Korean)
Currently translated at 100.0% (1432 of 1432 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/
2022-03-02 12:26:50 -05:00
Pino Toscano
fc696f2ce4 Translated using Weblate (Italian)
Currently translated at 97.7% (1400 of 1432 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2022-03-02 12:26:50 -05:00
Jan Kuparinen
6b79778423 Translated using Weblate (Finnish)
Currently translated at 100.0% (1432 of 1432 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fi/
2022-03-02 12:26:50 -05:00
Piotr Drąg
e8eeb6416e Translated using Weblate (Polish)
Currently translated at 100.0% (1432 of 1432 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pl/
2022-03-02 12:26:50 -05:00
Weblate
36085cc766 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2022-03-02 12:26:50 -05:00
Luna Jernberg
ef328fcf5a Translated using Weblate (Swedish)
Currently translated at 99.2% (1416 of 1427 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sv/
2022-03-02 12:26:50 -05:00
Yuri Chornoivan
059af9a11e Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1427 of 1427 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2022-03-02 12:26:50 -05:00
Oğuz Ersen
bd720e7395 Translated using Weblate (Turkish)
Currently translated at 100.0% (1427 of 1427 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/tr/
2022-03-02 12:26:50 -05:00
Pavel Borecki
e8aa6de310 Translated using Weblate (Czech)
Currently translated at 100.0% (1427 of 1427 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/cs/
2022-03-02 12:26:50 -05:00
Weblate
acf4a55f72 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2022-03-02 12:26:50 -05:00
Yuri Chornoivan
181676c432 Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1425 of 1425 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2022-03-02 12:26:49 -05:00
Oğuz Ersen
a77380a8ba Translated using Weblate (Turkish)
Currently translated at 100.0% (1425 of 1425 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/tr/
2022-03-02 12:26:49 -05:00
Kim InSoo
3cf9126b83 Translated using Weblate (Korean)
Currently translated at 100.0% (1425 of 1425 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/
2022-03-02 12:26:49 -05:00
Weblate
e776eacb68 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2022-03-02 12:26:49 -05:00
Ettore Atalan
f9f689085c Translated using Weblate (German)
Currently translated at 84.5% (1198 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/de/
2022-03-02 12:26:49 -05:00
Teknős Ferenc
31deb4548a Translated using Weblate (Hungarian)
Currently translated at 54.4% (772 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/hu/
2022-03-02 12:26:49 -05:00
Pedro Luis Valades Viera
703191e837 Translated using Weblate (Spanish)
Currently translated at 88.0% (1247 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/
2022-03-02 12:26:49 -05:00
Ettore Atalan
086adaad14 Translated using Weblate (German)
Currently translated at 84.4% (1197 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/de/
2022-03-02 12:26:49 -05:00
Yasuhiko Kamata
2e8232f331 Translated using Weblate (Japanese)
Currently translated at 100.0% (1417 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ja/
2022-03-02 12:26:49 -05:00
Weblate
f8cf3ea335 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2022-03-02 12:26:49 -05:00
Yasuhiko Kamata
9b78b32453 Translated using Weblate (Japanese)
Currently translated at 100.0% (1417 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ja/
2022-03-02 12:26:49 -05:00
Taras Panchenko
726aa37b1e Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1417 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2022-03-02 12:26:49 -05:00
Lucas Fernandes
b324d13daa Translated using Weblate (Portuguese (Brazil))
Currently translated at 95.0% (1347 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/
2022-03-02 12:26:49 -05:00
Weblate
b68e7da04c Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2022-03-02 12:26:49 -05:00
Fabio Tomat
0d4bdfe6d2 Translated using Weblate (Italian)
Currently translated at 98.5% (1396 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/

Translated using Weblate (Friulian)

Currently translated at 90.9% (1289 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fur/

Translated using Weblate (Friulian)

Currently translated at 89.9% (1275 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fur/
2022-03-02 12:26:49 -05:00
Ettore Atalan
b570ade245 Translated using Weblate (German)
Currently translated at 81.1% (1150 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/de/
2022-03-02 12:26:49 -05:00
Andika Triwidada
a6aacba974 Translated using Weblate (Indonesian)
Currently translated at 14.5% (206 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/
2022-03-02 12:26:49 -05:00
Laurent Bigonville
9d223deb8b Translated using Weblate (French)
Currently translated at 90.4% (1281 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fr/
2022-03-02 12:26:49 -05:00
Github Actions
2f87673fda Refresh translation .pot template 2022-03-02 12:26:49 -05:00
Weblate
0346c4dbf4 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2022-03-02 12:26:49 -05:00
Pedro Luis Valades Viera
4e2626a265 Translated using Weblate (Spanish)
Currently translated at 87.5% (1240 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/

Translated using Weblate (Spanish)

Currently translated at 80.6% (1143 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/

Translated using Weblate (Spanish)

Currently translated at 80.0% (1135 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/

Translated using Weblate (Spanish)

Currently translated at 79.0% (1120 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/
2022-03-02 12:26:49 -05:00
Weblate
0effaf3b28 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2022-03-02 12:26:49 -05:00
Lucas Fernandes
20b5b8c03b Translated using Weblate (Portuguese (Brazil))
Currently translated at 78.6% (1114 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/
2022-03-02 12:26:49 -05:00
Weblate
832da4776c Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2022-03-02 12:26:49 -05:00
Andika Triwidada
474f04a93c Translated using Weblate (Indonesian)
Currently translated at 12.7% (181 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/
2022-03-02 12:26:49 -05:00
Pavel Borecki
37c0844f19 Translated using Weblate (Czech)
Currently translated at 100.0% (1417 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/cs/
2022-03-02 12:26:49 -05:00
Kukuh Syafaat
4187fae0ae Translated using Weblate (Indonesian)
Currently translated at 11.5% (163 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/
2022-03-02 12:26:49 -05:00
Pavel Borecki
4b5db00ca2 Translated using Weblate (Czech)
Currently translated at 100.0% (1417 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/cs/

Translated using Weblate (Czech)

Currently translated at 100.0% (1417 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/cs/
2022-03-02 12:26:49 -05:00
Chris Wehrli
a8691138f0 Translated using Weblate (German)
Currently translated at 79.3% (1125 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/de/
2022-03-02 12:26:49 -05:00
Hela Basa
02e76e1ddc Translated using Weblate (Sinhala)
Currently translated at 0.1% (1 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/si/
2022-03-02 12:26:49 -05:00
Pino Toscano
0d1d676ba2 Translated using Weblate (Italian)
Currently translated at 98.5% (1396 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2022-03-02 12:26:49 -05:00
Luna Jernberg
43f5250b29 Translated using Weblate (Swedish)
Currently translated at 99.9% (1416 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sv/
2022-03-02 12:26:49 -05:00
Jan Kuparinen
296fd3f798 Translated using Weblate (Finnish)
Currently translated at 100.0% (1417 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fi/
2022-03-02 12:25:30 -05:00
Yuri Chornoivan
0f368b50eb Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1417 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2022-03-02 12:25:30 -05:00
Oğuz Ersen
05f2b2ca50 Translated using Weblate (Turkish)
Currently translated at 100.0% (1417 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/tr/
2022-03-02 12:25:30 -05:00
simmon
40f514a0ca Translated using Weblate (Korean)
Currently translated at 100.0% (1417 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/

Translated using Weblate (Korean)

Currently translated at 100.0% (1417 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/
2022-03-02 12:25:30 -05:00
Piotr Drąg
6381d44fc1 Translated using Weblate (Polish)
Currently translated at 100.0% (1417 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pl/
2022-03-02 12:25:30 -05:00
Weblate
66ec72142b Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/

Update translation files

Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/

Update translation files

Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2022-03-02 12:25:30 -05:00
Yuri Chornoivan
911bb00766 Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1416 of 1416 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2022-03-02 12:25:30 -05:00
Oğuz Ersen
952c4dfa78 Translated using Weblate (Turkish)
Currently translated at 100.0% (1416 of 1416 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/tr/
2022-03-02 12:25:30 -05:00
simmon
6e6421a705 Translated using Weblate (Korean)
Currently translated at 100.0% (1416 of 1416 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/
2022-03-02 12:25:30 -05:00
Jan Kuparinen
b9e9a2f51d Translated using Weblate (Finnish)
Currently translated at 100.0% (1416 of 1416 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fi/
2022-03-02 12:25:30 -05:00
Piotr Drąg
c7cde13310 Translated using Weblate (Polish)
Currently translated at 100.0% (1416 of 1416 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pl/
2022-03-02 12:25:30 -05:00
Weblate
fe3382d1a5 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2022-03-02 12:25:30 -05:00
Fabio Tomat
6cf2f721dc Translated using Weblate (Friulian)
Currently translated at 89.6% (1271 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fur/

Translated using Weblate (Friulian)

Currently translated at 89.7% (1271 of 1416 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fur/

Translated using Weblate (Friulian)

Currently translated at 85.7% (1213 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fur/

Translated using Weblate (Friulian)

Currently translated at 79.8% (1129 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fur/

Translated using Weblate (Italian)

Currently translated at 98.5% (1393 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/

Translated using Weblate (Friulian)

Currently translated at 79.4% (1123 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fur/

Translated using Weblate (Friulian)

Currently translated at 55.7% (789 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fur/

Translated using Weblate (Friulian)

Currently translated at 50.0% (708 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fur/
2022-03-02 12:25:30 -05:00
Weblate
60c85b41aa Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2022-03-02 12:25:30 -05:00
Alexey Rubtsov
f707d15bfd Translated using Weblate (Russian)
Currently translated at 99.8% (1412 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ru/
2022-03-02 12:25:29 -05:00
Whired Planck
18daf2e4cc Translated using Weblate (Chinese (Simplified) (zh_CN))
Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_CN/
2022-03-02 12:25:29 -05:00
Weblate
05302ed986 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/

Update translation files

Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2022-03-02 12:25:29 -05:00
Pino Toscano
a945526e60 Translated using Weblate (Italian)
Currently translated at 98.5% (1393 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2022-03-02 12:25:29 -05:00
Luna Jernberg
6cb6d04f44 Translated using Weblate (Swedish)
Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sv/
2022-03-02 12:25:29 -05:00
Ricky Tigg
5206fbf122 Translated using Weblate (Finnish)
Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fi/
2022-03-02 12:25:29 -05:00
Yuri Chornoivan
b927b520cb Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2022-03-02 12:25:29 -05:00
Oğuz Ersen
5721cd1b2e Translated using Weblate (Turkish)
Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/tr/
2022-03-02 12:25:29 -05:00
simmon
0d4b90309a Translated using Weblate (Korean)
Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/

Translated using Weblate (Korean)

Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/
2022-03-02 12:25:29 -05:00
Piotr Drąg
dbe26a7770 Translated using Weblate (Polish)
Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pl/
2022-03-02 12:25:29 -05:00
Weblate
8e916b41bc Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/

Update translation files

Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2022-03-02 12:25:29 -05:00
Ricky Tigg
96ab37096f Translated using Weblate (Finnish)
Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fi/
2022-03-02 12:25:29 -05:00
Github Actions
215eb03819 Refresh translation .pot template 2022-03-02 12:25:29 -05:00
rinsuki
445b946658 Translated using Weblate (Japanese)
Currently translated at 79.7% (1128 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ja/
2022-03-02 12:25:29 -05:00
simmon
d37afa26a3 Translated using Weblate (Korean)
Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/
2022-03-02 12:25:29 -05:00
Github Actions
434c816414 Refresh translation .pot template 2022-03-02 12:25:29 -05:00
Cole Robinson
3f76ceb110 tests: test_urls: test centos8 and centos9 stream
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-03-02 11:40:13 -05:00
Cole Robinson
291b750831 osdict: Hardcode win11 requires UEFI
Since there's a release pending, this is a bit of future proofing
if win11 pops up in a future osinfo-db without accompanying
libosinfo firmware APIs landing

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-03-02 10:57:36 -05:00
Cole Robinson
5640e9be5b osdict: firmware handling tweaks
* Check it for test:/// URI too
* Move the whole logic into osdict.requires_firmware_efi
* Wrap it all in an exception handler the final API breaks us
* Add some coverage exclusions since this is currently untestable

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-03-02 10:52:06 -05:00
Daniel P. Berrangé
5d74ca7621 virtinst/guest: use EFI firmware if osinfo-db shows lack of BIOS support
Windows 11 only supports EFI for installation, legacy BIOS is
discontinued as an option for new installs, unless you switch into
the console and run various regedit hacks in the installer.

This is not something we expect users to do, so osinfo-db will
report:

   <firmware arch="x86_64" type="efi"/>
   <firmware arch="x86_64" type="bios" supported="false"/>

for Windows 11.

When seeing 'bios' with supported=false, we need to prefer EFI
firmware no matter what.

For other OS we should stil prefer BIOS, because EFI blocks the usage of
internal qcow2 snapshots until some libvirt work is done to use the new
QMP snapshot commands.

Note this relies on a new API osinfo_os_get_complete_firmware_list
just added to libosinfo in version 1.10, so for most existing OS
distros this will be dormant functionality until they rebase to
latest libosinfo APIs.

The Windows 11 entry for osinfo-db will be the first that exposes
the metadata indicating lack of BIOS support.

Related: https://github.com/virt-manager/virt-manager/issues/310
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2022-03-02 10:42:12 -05:00
Cole Robinson
9db16377e8 viewers: Fix import error when spice is missing
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-03-01 14:52:26 -05:00
Cole Robinson
78e24fc986 cloudinit: Fix disabling cloud-init on first boot
`sudo` throws errors and is not even required to write the `disable`
file. Also add a message to the file that it was created by us

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-03-01 14:29:46 -05:00
Cole Robinson
767f856017 tests: test_inject: Some fixes and updates
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-03-01 14:29:46 -05:00
Cole Robinson
22478f307d virt-install: Add --cloud-init clouduser-ssh-key=
This sets the sshkey for the default cloud-init username

Resolves: https://github.com/virt-manager/virt-manager/issues/307

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-03-01 14:29:46 -05:00
Cole Robinson
c8afd1f51e virt-install: Rename --cloud-init ssh-key -> root-ssh-key
Originally we thought it would be for the clouduser, but then
we changed it, and now it's ambiguous. Rename it to make the
usage clear, and add an alias to keep any users working

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-03-01 14:29:46 -05:00
Cole Robinson
906604c972 tests: Compare cloud-init userdata output too
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-03-01 14:29:46 -05:00
Cole Robinson
015367fd85 ui: tpmdetails: Mark a uitests string as non-translatable
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-03-01 14:29:46 -05:00
Cole Robinson
d77efa1586 installer: Add smbios serial ds=nocloud for --cloud-init
This is a hint to cloud-init that we are passing in a nocloud
data source. This should typically just be an optimization, but
Ubuntu -kvm-disk cloud images since at least 20.04 need this to
work with -M q35:
https://bugs.launchpad.net/cloud-init/+bug/1940791

Fixes: https://github.com/virt-manager/virt-manager/issues/359

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-03-01 14:29:46 -05:00
Cole Robinson
51663a2c8c installer: Rework how we alter install and final XML
The Guest object passed in by the user is no longer altered in place,
instead we act on copies of the original XML. We need to rework how
unattended/cloudinit device altering works a bit to handle this.

There's some XML churn because working on parsexml gives different
output ordering, but this is expected.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-03-01 14:13:35 -05:00
Cole Robinson
08d3068340 installer: Rename install_xml -> initial_xml
Better describes when it applies

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-03-01 10:34:52 -05:00
Cole Robinson
825ec644b8 installer: Do not force reboot with --cloud-init
Resolves: https://github.com/virt-manager/virt-manager/issues/189

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-03-01 10:32:01 -05:00
Tudor Brindus
990b932c17 addhardware: add "none" video type
In some setups, it is useful to have Spice input, clipboard, audio, etc.,
but not video, for instance when doing GPU passthrough -- one can
interact inside the VM via Spice rather than USB passthrough, and use
a plugged-in monitor or alternate VM viewers like Looking Glass[1] for
video.

It is already possible to specify a "none" video device by manually
typing into the "Model" combobox and hitting "Apply". Yet, this is
unintuitive. Despite being documented everywhere GPU passthrough is
brought up, in the Looking Glass community we still get ~daily support
requests from users who couldn't figure out how to disable Spice video.

This patch makes "None" an explicit option in the video model combobox,
in the hopes that this is more straightforward for users to get right.

[1]: https://looking-glass.io/

Signed-off-by: Tudor Brindus <contact@tbrindus.ca>
2022-03-01 08:14:44 -05:00
Cole Robinson
3065b715d5 details: viewers: Fix variable override from outerscope
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-28 08:50:04 -05:00
Cole Robinson
e0c5d74e82 domain: launch_security: simplify defaults and validation
* libvirt fills in cbitpos and reducedPhysBits for us
* libvirt errors if type is missing
* libvirt errors if host/qemu doesn't support sev

So drop it all. This simplifies testing because we don't need
sev domcaps in place just to generate the XML

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-28 08:45:18 -05:00
Cole Robinson
1aaa28e26a tests: uitests: Add coverage for when spice is missing
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-27 14:23:09 -05:00
Cole Robinson
365d1f5d56 diskbackend: Set relative path for media change
Via the virt-manager UI we aren't converting relative path to
absolute path, even though we do it internally when needed.

We were benefiting from this in the test suite in some ways, so we
need to adjust tests to strip out the dev dir on XML comparison

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-27 13:44:26 -05:00
Cole Robinson
59595aebb7 uitests: details: Break out table cell click helper
We may want to move this to generic code at some point

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-27 13:44:26 -05:00
Cole Robinson
1f20ef7e07 tests: testdriver: Have all pools use pool- prefix
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-27 13:44:13 -05:00
Cole Robinson
435c7181f1 tests: testdriver: Rename default-pool -> pool-dir
And move the path to not be rooted in /dev, which doesn't make
sense for a directory pool, and triggers some special /dev handling
in virtinst that we don't want in the common testing path.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-27 13:03:04 -05:00
Cole Robinson
6a21b38ae8 tests: testdriver: Rename disk-pool -> pool-logical
It _is_ type=logical, so make it clear in the naming. Plus we
already have a type=disk pool named pool-disk

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-27 12:55:48 -05:00
Cole Robinson
d6b74a83d1 cli: Add xpath.* subargs to XML options
This adds the power of --xml to individual device options. For example
this makes it easier to make custom XML changes for a single --disk
device from both virt-install and virt-xml

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-27 11:46:54 -05:00
Cole Robinson
6c47fa56b9 xmlbuilder: Make XMLManualActions work more like XMLChildProperty
This will help us in upcoming patches add xpath subarguments to
cli device options

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-27 11:38:13 -05:00
Cole Robinson
e1b168c69b cli: Clean up _init_class mechanism
This will make it easier in future patches to register some objects
programatically

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-26 15:12:51 -05:00
Cole Robinson
b275e3c266 cli: Add --boot refresh-machine-type=yes
This is a virt-xml option to refresh a VM to use the latest machine
type version for the machine type it's currently using. Ex:

pseries-2.11 -> pseries
pc-q35-5.0 -> q35

This is useful for when qemu deprecates and removes the machine type
out from under you, or to pick up bug fixes.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-26 14:11:56 -05:00
Cole Robinson
310136337c guest: Make default graphics arch check more specific
We enable default graphics for all of ppc64, but really the only
thing we have ever tested is pseries, so make that clear.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-26 14:11:56 -05:00
Cole Robinson
1d9aed678e Revert "guest: Add default graphics for aarch64"
This reverts commit 20d3bf94845566a9893a4756362fad3e11bd6de0.

Indeed graphics does work on aarch64, but for example, fedora
server aarch64 installs don't output any graphical output and only
put data on the serial console. So we would need to be more specific
about how we enable this if we make the change.
2022-02-26 14:11:56 -05:00
Cole Robinson
0611302448 sound: Use ich9 more generally for PCIe, not just q35
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-26 14:11:56 -05:00
Cole Robinson
9a93f9c949 guest: Default num_pcie_root_ports to 14
qemu 6.1, fairly new when we added this option, has an unfortunate
bug with >= 15 root ports, so we choose 14 instead of our original 16
https://gitlab.com/qemu-project/qemu/-/issues/641

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-26 14:11:56 -05:00
Cole Robinson
2a3ff3609b Use pcie_root_ports for arm and riscv machvirt
Libvirt defaults to PCIe for arm32/aarch64 and riscv -M virt too.

Rename q35_pcie_root_ports to num_pcie_root_ports and extend the
logic to those archs too

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-26 14:11:56 -05:00
Andrew Shark
3a0275590c Add "vmm" shortcut keyword 2022-02-24 15:13:10 -05:00
Cole Robinson
708ec982a9 details: Only show channel state for qemu ga channel
This is the only one that we get notified when the XML changes,
so it's the only one we can be certain is up to date. Users have
gotten confused about out of date spice info here:

https://bugzilla.redhat.com/show_bug.cgi?id=2027867

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-24 14:54:08 -05:00
Cole Robinson
cd5c34a3f3 cli: Add basic --audio type=XXX,id=Y support
Closes: #264

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-24 14:18:41 -05:00
Cole Robinson
5a6714715b INSTALL: Correctly document that we require pygobject >= 3.31.1
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-20 12:31:52 -05:00
Cole Robinson
363fca413c virt-install: Require --osinfo for non-x86 HVM case too
It's generally not as valuable for non-x86 where we don't have the
history of supporting non-virtio OSes, but as time goes on it will
likely become more relevant for non-x86 arches, so let's make this
change now to get ahead of it.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-20 11:40:35 -05:00
Cole Robinson
5ebd4313f2 tests: consolidate some arch compare tests
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-20 11:31:42 -05:00
Cole Robinson
e3ecae0d2a domain: cpu: Clear 'migratable' and 'check' when changing mode
Otherwise going host-passthrough -> host-model -> host-passthrough
can cause libvirt validation errors or leave unintended bits in
the XML

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-20 11:04:37 -05:00
Cole Robinson
6ddcb23d9a man: virt-install: Update --controller docs
Drop type value lists, add example invocations, document
q35_pcie_root_ports

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-20 10:40:58 -05:00
Cole Robinson
4760d11bd8 cli: Fix busted --controller example in --help
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-20 10:39:04 -05:00
Cole Robinson
34543b3ecd ui: Remove use of deprecated GtkAlignment
Mostly this is replaced with widget padding, and GtkBox for generic
containers

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-20 09:53:17 -05:00
Cole Robinson
382391eadb Clean up gtk STOCK and various image usage
- Remove most use of deprecated stock icons. Without it the UI will
  be a lot more ugly in Fedora 36
- Remove deprecated ImageMenuItem usage, convert to regular MenuItem
- Remove most embedded button images

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-19 15:33:42 -05:00
Cole Robinson
cfc438c024 storagepool: Fix backtrace in cleanup path
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-19 14:07:27 -05:00
Cole Robinson
9c0a132f2a fsdetails: Point users to Memory screen if shared memory not enabled
If the user selects virtiofs when editting or adding a new VM, and
we don't detect that they have shared memory enabled, show
a warning label in the UI pointing them to the Memory screen.

It would be nicer if we did this for them, but to get that totally
correct would require both duplicating libvirt's shared memory
detection logic, and some surgery to the addhw wizard. This is good
enough for now

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-19 10:44:29 -05:00
Cole Robinson
a7682fc9eb fsdetails: Show virtio-9p vs virtiofs driver field
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-19 10:02:41 -05:00
Cole Robinson
d65d31cea2 devices: filesystem: Fix default virtiofs accessmode
We shouldn't use accessmode=mapped here, libvirt rejects it.
Let libvirt fill in a working default

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-19 10:02:41 -05:00
Cole Robinson
72b7dcaceb fsdetails: Hide 'Type:' field for qemu driver
The qemu driver only accepts type=mount

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-19 10:02:41 -05:00
Cole Robinson
fd079a6132 fsdetails: Drop 'Mode:' UI
We only ever show mapped vs squashed, and the difference is pretty
advanced, so if users need it they can use the XML editor. Upcoming
virtiofs support will also make handling this field more complicated

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-19 10:02:41 -05:00
Cole Robinson
3fd71ea72f tests: cli: A bunch of cleanup
- Move most xml suboption testing to many-devices test
- Clarify every specific bit we are testing in the singleton tests
- Consolidate/drop/reduce a lot of tests

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-19 10:02:41 -05:00
Cole Robinson
fd181cecc3 virtManager: Split out tpmdetails.py and tweak it
Split out tpmdetails.py, following the pattern of fsdetails.py. This
adds more UI editing fields for an already attached TPM.

Move the model and version under an 'Advanced options' expander,
since we should be getting this correct by default.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-19 10:02:22 -05:00
Cole Robinson
d70d4e6e7a devices: tpm: Rework defaults
The code previously was just encoding the same defaults as libvirt,
which doesn't really add anything.

Instead, let's prefer type='emulator' model='tpm-crb', which
gives the most modern virtualization friendly config. When we don't
know if that will work, we mostly leave things up to libvirt to fill
in.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-19 08:36:28 -05:00
Cole Robinson
39731b8bf7 tests: Add updated domcaps data for s390x and ppc64le
Pulled from libvirt's test suite

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-17 14:47:18 -05:00
Cole Robinson
46d6491eae domcapabilities: Organize methods a bit
Break out the CPU secure stuff from being inline in the class, most
of the logic there is not relevant to understanding what the
domcapabilities API provides

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-17 14:15:46 -05:00
Cole Robinson
f7f390836a domcapabilities: Add has_value() helper and use it
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-17 14:00:22 -05:00
Cole Robinson
db8305ad01 guest: Default to 16 pcie root ports for q35
Add extra PCIe root ports to enable q35 device hotplug to work out
of the box. A typical modern linux guest has 7-8 PCI devices added
by default, so this gives plenty of wiggle room.

The smart thing to do would be to count the attached PCI devices
and add 4-5 extra, but that takes more work and isn't trivial.

The number can be overridden on the cli with:

  --controller q35_pcie_root_ports=X

Use =0 to go back to the old behavior.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-16 14:09:33 -05:00
Cole Robinson
ceeae705c2 guest: Use is_q35 helper in UEFI secboot check
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-16 14:06:13 -05:00
Cole Robinson
0c2cb36475 tests: uitests: Test linux2020 osinfo usage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-16 14:03:44 -05:00
Cole Robinson
8903b470f1 details: Have 'copy host CPU' mean 'host-passthrough'
Adjust the UI to leave the box checked for both host-model and
host-passthrough, but host-passthrough is now what it means when
the user selects it. host-model can still be selected via the
CPU model drop down list

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-16 14:03:44 -05:00
Cole Robinson
2c477f3302 domain: cpu: Use host-passthrough by default on x86
When libvirt and qemu are new enough, use host-passthrough for the
CPU default. Nowadays this is recommended over host-model for most
end user usage where migration isn't a critical feature.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-16 14:03:44 -05:00
Cole Robinson
fc9a22afe0 oslist: fix window size in New VM wizard
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-16 14:03:44 -05:00
Cole Robinson
e37e27bc35 guest: Rename _add_implied_controllers -> _add_virtioscsi_controller
Since that's all it does. And clean up the style a bit

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-16 14:02:58 -05:00
Cole Robinson
d488472837 tests: cli: Organize the qemu/kvm section a bit
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-16 12:31:52 -05:00
Cole Robinson
8eeebce4bc tests: more capabilities data cleanup
* Merge kvm-x86_64-domcaps{-q35} variants
* Add -oldfirmware for explicitly testing secboot fallback setup
* Use consistent kvm-x86_64-domcaps-* prefix

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-16 12:31:52 -05:00
Cole Robinson
0cce75addc capabilities: Remove some XML parsing we don't use
These have been used in the past, but no current code touches them,
so drop the parsing infrastructure

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-16 12:31:52 -05:00
Cole Robinson
49f54a294b virtinst: cpu: drop host-copy support
host-copy was the old default, but it's fundamentally flawed. Since
we switched to host-model default a few years back, it's not advertised
in the docs or selectable via virt-manager any more.

Have it print a warning and invoke host-model-only

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-16 12:31:52 -05:00
Cole Robinson
26ecf8a5e3 virt-install: Make missing --osinfo fatal for most cases
This was previously discussed here:
https://listman.redhat.com/archives/virt-tools-list/2020-September/msg00017.html

For the x86 + hvm case, failure to specify an --osinfo/--os-variant
OS, and failure to detect an OS from install media, will now throw
a big error:

```
--os-variant/--osinfo OS name is required, but no value was
set or detected.

This is now a fatal error. Specifying an OS name is required
for modern, performant, and secure virtual machine defaults.

If you expected virt-install to detect an OS name from the
install media, you can set a fallback OS name with:

  --osinfo detect=on,name=OSNAME

You can see a full list of possible OS name values with:

   virt-install --osinfo list

If your Linux distro is not listed, try one of generic values
such as: linux2020, linux2018, linux2016

If you just need to get the old behavior back, you can use:

  --osinfo detect=on,require=off

Or export VIRTINSTALL_OSINFO_DISABLE_REQUIRE=1
```

The thread goes into more detail, but basically, for x86 VMs at least,
it's unlikely you will _ever_ want the default 'generic' behavior,
which gives gives no virtio, no PCIe, no usb3, IDE disks, slow
network devices, etc.

Many people use virt-install in scripts and CI, and this may now
cause breakage. The environment variable is there to help them
get things back to normal as quick as possible, but it will still
noisy up their logs with the warning to hopefully get them to make
a useful change to their virt-install invocations.

This is limited to x86, since that's where most of our defaults
historically differ, and where we can depend on libosinfo to give
the most accurate device info. This may be relevant to change for
other KVM architectures in the future.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-16 12:25:13 -05:00
Cole Robinson
c57b0f7d46 tests: Add output test for --osinfo linux2020
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-12 12:56:00 -05:00
Cole Robinson
95cdbf9e8f osdict: Drop usb-tablet checking
Historically over time it's been more likely that an issue is reported
for osinfo-db missing the usb-tablet annotation. So for example we
always enable it for the default 'generic' case. We also want to
enable it for osinfo's 'unknown' case too.

Rather than add another check for that, let's just drop the osinfo
checking entirely. Some very old OS don't support usb-tablet, but
specifying it for those cases doesn't cause issues AFAIK, and users
can override it with `--input none` if they want.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-12 12:51:05 -05:00
Cole Robinson
e7249fa79f virt-install: Warn about performance for --osinfo generic too
Currently we skip the warning if the user explicitly requests
`--osinfo generic`. Upcoming changes to the defaults here will make
it tempting to specify `--osinfo generic` just to make things work,
and we want to dissuade that, so enable the warning for that case too.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-12 12:51:01 -05:00
Cole Robinson
9c54c116fa cli: Recommend --osinfo more over --os-variant
We are about to change the some defaults around os handling. Let's
start recommending the nicer named --osinfo more, since new error
messages are going to promote it a bit as well

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-12 11:53:09 -05:00
Cole Robinson
c2fb5ad402 tests: Add grep= annotation for every invalid test
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-12 11:53:09 -05:00
Cole Robinson
3e794d2d96 virt-install: Turn --os-type into a no op and warning
I'm still seeing blog posts that recommend using

  --os-type linux --os-variant XXX

Which has been a no op for a long time but is mostly harmless.
Current git would make this an error condition, but that's too
disruptive IMO. Just print a warning

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-12 11:53:09 -05:00
Cole Robinson
1f8afc8668 virtManager: oslist: Push users towards linuxXXXX options
Have the UI push users more towards better defaults, by discouraging
the 'generic' entry and offering the 'linuxXXXX' entries when their
distro or OS version is not in the list.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-12 11:53:09 -05:00
Cole Robinson
95ba78f3e8 osdict: Simplify os list sorting
Previously we tried to use a combination of distro class and version
number to produce a correct ordering that was independent of the
osinfo short ID. The original intent was to have correct ordering
for Windows entries in the virt-manager UI, since the short ID
values are all over the place.

Nowadays that doesn't really matter, since we weed out old
unsupported entries by default. And in the mean time, our current
sort method gives some weird results like interspersing silverblue
entries with fedora entries.

Using a natural/human sort is simpler and handles things pretty well.

Change the UI to sort by the OS label too which preserves some of
the good behavior of original method

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-12 11:53:09 -05:00
Cole Robinson
96a40b1143 cli: Add --os-variant list option to print OS name values
The canonical tool for this is `osinfo-query os`, which we still
reference in the man pages and in the list output.

However, we are about to make missing --os-variant fatal for common
usage, and I don't want to force users to install an extra tool just
to figure out what an acceptable --os-variant value is.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-12 11:53:09 -05:00
Cole Robinson
a39bd561b0 addhardware: tweak mdev inactive UI
- Move tooltip to the tree row instead of the finish button
- Some style cleanups
- Add a hack so we can hit it in the test suite

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-12 11:24:44 -05:00
Shalini Chellathurai Saroja
a4c02b1aed virt-manager: prevent attach of inactive nodedevs
With virt-manager application, it is possible to add inactive node
devices(eg: mediated device) in host system to guest system. But it is
impossible to start a guest system with inactive node devices.  Also,
it is not yet possible to start a node device with virt-manager
application. So, the user cannot use the inactive node devices.

This patch disables the "finish" button and provides a tip, when
inactive node devices are selected. So, it is not possible to add
inactive node devices to the guest system.

Signed-off-by: Shalini Chellathurai Saroja <shalini@linux.ibm.com>
Reviewed-by: Boris Fiuczynski <fiuczy@linux.ibm.com>
2022-02-11 14:00:33 -05:00
Cole Robinson
9643955121 Revert "virt-manager: prevent attach of inactive nodedevs"
This reverts commit 216dc6e4e12a628ceebfd692075b3a36b7be97d8.

This was not meant to be pushed, the patch is still under review
2022-02-11 13:59:06 -05:00
Cole Robinson
d1e1bc0995 devices: graphics: tweak a few log messages
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-10 10:17:15 -05:00
Cole Robinson
b4e35c0687 devices: graphics: Don't use spice default on xen
This matches what we have historically done, prior to the domcaps
change in 30382d57f. Xen will report spice in domcaps but we should
not let that change our historical default

https://listman.redhat.com/archives/virt-tools-list/2022-February/msg00006.html

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-10 10:17:10 -05:00
Cole Robinson
9c6efdc1d5 man: virt-install: Use osuosl.org for debian URL example
https:// needs to link to the exact site, not the debian.org redirect,
otherwise we get browser cert warnings

Fixes: #360

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-09 11:11:29 -05:00
Jonathon Jongsma
17cd4477b8 man: fix default value for filesystem accessmode option
Commit 85307b9bd2971cfc972c976c78e411f018647861 changed the default
value for 'accessmode' from 'passthrough' to 'mapped', but forgot to
update the documentation in the man page.

Signed-off-by: Jonathon Jongsma <jjongsma@redhat.com>
2022-02-09 11:05:01 -05:00
Michal Privoznik
34c47c1527 Update domain title/description on corresponding event
If a domain is edited outside of virt-manager (e.g. via virsh
edit) then this is reflected in the GUI (in the domain HW details
tab). However, if domain title or description is updated outside
of virt-manager (virsh desc) then this change is not reflected.
This is simply because the corresponding event emitted by libvirt
is not listened to.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
2022-02-09 10:14:24 -05:00
Cole Robinson
6baa327d67 cli: Add --tpm active_pcr_banks support
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-03 16:33:08 -05:00
Shalini Chellathurai Saroja
216dc6e4e1 virt-manager: prevent attach of inactive nodedevs
With virt-manager application, it is possible to add inactive node
devices(eg: mediated device) in host system to guest system. But it is
impossible to start a guest system with inactive node devices.  Also,
it is not yet possible to start a node device with virt-manager
application. So, the user cannot use the inactive node devices.

This patch disables the "finish" button and provides a tip, when
inactive node devices are selected. So, it is not possible to add
inactive node devices to the guest system.

Signed-off-by: Shalini Chellathurai Saroja <shalini@linux.ibm.com>
Reviewed-by: Boris Fiuczynski <fiuczy@linux.ibm.com>
2022-02-03 15:29:26 -05:00
Cole Robinson
d09e722a6f config: Disable libguestfs UI integration by default
If python3-libguestfs is installed, virt-manager will use it
automatically to fetch guest OS icons, installed application lists,
and some other details.

In practice though the libguestfs integration usually doesn't work,
because most virt-manager created VMs have disks image in a location
only accessible to root, and our libguestfs usage needs the disks
accessible by the app user.

When it does work, we don't cache the results across app runs, so
libguestfs spawns lots of inspecting VMs every app startup, with
lots of log chatter and CPU spiking.

Then there's the confusion that app behavior can noticeably change
through the install of another package and an app restart.

I think it's simpler from a maintenance perspective to disable this
by default. If we fix those two big issues then maybe we can change
it back in the future

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-03 15:28:24 -05:00
Cole Robinson
19efeaf7a6 Rename 'master' branch to 'main'
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-03 15:23:45 -05:00
Cole Robinson
8377b7f7b6 details: Remove 'detect zeroes' UI
After checking with qemu devs, this option is not really recommended
for common usage and doesn't get used much in practice. So I don't
think it is suitable for the UI

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-03 13:50:53 -05:00
Cole Robinson
381aa4050c devices: disk: Set discard=unmap by default for some cases
This recommendation came from an internal discussion. The cases are

* For block storage. This means guest requests are passed through
  to the host device, which seems a more reasonable default than
  ignoring them

* For sparse disk images we will create. discard=unmap helps preserve
  the sparseness of the disk image. If a user requests non-sparse, they
  are likely more concerned with performance than saving disk space,
  so we leave the default as is. We limit this to disk images we will
  create, since that's the easiest case to check, and it's less clear
  if we should change the behavior here for an arbitrary existing
  disk image.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-03 13:42:49 -05:00
Cole Robinson
1ab6dd50be devices: video: Use virtio default more often
This is from Gerd's suggestions here:
https://www.kraxel.org/blog/2019/09/display-devices-in-qemu/

When the guest supports it, we should use virtio. qxl is on the way
out, and the benefits are marginal and add a security and maintenance
burden.

While here, check domcaps that qxl or virtio are actually available.
Modern qemu has device modules, so device support may not be installed.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-03 13:42:49 -05:00
Cole Robinson
f291ad2541 devices: video: Clean up default_model a bit
Add comments for most of the cases, and break apart some nesting

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-03 13:42:49 -05:00
Cole Robinson
1498085ff9 domcapabilities: Remove redundant check
get_enum() will always succeed, so the first check is redundant

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-02-03 13:42:43 -05:00
Cole Robinson
c3e9db5f3a createvm: Tweaks to new UEFI pref
* Make it clear in code and UI that this is x86 only. Other arches
  either require UEFI (aarch64) or don't support it
* Drop the internal 'bios' values since we don't handle them and may
  not want them anyways, since when win11 support lands we will need
  to explicitly throw an error if the user tries to force bios
* Add UI tests

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-31 14:18:42 -05:00
Charles Arnold
0a1dd8b822 virt-manager: Add firmware preferences for creating a new VM
Possible values are BIOS (default) and UEFI.
The firmware used is determined by libvirt unless a specific firmware is
selected from the Customize dialog.

See https://bugzilla.redhat.com/show_bug.cgi?id=1997882
2022-01-31 13:55:00 -05:00
Cole Robinson
f4aea0dca0 ui: Resave all files with latest glade
It creates a lot of churn.

Adjust phantom grid rows + columns while we are at it, not sure why
those counts are suddenly wrong

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-27 13:34:26 -05:00
Cole Robinson
87e0ed5de0 Revert "details: console: drop hardcoding background color as black"
This reverts commit aaabb44ac73dfaaa49f5d70be689d9e433801121.

I figured out how to trigger this: it's when scaling is enabled.
To maintain VM aspect ratio, we have to constrain the size of the
viewer widget. When the widget is smaller than the VM window, the
viewport widget is visible. This change made the viewport the default
theme color, rather than black.

Problem is, in the non-scaling case, we don't shrink the viewer
widget but let it expand to fill the whole area. This is necessary
to get the 'Autoresize VM with window' option to work, but is also
simpler in the cdoe. The viewport widget is not visible, and gtk-vnc
and spice-gtk paint the non VM owned areas as black. AFAICT that's not
configurable in any way.

So after this change we have differing behavior for scaled and
non-scaled cases, which is confusing and visually kinda comes off as
a bug.

So this reverts back to the old behavior and explains all this in
a comment.
2022-01-27 11:07:31 -05:00
Cole Robinson
588e5e4f54 DESIGN.md: reference rejected sky high maxmem and maxvcpus
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-27 10:34:26 -05:00
Cole Robinson
7ee01c7eeb setup: Plan for newer setuptools providing distutils back compat
setuptools still doesn't natively provide some infrastructure we
need, but newer versions will keep 'import distutils' working until
those issues are addressed. I think we need to reorder imports to take
advantage of it though. It silences some deprecation warnings at
least

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-27 10:19:43 -05:00
Cole Robinson
16fecb482a cli: Add --memdev target.{current,block,requested}
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-27 09:57:20 -05:00
Cole Robinson
a489d69dc6 cli: Add virtio option driver.page_per_vq=on
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-26 17:11:56 -05:00
Cole Robinson
01f52fed97 cli: Add --launchSecurity kernelHashes=yes|no
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-26 17:08:27 -05:00
Cole Robinson
1a1bbe99f8 cloner: Improve error message about unimplemented rbd support
Fixes: https://github.com/virt-manager/virt-manager/issues/340

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-26 16:58:45 -05:00
Cole Robinson
b7e86d2fcc guest: Move uefi check into _add_default_tpm
This is closer to the same pattern used by _add_default_*

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-26 13:23:27 -05:00
Cole Robinson
5003f0432e details: Add os.firmware=efi in the firmware selector UI
Let users choose libvirt's os.firmware=efi setting in the UI, putting
it about the firmware path list, since it's the preferred default
these days.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-26 13:23:27 -05:00
Cole Robinson
3013889727 guest: Use os.firmware=efi for --boot uefi, if it is supported
<os firmware='efi'> is the libvirt official way to do what we
historically implement with `--boot uefi`, and UEFI setup in
virt-manager.

Let's prefer libvirt's official method if the support is advertised
in domcapabilities.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-26 11:59:51 -05:00
Cole Robinson
245e89ac38 guest: Rework set/get_uefi entry points
This replaces the pattern:

  Guest.set_uefi_path(Guest.get_uefi_path())

With a single entrypoint

  Guest.enable_uefi()

to immediately change the guest config to use UEFI, using our
default logic.

This will make it easier to change that logic in the future, like
using <os firmware='efi'> instead of hardcoded paths

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-26 11:59:42 -05:00
Cole Robinson
6c3b5def81 netlist: Revive portgroup UI
I removed Portgroup UI in 4c3c53f773 release 3.0.0, but there's been
a steady stream of requests to bring it back. It seems it's commonly
used with some certain openvswitch config.

Maint burden isn't too bad. Let's bring it back

Fixes: https://github.com/virt-manager/virt-manager/issues/169

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-25 16:01:17 -05:00
Cole Robinson
c6bf106dd3 device: netlist: Rework source row data structure
Put non-UI bits into a class, rather that stuff them into gtk
columns. Simplifies adding bits here

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-25 15:35:55 -05:00
Cole Robinson
dfef112b2a virt-xml: Fix device lookup by integer properties
We were not correctly accounting for the internal representation of
some fields, and just trying to a string comparison. We need to be
a bit smarter than that

Fixes: https://github.com/virt-manager/virt-manager/issues/356

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-25 13:43:58 -05:00
Cole Robinson
9c45f4a2e9 details: Strip back 'Enable shared memory' to only cover memfd
Strip back the logic to:

* Only try to toggle source_type=memfd and access_mode=shared
* Disable the field if guest has any <numa> config
* Disable the field if domcaps does not report virtiofs and memfd

This is the simplest future proof case, though it will exclude some
legit guest configs and some libvirt+qemu back compat.

My feeling is the <numa> stuff in particular is pretty advanced, so if
users have it configured they can toggle shared memory via the XML
without too much trouble.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-25 12:43:32 -05:00
Cole Robinson
3d915717dd tests: Add domcaps coverage for filesystem checks
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-25 12:26:14 -05:00
Cole Robinson
c9ce3ad84e tests: uitests: Add some coverage for 'Enable shared memory'
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-25 12:26:14 -05:00
Cole Robinson
51de31499e details: Move 'shared mem' editing and tooltip logic to domain.py
We will eventually want to share this with the addhw wizard, so it
should live in a shared space.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-25 12:26:14 -05:00
Cole Robinson
ab9cdb55e0 details: shared mem UI tweaks
- Change label to 'Enable shared memory'
- Add accelerator
- Tweak table row fill

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-25 12:26:14 -05:00
Lin Ma
b4189a925b details: Add new checkbox to control shared memory access
The virtiofs in domcapabilities is used as a proxy to tell us whether
libvirt is new enough to allow bare memory access mode=shared', So We
enable/disable this checkbox according to it.

When we configure shared memory access, If the 'memfd' is available in
domcaps, We configure VM to use it as memory backend because it doesn't
need addtional host setup for vhost-user devices, Otherwise use 'file'
as backend.

If all of numa nodes explicitly defined memAccess=shared, We mark this
checkbox as checked even if virtiofs isn't exposed in domcapabilities.
In this case:
- It doesn't matter what the value of access mode of memoryBacking is
  because access mode of memoryBacking will be overridden per numa node
  by memAccess attribute.
- Although the checkbox is disabled, the checked checkbox presents actual
  status about shared memory access to users.

Signed-off-by: Lin Ma <lma@suse.com>
2022-01-25 12:26:14 -05:00
Lin Ma
b19f973f78 domain: cpu: Add function all_shared_memAccess_cells()
It returns true in case all of numa nodes have the "shared" memAccess
attribute defined explicitly.

Signed-off-by: Lin Ma <lma@suse.com>
2022-01-25 12:26:14 -05:00
Lin Ma
f223992934 domain: cpu: Add function has_private_memAccess_cells()
It returns true in case any of numa nodes has the "private" memAccess
attribute.

Signed-off-by: Lin Ma <lma@suse.com>
2022-01-25 12:26:14 -05:00
Lin Ma
0864a9b231 domain: memorybacking: Add function is_shared_access()
It returns true in case the memoryBacking element contains the "shared"
access mode.

Signed-off-by: Lin Ma <lma@suse.com>
2022-01-25 12:26:14 -05:00
Lin Ma
c55a5b2d6d domcapabilities: Add supports_memorybacking_memfd()
Linux memfd memory backend doesn't require any host setup, We prefer to
use it as the simplest memory XML adjustments to make virtiofs works.

Signed-off-by: Lin Ma <lma@suse.com>
2022-01-25 12:26:14 -05:00
Lin Ma
546010ff94 domcapabilities: Add supports_filesystem_virtiofs()
Check whether virtiofs is exposed in domcapabilities, We can use it as a
proxy for 'libvirt is new enough to allow bare memory access mode=shared'
as well.

Signed-off-by: Lin Ma <lma@suse.com>
2022-01-25 12:26:14 -05:00
Lin Ma
a608a8c710 domcapabilities: Get filesystem devices
Signed-off-by: Lin Ma <lma@suse.com>
2022-01-25 12:26:14 -05:00
Cole Robinson
f13c8d87fb guest: Remove the hyperv + uefi workaround for win7 + win2k8r2
Both these windows versions are now longer supported, and UEFI isn't
the default, so I don't think this hack is much needed anymore

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-25 12:05:45 -05:00
Cole Robinson
8896944d59 tests: Fix missing XML output from some virt-xml tests
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-25 12:05:45 -05:00
Cole Robinson
11365e6f43 tests: update x86 capabilities data
Using qemu 6.1.0 and libvirt 7.6.0 on Fedora 35

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-25 12:05:45 -05:00
Cole Robinson
b39aa1ea79 tests: Clean up URI building and naming
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-25 10:32:03 -05:00
Cole Robinson
5444bf32f5 tests: Remove unnecessary KVMIBM data
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-25 10:22:24 -05:00
Cole Robinson
adae7bf1e5 tests: Remove old rhel7 domcaps data
This doesn't hit any code path we care about anymore

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-25 10:22:15 -05:00
Daniel P. Berrangé
eb58c09f48 virtinst/guest: enable a TPM by default if UEFI is present
The bare metal world is moving to a situation where UEFI is going to be
the only supported firmware and there will be a strong expectation for
TPM and SecureBoot support.

With this in mind, if we're enabling UEFI on a VM, it makes sense to
also provide a TPM alongside it.

Since this requires swtpm to be installed we can't do this
unconditionally. The forthcoming libvirt release expands the domain
capabilities to report whether TPMs are supported, so we check that.

The user can disable the default TPM by requesting --tpm none

https://github.com/virt-manager/virt-manager/issues/310
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2022-01-21 17:49:15 -05:00
Cole Robinson
7e1f886aa9 cli: Clean up nodedev address functions a bit
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-21 13:20:46 -05:00
Cole Robinson
7986ffa80b nodedev: Move the CLI string format lookup to cli.py
This address string decomposing is strictly and virt-* cli feature.
Move it to cli.py to make that explicit

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-21 13:20:46 -05:00
Cole Robinson
6a83eae30f virtManager: nodedev: Handle failure to lookup drm parent
Apparently nodedev drm XML can link to a parent device that we can't
look up?

We shouldn't be trying to do the full address string compare anyways,
so just try the name lookup, which would improve the error here too

Fixes: #328

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-21 13:20:46 -05:00
Cole Robinson
d0664bc521 nodedev: Separate out lookupNodedevByName
This will facilitate upcoming cleanups + bugfixes

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-21 13:20:46 -05:00
Cole Robinson
4a933b0223 uitests: Test graphics port fix
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-21 13:19:57 -05:00
Cole Robinson
28af0f02f6 console: Clarify some error labels and debug messages
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-21 11:03:23 -05:00
Cole Robinson
bd4ca8a55e console: Add _cb suffix to viewer callback function names
And use _src for the first parameter name, which appeases pylint
but is more descriptive

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-21 11:03:23 -05:00
Cole Robinson
8bb64ad5af console: Don't block console reconnect for non-error
https://listman.redhat.com/archives/virt-tools-list/2022-January/msg00012.html

On xen, a guest reboot will trigger a non-error viewer-disconnected
signal, but we treat it like an error, which makes it difficult to
reconnect to the VM console.

If there's no error message raised, treat the disconnect like a
non-error cases.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-21 11:03:23 -05:00
Cole Robinson
2815b7406e gfxdetails: Fix switching from listen=none to listen=address
... with the 'hypervisor default' address. In this case, we need to
force set port=-1 in the XML, to make the changes actually stick

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-20 16:34:59 -05:00
Daniel P. Berrangé
5622854d8c virtinst: refactor setting of default vcpus count
The sync_vcpus_topology method will sometimes set the self.vcpus prop,
but other times leave it unset. This is confusing an unhelpful
behaviour. Both callers have logic to set the self.vcpus prop
to a default value of sync_vcpus_topology failed to do so. It makes
more sense to just pass this default value in.

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2022-01-20 14:16:39 -05:00
Daniel P. Berrangé
883419c214 virtinst: allow to force create topology from scratch
When setting CPU defaults we want to force create the topology even if
the user has not specified anything. In particular this allows for
overriding the QEMU defaults, to expose vCPUs as cores instead of
sockets which is a much saner default for Windows.

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2022-01-20 14:16:39 -05:00
Daniel P. Berrangé
9a578e1ac5 virtinst: prefer cores when exposing topology to the guest
In real world silicon though it is rare to have high socket/die counts,
but common to have huge core counts.

Some OS will even refuse to use sockets over a certain count.

Thus we prefer to expose cores to the guest rather than sockets as the
default for missing fields.

This matches a recent change made in QEMU for new machine types

  commit 4a0af2930a4e4f64ce551152fdb4b9e7be106408
  Author: Yanan Wang <wangyanan55@huawei.com>
  Date:   Wed Sep 29 10:58:09 2021 +0800

    machine: Prefer cores over sockets in smp parsing since 6.2

Closes: https://github.com/virt-manager/virt-manager/issues/155
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2022-01-20 14:16:38 -05:00
Daniel P. Berrangé
e1c8866163 virtinst: validate that the CPU topology is sane
The product of sockets * dies * cores * threads must be equal to the
vCPU count. While libvirt and QEMU will report this error scenario,
it makes sense to catch it in virt-install, so we can test our local
logic for setting defaults for topology.

This exposes some inconsistent configurations in the test suite.

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2022-01-20 14:16:38 -05:00
Daniel P. Berrangé
552759bef4 tests: re-arrange CPU topology test for clarity
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2022-01-20 14:16:38 -05:00
Daniel P. Berrangé
609007c9ca virtinst: make CPU topology defaulting take account of dies
Any missing values in the topology need to be calculated based on the
other values which are set.

We can take account of fact that 'total_vcpus' treats any unset values
as being 1 to simplify the way we set topology defaults.

This ensures that topology defaulting takes account of dies.

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2022-01-20 14:16:38 -05:00
Daniel P. Berrangé
9bb86f5186 virtinst: move method for calculating vCPU count from topology
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2022-01-20 14:16:38 -05:00
Daniel P. Berrangé
c1491ae142 virtinst: set dies in topology to 1
It is always permitted to set dies==1 regardless of architecture or
machine type. The only constraint is around setting values > 1, for
archs/machines that don't support the dies concept.

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2022-01-20 14:16:38 -05:00
Daniel P. Berrangé
7b68fe1a5e virtinst: take account of 'dies' when calc vcpu count from topology
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2022-01-20 14:16:38 -05:00
Daniel P. Berrangé
95eb8dda9b virtinst: add missing 'dies' parameter for --vcpus
Although using --cpu topology.XXX is the preferred way to set topology,
it is still possible via the --vcpus parameter. For consistency, this
should support the full set of parameters, so dies needs to be added.

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2022-01-20 14:16:38 -05:00
Shalini Chellathurai Saroja
ca8950f0ed virtManager: change MDEV display names
The MDEV devices listed in the "Add New Virtual Hardware" page, are a
concatenation of parent device name and MDEV device name, eg:
css_0_0_0014 mdev_b204c698_6731_4f25_b5f4_894614a05ec0_0_0_0014. The
parent name is duplicated in here, as the MDEV device name itself includes
a part of the parent name in libvirt version 7.8.0 and later. So, this patch
changes the MDEVs listed in "Add New Virtual Hardware" page to only display
the MDEV device
name(eg:mdev_b204c698_6731_4f25_b5f4_894614a05ec0_0_0_0014), when the
new naming convention is used.

Signed-off-by: Shalini Chellathurai Saroja <shalini@linux.ibm.com>
2022-01-19 14:24:14 -05:00
Cole Robinson
9e133de21a diskbackend: Restrict format->driver_type even more
We should only be returning a driver_type value for volumes that
report support_format(), meaning they support file type formats like
qcow2. Any other reported format should be ignored

Dropping the check for 'unknown' value changes one test case a bit,
but it hardcodes raw which is what libvirt gives us anyways, so it's
okay

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-19 14:21:48 -05:00
Simon Kobyda
2676640979 Disk pool volumes should be always attached as "raw" disks
Usually, when storage volume is attached as a disk and disk xml is filled with
default values, the "<driver type=...>" value is copied from volume's
"<format type=...>".  This makes sense for volumes of storage pool of type
"dir", where format types include "raw, qcow2...".

However, the same approach cannot be used for the storage pool of type "disk".
In that case, format types include "none, linux, fat16, fat32...". Such formats
cannot be used for disk's "<driver type=...>".

Therefore, when generating disk XML for volume of storage pool type "disk",
driver type should always be "raw".
2022-01-19 14:11:46 -05:00
Simon Kobyda
59e24f6bb9 tests: Introduce disk attachment from pool of type 'disk' 2022-01-19 14:09:47 -05:00
Cole Robinson
45eb83f93a osdict: Remove outdated 'no cover' annotation
The test suite does cover this line

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-19 13:45:46 -05:00
Daniel P. Berrangé
d9044419ac virtinst: fix return type in guess_os_by_iso
Accidentally changed in

  commit 302ef1f09669516677d83979536617f1705e1c75
  Author: Daniel P. Berrangé <berrange@redhat.com>
  Date:   Fri Nov 26 18:51:49 2021 +0000

    virtinst/osdict: add a property for the OsinfoDb object

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2022-01-19 13:44:54 -05:00
Cole Robinson
acaca061be uitests: top off test coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-17 17:11:18 -05:00
Cole Robinson
4f02ccd7b5 uitests: Mock virtBootstrap
It's historically flakey to keep it + skopeo + virt-sandbox
all working, let's just mock it

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-17 15:13:12 -05:00
Cole Robinson
92c0c4e1a7 tests: Fix test coverage after osdict changes
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-17 14:51:36 -05:00
Cole Robinson
06dbac540f tests: Fix hyperv @mode handling on libvirt 8.0.0
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-17 14:51:36 -05:00
Daniel P. Berrangé
9423f6680a virtinst/osdict: remove internal cache of OS objects
Now that we've removed all internal aliases, there is no longer any
reason to keep a cache of OS objects internally. We can directly
query the DB when we need it.

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2022-01-17 14:51:36 -05:00
Daniel P. Berrangé
6b584b183f virtinst/osdict: refactor setup of generic fallback OsinfoOs
Introduce a property for accessing the generic fallback Os object, which
will be useful in future refactoring.

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2022-01-17 14:51:36 -05:00
Daniel P. Berrangé
302ef1f096 virtinst/osdict: add a property for the OsinfoDb object
This simplies the code a little bit by avoiding visible indirection
via the loader every time.

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2022-01-17 14:51:36 -05:00
Daniel P. Berrangé
35ef83d628 virtinst/osdict: remove osinfo legacy aliases
The code comment suggests removing the aliases after a year. It has
now been three years, so it is time for them to go.

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2022-01-17 14:51:36 -05:00
Cole Robinson
499badbdf4 object: nodedev: support isActive state
This was added to libvirt in the past few years, and we may want it
for mdev addhardware UI

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-17 14:37:06 -05:00
Matt Graham
c51ebdd76a Fix typo 2022-01-12 13:29:30 -05:00
Jonathon Jongsma
9766beea04 cli: add 'ioapic.driver' to --features
Add the ability to set the ioapic driver using the --features argument:

    $ virt-install --features ioapic.driver=qemu ...

This results in the following xml:

  <features>
    ...
    <ioapic driver="qemu"/>
  </features>

This is required in order to install a guest with >255 cpus. Such a
configuration requires an iommu with extended interrupt mode enabled,
which in turn requires IOMMU interrupt remapping to be enabled, which in
turn requires a split I/O APIC.

Signed-off-by: Jonathon Jongsma <jjongsma@redhat.com>
2022-01-11 18:26:06 -05:00
Cole Robinson
cdd7061f8e pylint: Fix some deprecation warnings and minor bits
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-11 12:32:23 -05:00
Cole Robinson
c08e3e6397 tests: make sure all test output ends with a newline
Simplifies viewing files in an editor, and some pytest output.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-11 12:32:23 -05:00
Cole Robinson
7f56717006 osdict: Remove dead code after get_kernel_url_argument usage
This would still be used for old osinfo (mid 2019), and only for
the case of installing 7+ year old RH distros. I think we can safely
delete it.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-11 12:32:22 -05:00
Daniel P. Berrangé
019c621b62 virtinst: fix check for UEFI in SEV setup
The code was only checking the manual approach to enabling UEFI, not the
modern automatic approach.

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2022-01-11 12:04:39 -05:00
Cole Robinson
ed7b8769c4 nodedev: Improve error with unknown address strings
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2022-01-11 11:39:29 -05:00
Andrea Bolognani
ed39fd79eb installerinject: Add error detection for initrd injection
Any of the commands involved in injecting files into an initrd
could fail, and if that happens we should interrupt the
installation instead of proceeding as if nothing had happened.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2022-01-04 09:39:21 +00:00
Pino Toscano
0038d750c9 osinfo: use the OS kernel-url-argument if available
Each OS may specify which kernel argument is needed to specify the
installation source; use it as primary source, falling back to the
current logic. This should help supporting new OSes OOTB.

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2021-12-10 16:30:50 +00:00
Andrea Bolognani
2e2d3b84bc installerinject: Use root:root instead of +0:+0 as owner
Commit c6b5f22fa61d started passing the --owner argument to
cpio when injecting files into the initrd to comply with the
more strict requirements introduced by systemd starting with
Fedora 30.

However, cpio only started accepting the +uid:+gid syntax in
version 2.12, which means that the fix actually broke the
initrd inject functionality completely in RHEL 7 and other
distros that don't include a recent enough cpio.

Use the user:group syntax instead, which is understood by
all versions of cpio, including non-GNU ones.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2021-12-03 09:12:27 +00:00
Daniel P. Berrangé
b8aa69477f tests: fix pycodestyle violation with missing blank line
Fixes commit 0c146b250384ddddcefd2cc0d76b9e808377ebe5
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2021-11-24 22:42:32 +00:00
Jonathon Jongsma
0c146b2503 Handle new nodedev name for mediated devices
libvirt recently changed the nodedev names for mediated devices due to
the fact that mdevctl supports defining multiple mediated devices with
the same UUID as long as only one is active at a time. This means that
the nodedev name changed from the format 'mdev_$UUID' to the format
'mdev_$UUID_$PARENT'.

Unfortunately, virt-install was parsing the nodedev name to extract the
UUID of a mediated device. This fails with the new name format.
Fortunately, in libvirt 7.3.0, a <uuid> field was added to the xml
schema for mdev devices, so we can simply use this instead, and fall
back to the name parsing if it doesn't exist.

Signed-off-by: Jonathon Jongsma <jjongsma@redhat.com>
2021-11-10 14:58:07 +00:00
Daniel P. Berrangé
56ca569dfc tests: don't add the same USB devices to the guest twice
Libvirt now validates that all <hostdev> elements refer to distinct host
devices. The test suite violates that constraint by trying to build a
new guest with the same USB devices added to the guest twice, to
validate the various host device syntax options.

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2021-11-05 12:40:38 +00:00
Daniel P. Berrangé
cfa88603a2 tests: use different USB device when testing hot-add
Libvirt now validates that all <hostdev> elements refer to distinct host
devices. The test suite violates that constraint by trying to hot-add a
device that alreadye exists in the config.

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2021-11-05 12:40:38 +00:00
Cole Robinson
67695d00cf virt-xml: Don't regenerate defaults if both hotplugging and defining
For example, if both hotplugging and defining a new NIC, where we
generate the mac address, we need to use the initial generated device
XML for both operations, and not generate different MAC addresses
for each stage.

Resolves: https://github.com/virt-manager/virt-manager/issues/305

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-10-12 15:15:08 -04:00
Cole Robinson
c0f8da69b6 devices: interface: Add support for testing different mac addresses
Some test scenarios need to make sure different mac addresses would
_not_ be used in normal operations, but the test suite always generates
the same value. Add some hacks to let the test suite override the
default behavior and use incrementing addresses

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-10-12 15:14:06 -04:00
Cole Robinson
68ca651d85 xmlbuilder: Make embedded device XML print correctly
If you call get_xml() on a device that's part of a Guest class,
the last element has correct indent but not the first element.

Steal the indent from the last element and prepend it to the returned
XML

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-10-12 15:10:39 -04:00
Cole Robinson
2e7b7745aa tests: mock virt-xml hotplug success
The libvirt test driver doesn't support hotplug. Add an env variable
to ignore failure, so we can get better test coverage here

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-10-12 15:10:12 -04:00
Cole Robinson
17f0c83cf9 cloudinit: Rename variable to make codespell happy
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-10-04 16:32:17 -04:00
lisongmin
7da5daff92 cli: --cloud-init add network-config option 2021-10-04 16:31:39 -04:00
a1346054
fa78a0c3f2 misc: trim excess whitespace 2021-10-04 16:26:08 -04:00
a1346054
0d71a9a7fd misc: fix spelling 2021-10-04 16:26:08 -04:00
a1346054
59babfe4d6 virt-*: invoke python3 using /usr/bin/env 2021-10-04 16:26:08 -04:00
a1346054
5fb529fe0b COPYING: use license file from gnu.org
The license file distributed by gnu.org does not mix tabs and spaces.

Downloaded from:
https://www.gnu.org/licenses/old-licenses/gpl-2.0.txt
2021-10-04 16:26:08 -04:00
Cole Robinson
758eb74ba3 Replace deprecated imp usage with importlib
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-10-04 16:04:44 -04:00
Cole Robinson
79da19ad07 Fix some pylint, exclude some new warnings
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-10-04 16:04:33 -04:00
Hugues Fafard
cb97f6001b cli: --cpu: code cleanup & reordering
Shuffling bits of code around, adding comments and grouping CLI options
to make the code easier to read and understand at a glance.

Brings the ordering of XML options in line with libvirt's own output as
implemented in `src/conf/cpu_conf.c` and `src/conf/numa_conf.c`.
2021-10-04 15:10:10 -04:00
Hugues Fafard
6a2bc142eb cli: --cpu: add support for NUMA interconnects
This includes support for the following options:
* numa.interconnects.latency[0-9]*.initiator
* numa.interconnects.latency[0-9]*.target
* numa.interconnects.latency[0-9]*.cache
* numa.interconnects.latency[0-9]*.type
* numa.interconnects.latency[0-9]*.value
* numa.interconnects.latency[0-9]*.unit
* The same suboptions for `numa.interconnects.bandwith[0-9]*`

Note that the cache= attribute is only explicitly defined for <latency>
nodes in the documentation. However, since <latency> and <bandwidth>
nodes are otherwise identical, the docs also don't explicitly forbid it
for <bandwidth> nodes, and libvirt happily accepts XML that does specify
it for for <bandwidth> nodes, this implements the cache= attribute for
<bandwidth> elements as well.
2021-10-04 15:08:39 -04:00
Hugues Fafard
fbcb7539c3 cli: --cpu: add support for NUMA caches
This includes support for the following options:
* numa.cell[0-9]*.cache[0-9]*.level
* numa.cell[0-9]*.cache[0-9]*.associativity
* numa.cell[0-9]*.cache[0-9]*.policy
* numa.cell[0-9]*.cache[0-9]*.size.value
* numa.cell[0-9]*.cache[0-9]*.size.unit
* numa.cell[0-9]*.cache[0-9]*.line.value
* numa.cell[0-9]*.cache[0-9]*.line.unit
2021-10-04 15:08:38 -04:00
Hugues Fafard
42bb522f0d cli: --cpu: make numa.cell[0-9]*.discard an on/off type option 2021-10-04 15:08:38 -04:00
Hugues Fafard
bf3bd824c1 cli: --cpu: add support for unit of NUMA memory size
This adds support for the `numa.cell[0-9]*.unit` option.
2021-10-04 15:08:38 -04:00
Hugues Fafard
7d49d95a0f cli: --cpu: add support for specifying dies in topology
This adds support for the `topology.dies` option.
2021-10-04 15:08:38 -04:00
Hugues Fafard
1166bb3d8d cli: --cpu: add support for check & migratable options
Note that the `migratable` option is only allowed by libvirt for
`mode=passthrough` or `mode=maximum`.
2021-10-04 15:08:38 -04:00
Hugues Fafard
bcd97dd01a cli: --cputune: add support for cachetune montiors
This adds support for the following options:
* `cachetune[0-9]*.monitor[0-9]*.level`
* `cachetune[0-9]*.monitor[0-9]*.vcpus`
2021-10-04 13:31:54 -04:00
Hugues Fafard
563a97f022 cli: --cputune: add scheduling options
This includes support for the following options:
* `emulatorsched.scheduler`
* `emulatorsched.priority`
* `iothreadsched.iothreads`
* `iothreadsched.scheduler`
* `iothreadsched.priority`
2021-10-04 13:31:54 -04:00
Hugues Fafard
95721ae8d7 cli: --cputune: cleanup 2021-10-04 13:31:54 -04:00
Hugues Fafard
5cfbbf5701 cli: --cputune: add support for host cpu usage quotas
This includes support for the following options:
* `shares`
* `period`
* `quota`
* `global_period`
* `global_quota`
* `emulator_period`
* `emulator_quota`
* `iothread_period`
* `iothread_quota`
2021-10-04 13:31:54 -04:00
Chris Kerr
ddcdd39dcb urlfetcher: Make check_output call compatible with Python 3.6
Fixes: #291

The `text=` keyword was added in Python 3.7 "as a more readable
alias for `universal_newlines=`". This commit switches to the
old form of the name, for backwards compatibility with Python 3.6,
the default Python3 version on Ubuntu 18.04 and RHEL 8.

When support for Python 3.6 is no longer needed, this change can
be reverted.
2021-10-04 13:13:18 -04:00
Pavel Hrdina
0953e1aea1 cli: introduce --resource fibrechannel.appid option
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2021-09-14 17:08:35 +02:00
Cole Robinson
be05135867 libvirtobject: rename autostart tweaks
* Silence some pylint
* set_autostart failure shouldn't reset the old name

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-07-31 19:21:09 -04:00
coreyberla
b2835da3c8 libvirtobject: reapply autostart setting after rename
Fixes: #204
2021-07-31 19:20:51 -04:00
coreyberla
f3127e0029 domain: Don't rename domain if newname isn't different 2021-07-31 16:36:39 -04:00
Cole Robinson
aaabb44ac7 details: console: drop hardcoding background color as black
Submitted in https://github.com/virt-manager/virt-manager/pull/241

I couldn't get this code to change the output, tested with VNC and
spice-gtk on Fedora 34 gnome-shell x11 and XFCE. Maybe it's something
theme related. But either way this doesn't seem to be useful for the
default case anyways, so let's drop it

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-07-31 16:27:15 -04:00
Cole Robinson
520b3a3b35 cli: --filesystem: add binary.sandbox.mode and source.socket
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-07-30 13:15:29 -04:00
Cole Robinson
a214018af3 cli: --vsock: add generic virtio options support
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-07-30 13:09:08 -04:00
Cole Robinson
4a31f5cc12 README.md: clarify mailing list patch usage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-07-30 12:02:13 -04:00
Cole Robinson
8754a59d92 urlfetcher: Silence xorisso stderr output
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-07-30 10:45:07 -04:00
Cole Robinson
27525f4bab pylint: More attempts to silence gi warnings with -j option
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-07-29 11:45:06 -04:00
Hugues Fafard
6cc7987627 Finish reordering stuff and cleaning up
Finishes shuffling bits of code around to make the options better
grouped in the code so it's easier to read and understand what's what at
a glance.
2021-07-29 11:44:57 -04:00
Hugues Fafard
edf6c3ff2e cli: --boot: Completed options for container boot
Adds support for `initenv[0-9]*.name` and `initenv[0-9]*` suboptions.
2021-07-29 11:44:57 -04:00
Hugues Fafard
7bc4ba81ff cli: --boot: Completed options for direct kernel boot
Adds support for `acpi.table` and `acpi.table.type` suboptions.
2021-07-29 11:44:57 -04:00
Hugues Fafard
0a856179a5 cli: --boot: Completed options for host-based bootloader
Adds support for `bootloader_args` suboption
2021-07-29 11:44:57 -04:00
Hugues Fafard
a24cdd1964 cli: --boot: Completed options for guest-based bootloader
Adds support for `bootmenu.timeout` suboption.
2021-07-29 11:44:57 -04:00
Hugues Fafard
f067435e2a cli: --input: make source.repeat on/off type option 2021-07-28 14:49:52 -04:00
Hugues Fafard
b987613106 cli: --boot: add support of firmware features
libvirt 7.2.0 introduced support for a list of firmware features
that should or should not be present. Libvirt takes these into
account when auto-selecting a firmware. Currently supported features
are `enrolled-keys` and `secure-boot`.
2021-07-28 09:46:16 -04:00
Hugues Fafard
9028d728f8 cli: --input: add support for evdev inputs
This adds support for evdev inputs which were introduced in 7.4.0,
as well as passthrough inputs and some other misc options to complete
the --input command.

New suboptions:
* source.evdev
* source.dev
* source.repeat
* source.grab
* source.grabToggle
* model
2021-07-27 16:04:15 -04:00
Cole Robinson
4793bdaef7 tests: Only run --memdev uuid= test on new enough libvirt
The error was only introduced in later libvirt

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-07-27 16:04:15 -04:00
Hugues Fafard
20d2376b18 cli: --shmem: added support for shared memory devices
This includes support for the following suboptions:
* name              (<shmem name=X>)
* role              (<shmem role=X>)
* model.type        (<shmem><model type=X/>)
* size              (<shmem><size>X)
* size.unit         (<shmem><size unit=X/>)
* server.path       (<shmem><server path=X/>)
* msi.vectors       (<shmem><msi vectors=X/>)
* msi.ioeventfd     (<shmem><msi ioeventfd=X/>)
2021-07-27 15:55:00 -04:00
Cole Robinson
4017e761c2 tests: Fix --memdev uuid= test
latest libvirt rejects everything we can trigger here

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-07-27 15:54:50 -04:00
Cole Robinson
6e9b6bff30 cli: --memdev: add uuid= option
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-07-27 13:01:14 -04:00
Hugues Fafard
ddcca8f585 cli: --disk: add support for driver.queues config 2021-07-27 08:38:09 -04:00
Hugues Fafard
c2f629fc03 cli: --cputune: add iothreadpin[0-9]* config
This adds the following suboptions to configure the
<domain><cputune><iothreadpin> list:

* iothreadpin[0-9]*.iothread
* iothreadpin[0-9]*.cpuset
2021-07-27 08:28:10 -04:00
Hugues Fafard
f0f7ae2d1c cli: --cputune: add emulatorpin.cpuset config
Reviewed-by: Cole Robinson <crobinso@redhat.com>
2021-07-26 14:12:36 -04:00
Cole Robinson
10515ea167 gfxdetails: Default to configured graphics type, not always spice
So if the user chooses a different value from Preferences, or
app is built with a different value, default to that in Add Hardware

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-07-01 11:24:43 -04:00
Cole Robinson
eb6b79396b Remove shebangs from library paths
These don't really serve any purpose any longer

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-06-22 19:54:37 -04:00
Cole Robinson
c2ed7ad4ec spec: Remove shebang fixup
redhat-rpm-config brp-mangle-shebangs added in 2018 will do
/usr/bin/env python3 -> /usr/bin/python3 automatically for us

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-06-22 19:48:19 -04:00
Michal Privoznik
351667a354 virtinst: Support missing NVDIMM knobs
There are two domain XML knobs specific to NVDIMMs that
virt-install doesn't allow to set: <pmem/> and <alignsize/>.
Implement them.

Closes: https://github.com/virt-manager/virt-manager/issues/267
Reviewed-by: Cole Robinson <crobinso@redhat.com>
Reviewed-by: Erik Skultety <eskultet@redhat>
Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
2021-06-22 12:47:28 -04:00
Jonathon Jongsma
b1ba9009de spec: use %autosetup
Make sure potential patches get applied by using %autosetup instead of
plain %setup

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Jonathon Jongsma <jjongsma@redhat.com>
2021-06-22 12:47:28 -04:00
Liu Yiding
e4a9ff7df4 cloner: mark transient_shareBacking disk as shareable
libvirt 7.4.0 added support for sharing base image of <transient/> disks,
multiple VMs can share the same image
https://libvirt.org/news.html#v7-4-0-2021-06-01

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Liu Yiding <liuyd.fnst@fujitsu.com>
2021-06-22 12:47:28 -04:00
Cole Robinson
5f12f63549 spec: Move docs to virt-manager-common
And use %license tag

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-06-15 08:48:06 -04:00
Cole Robinson
58837a7641 tests: Add full test coverage for progress text output
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-06-09 16:52:12 -04:00
Cole Robinson
078178f476 progress: Drop tqdm and revert back to local urlgrabber copy
I thought tqdm was available everywhere, but it does not seem like
it will be in RHEL9. Revert back to the old urlgrabber copy, now
stored in virtinst/_progresspriv.py. If we ever want to try tqdm
again, we can just revert this commit

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-06-09 16:52:11 -04:00
Cole Robinson
18b017f148 domain: Force jobinfo values to be ints
We only want our meter abstraction to handle int values now

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-06-09 16:51:48 -04:00
Cole Robinson
f2a04f1abc createvm: Fix text progress with virt-bootstrap
It looks awkward after the text tweaks. Drop the semblance of
progress reporting

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-06-09 16:51:46 -04:00
Fabiano Fidêncio
20d3bf9484 guest: Add default graphics for aarch64
As already done for a few architectures, let's add the default
graphics when using aarch64.

This has been tested on a NVIDIA Jetson Xavier NX SBC.

Signed-off-by: Fabiano Fidêncio <fabiano@fidencio.org>
2021-06-08 10:37:56 -04:00
Cole Robinson
30382d57f1 graphics: Check domcaps for whether spice is available
This has been reported for the libvirt qemu driver since v1.3.5,
released June 2016. But we need to keep some fallback logic for
the test driver, and to keep the testsuite happy

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-06-08 10:36:19 -04:00
Cole Robinson
5e7a899a8e tests: Regenerate mdev output
There's some whitespace difference on my machine

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-06-08 10:36:17 -04:00
Shalini Chellathurai Saroja
0e15cd51df virt-manager: enable MDEV support
Enable virt-manager GUI to support add, edit, remove, hot-plug and
hot-unplug of mediated devices (like DASDs, APQNs and PCIs) in virtual
server.

It is not possible to edit MDEV when a virtual server is in
running state, as this is not supported by libvirt.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Shalini Chellathurai Saroja <shalini@linux.ibm.com>
2021-06-08 09:58:50 -04:00
Shalini Chellathurai Saroja
9d4002ee0f tests: verify MDEV support
Add tests to verify add, edit and remove features of mediated
devices.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Shalini Chellathurai Saroja <shalini@linux.ibm.com>
2021-06-01 17:07:36 -04:00
Shalini Chellathurai Saroja
f87e96d3d4 hostdev: use method get_mdev_uuid()
Use method get_mdev_uuid() to retrieve the UUID of MDEV node device
object.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Shalini Chellathurai Saroja <shalini@linux.ibm.com>
2021-06-01 17:07:36 -04:00
Shalini Chellathurai Saroja
9363e1e692 virt-xml: add support for mediated devices
Provide support to add/remove MDEV in a guest domain, which is in
shut-off or running state (hotplug/unplug). Also support update of
already existing MDEV device, when the guest domain is in shut-off
state. Please note that libvirt does not support update of MDEV
device, when the guest domain is in running state.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Shalini Chellathurai Saroja <shalini@linux.ibm.com>
2021-06-01 17:07:36 -04:00
Cole Robinson
0f6b73d4f1 github: Update issue template
Reword, and link to the graphical debugging wiki page
https://github.com/virt-manager/virt-manager/wiki/Debugging-VM-graphical-display-issues

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-05-28 15:47:10 -04:00
Han Han
38dd57284f cli: --feature: Support kvm.poll-control.state
Implement kvm.poll-control.state to `virt-install --feature`. It requires
libvirt >= v6.10.0.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Han Han <hhan@redhat.com>
2021-05-28 15:43:38 -04:00
Han Han
a1ddd23c89 virtinst: Support transient.shareBacking option
Implement "<transient shareBacking=yes/>" to virtinst to allow a transient disk
to be shared across VMs. It is introduced to libvirt since:

75871da0ec    qemu: Allow <transient> disks with images shared accross
VMs

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Han Han <hhan@redhat.com>
2021-05-26 19:04:07 -04:00
Han Han
8ef556773d virtinst: Implement support for transient disks
Since libvirt v6.9, the element <transient/> is to configure a disk
which discards its changes while VM was active. Support this element
by cmdline option `--disk ...,transient=on`.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Han Han <hhan@redhat.com>
2021-05-26 19:04:07 -04:00
Han Han
dfd40733f1 virtinst: Support rotation_rate attrib in target
Support rotation_rate attrib which is introduced since libvirt v7.3.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Han Han <hhan@redhat.com>
2021-05-23 17:39:55 -04:00
Cole Robinson
e8272763fc ci: Fix RPM install
This should fix new dep issues as well

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-05-23 15:25:49 -04:00
Cole Robinson
f929bc7b8b ci: Add tqdm to dep list
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-05-23 14:23:59 -04:00
Cole Robinson
12d40bdf62 setup: Mostly convert to setuptools
distutils is slated for removal in python3 eventually:
https://www.python.org/dev/peps/pep-0632/

Mostly switch to setuptools. There's still an issue with the way
that we extend the 'build' command that doesn't seem to have a
setuptools equivalent, but we can hack around it if needed.

Closes: #252

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-05-23 14:23:59 -04:00
Cole Robinson
ed863a66a1 pylint: Another fix for gtk3 version detection
We can't depend on file ordering apparently. Use pylint's
init-hook feature instead

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-05-22 16:21:17 -04:00
Cole Robinson
fe7f4db6e7 host: Use libvirtobject.run_status
Fixes uitest coverage when the host doesn't have any inactive
non-domain objects

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-05-22 16:17:02 -04:00
Cole Robinson
bed31a6a27 virtinst: Use consistent format for meter filename strings
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-05-22 14:56:10 -04:00
Cole Robinson
2024068be8 progress: convert to tqdm
tqdm is an external library that provides a progress bar
implementation. Switch to it and drop our internal copy of the
old urlgrabber progressbar

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-05-22 14:56:10 -04:00
Cole Robinson
6659889319 progress: Some internal API cleanup
* Simplify start() and end() function signature
* Drop use of 'basename' and standardize on 'text'
* Add vmmMeter.is_started()
* Add vmmMeter.set_text()
* Fix asyncjob UI to show text in the progress bar

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-05-22 14:56:10 -04:00
Cole Robinson
167d2f2f8e delete: Ensure storage_errors is always declared
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-05-22 14:56:10 -04:00
Cole Robinson
a53f35e425 viewers: Absorb resizeguest support check
This let's us move the gtkvnc import back
to be solely in viewers.py

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-05-22 14:56:10 -04:00
Cole Robinson
08d1a6a2dd urlfetcher: Delete the 'isoinfo' ISOReader
We didn't delete this in the last commit, mostly to make it easier
to revert this commit if it turns out we need to support both isoinfo
and xorriso. Right now I don't know of any reason why that should
be necessary but time will tell.

If we do go that route it will take more work to teach urlfetcher
to dynamically detect the presence of one or the other, along with
similar tweaks.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-05-22 14:56:10 -04:00
Cole Robinson
f793986378 urlfetcher: Add xorriso ISOReader implementation
xorisso is the still maintained isoinfo alternative, and may be
the only iso reading tool in RHEL9, so we need to support it.
Make it the default for our spec file and test suite too

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-05-22 14:56:10 -04:00
Cole Robinson
b13b5e0f5e urlfetcher: Factor out ISOReader class
This contains all the isoinfo command logic. This will be used
to add an xorriso backend as well

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-05-22 14:56:10 -04:00
Cole Robinson
a8e978dd38 pylint: Another fix for gtk3 version detection
We need to place require_version calls earlier and before
any code that might import Gtk/Gdk

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-05-22 14:56:10 -04:00
Cole Robinson
99a2818d0e tests: test_urls: Update some URLs
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-05-22 13:04:06 -04:00
Cole Robinson
3785abc6f0 installer: Prefer xorrisofs over genisoimage/mkisofs
Apparently it's the most likely version to exist in distros these
days. Particularly the other options may not be shipped in stock
RHEL9

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-05-22 13:04:06 -04:00
Cole Robinson
b891018d48 pylint: Ignore consider-using-with
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-05-22 13:03:47 -04:00
Cole Robinson
61a4c00835 tests: uitests: Add mock test for VNC autoresize
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-05-19 16:46:30 -04:00
Daniel P. Berrangé
499739cee3 details: enable resizing of displays with new GtkVnc
The 1.2.0 release of GtkVnc introduces support for remote desktop
resize. This is also supported in QEMU >= 6.0.0 when using virtio-gpu.

This introduces support for resize without forcing a new min version of
GtkVnc by just checking for existance of the new API. We don't attempt
to check if the current QEMU instance supports resize, as we gracefully
degrade - the guest simply won't resize and will be rendered as before.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2021-05-19 16:30:00 -04:00
Shalini Chellathurai Saroja
965480e8bc virt-install: add mediated device
Add support to install a virtual server with passed-through mediated
device. Mediated device can be created using vGPU attached to
vfio_pci driver or DASD attached to vfio_ccw driver or APQNs attached
to vfio_ap driver.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Shalini Chellathurai Saroja <shalini@linux.ibm.com>
2021-05-18 18:36:03 -04:00
Renan Birck Pinheiro
2421214101 Translated using Weblate (Portuguese (Brazil))
Currently translated at 79.1% (1119 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/
2021-04-14 14:50:59 -04:00
Weblate
ea8d6a0aa1 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2021-04-14 14:50:59 -04:00
Jan Kuparinen
03629d90f9 Translated using Weblate (Finnish)
Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fi/
2021-04-14 14:50:59 -04:00
Fabio Tomat
1dd95d5fe7 Translated using Weblate (Friulian)
Currently translated at 49.2% (697 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fur/
2021-04-14 14:50:59 -04:00
simmon
3ebda9e9fd Translated using Weblate (Korean)
Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/

Translated using Weblate (Korean)

Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/

Translated using Weblate (Korean)

Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/

Translated using Weblate (Korean)

Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/

Translated using Weblate (Korean)

Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/

Translated using Weblate (Korean)

Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/

Translated using Weblate (Korean)

Currently translated at 81.4% (1151 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/

Translated using Weblate (Korean)

Currently translated at 75.6% (1069 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/

Translated using Weblate (Korean)

Currently translated at 72.8% (1030 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/

Translated using Weblate (Korean)

Currently translated at 69.9% (989 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/

Translated using Weblate (Korean)

Currently translated at 68.0% (962 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/
2021-04-14 14:50:59 -04:00
Rodrigo Tavares
da54ad0f16 Translated using Weblate (Portuguese (Brazil))
Currently translated at 78.6% (1112 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/
2021-04-14 14:50:59 -04:00
Ricky Tigg
d9483b931e Translated using Weblate (Finnish)
Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fi/

Translated using Weblate (Finnish)

Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fi/

Translated using Weblate (Finnish)

Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fi/
2021-04-14 14:50:59 -04:00
Hela Basa
0db719b929 Added translation using Weblate (Sinhala) 2021-04-14 14:50:59 -04:00
Gustavo Costa
ce31779ba6 Translated using Weblate (Portuguese (Brazil))
Currently translated at 75.0% (1061 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/
2021-04-14 14:50:59 -04:00
Марко Костић (Marko Kostić)
a3796361f4 Translated using Weblate (Serbian)
Currently translated at 20.5% (290 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sr/
2021-04-14 14:50:59 -04:00
Weblate
9eaf888e48 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2021-04-14 14:50:59 -04:00
Osvaldo R. Salazar S
6bb7c00f6c Translated using Weblate (Spanish)
Currently translated at 76.9% (1088 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/es/
2021-04-14 14:50:59 -04:00
Jan Kuparinen
f4a4291e9e Translated using Weblate (Finnish)
Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fi/
2021-04-14 14:50:59 -04:00
Weblate
a500ca15d3 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/

Update translation files

Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2021-04-14 14:50:59 -04:00
Teknős Ferenc
73aa1ac169 Translated using Weblate (Hungarian)
Currently translated at 54.7% (774 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/hu/
2021-04-14 14:50:59 -04:00
Jonatan Nyberg
4dd5ad8130 Translated using Weblate (Swedish)
Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sv/
2021-04-14 14:50:59 -04:00
Dmitry Astankov
20789cc3e3 Translated using Weblate (Russian)
Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ru/
2021-04-14 14:50:59 -04:00
Arnaud T
9fb654cdcc Translated using Weblate (French)
Currently translated at 90.8% (1284 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fr/
2021-04-14 14:50:59 -04:00
Lucas Fernandes
4e026ec88f Translated using Weblate (Portuguese (Brazil))
Currently translated at 72.7% (1029 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/
2021-04-14 14:50:59 -04:00
Andika Triwidada
d9e84194f0 Translated using Weblate (Indonesian)
Currently translated at 6.5% (93 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/
2021-04-14 14:50:59 -04:00
Ricky Tigg
34543aa6fb Translated using Weblate (Finnish)
Currently translated at 96.4% (1364 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fi/

Translated using Weblate (Finnish)

Currently translated at 59.1% (837 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fi/
2021-04-14 14:50:59 -04:00
Pino Toscano
d032340338 Translated using Weblate (Italian)
Currently translated at 98.5% (1394 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/

Translated using Weblate (Italian)

Currently translated at 98.5% (1394 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2021-04-14 14:50:59 -04:00
Weblate
c277a9e465 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2021-04-14 14:50:59 -04:00
Whired Planck
9184400bba Translated using Weblate (Chinese (Simplified) (zh_CN))
Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_CN/

Translated using Weblate (Chinese (Traditional))

Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_TW/

Translated using Weblate (Chinese (Simplified))

Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_CN/

Translated using Weblate (Chinese (Simplified))

Currently translated at 99.3% (1405 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_CN/
2021-04-14 14:50:59 -04:00
Oğuz Ersen
aab857a7ba Translated using Weblate (Turkish)
Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/tr/
2021-04-14 14:50:58 -04:00
Yuri Chornoivan
ddd80cff4c Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2021-04-14 14:50:58 -04:00
Göran Uddeborg
08688d5238 Translated using Weblate (Swedish)
Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sv/
2021-04-14 14:50:58 -04:00
Piotr Drąg
49d97641e2 Translated using Weblate (Polish)
Currently translated at 100.0% (1414 of 1414 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pl/
2021-04-14 14:50:58 -04:00
Weblate
a6014a31a6 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/

Update translation files

Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2021-04-14 14:50:58 -04:00
Pino Toscano
33da4f71a5 Translated using Weblate (Italian)
Currently translated at 98.5% (1393 of 1413 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2021-04-14 14:50:58 -04:00
Cole Robinson
ff0c8458e2 keyring: Coverage and style fixes
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-04-06 19:20:16 -04:00
WGH
9b00bf3e1c Support prompt in keyring CreateItem as well
I haven't seen the implementation that needs prompt confirmation here,
though, so I haven't really tested it. The code path is pretty much the
same as in Delete, though, which I did test.
2021-04-06 18:30:08 -04:00
WGH
fae3fecc1e Improve Secret Service interoperability
The current implementation of Secret Service keyring client assumes that
the last component of an item path is integer, which is not true for some
Secret Service server implementations (e.g. KeePassXC). Besides,
the Secret Service API documents advises against recording object path
(not to mentioning parsing it in any way), recommending using lookup attributes
instead[1].

This commit fixes the code to behave in more interoperable way.

- The item path (called "keyid" in code) is no longer parsed and stored anywhere.
- The secret item is looked up in the Secret Service using hvuri and machine
  uuid attributes.
- /console-password with (username, keyid) is removed from GSettings
  storage. Instead, only username is stored in /console-username.

[1] https://specifications.freedesktop.org/secret-service/latest/ch03.html

Resolves: #237
2021-04-06 18:30:08 -04:00
WGH
d9b5090e06 Fix forgetting password from keyring
First, Item.Delete never accepted any arguments, so this code likely
never worked.

Second, Item.Delete might return a Prompt object, which client
is supposed to call if keyring wants to confirm deletion.
2021-04-06 18:30:08 -04:00
Cole Robinson
5b93a43622 pylint: Make sure we lint against Gtk3
We need to pass virtmanager.py to pylint first, so it detects
the require_version() call

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-04-06 18:28:48 -04:00
Cole Robinson
511857b288 pylint: Exclude use-a-generator
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-04-06 18:11:19 -04:00
Cole Robinson
12517e0a28 tests: Fix --sound audio.id test
libvirt validates this, but we don't support <audio> devices yet,
so find another way

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-04-06 17:06:41 -04:00
Cole Robinson
87ce425197 tests: storage: Fix with latest libvirt XML output
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-04-06 15:21:00 -04:00
Cole Robinson
fe8722e763 createnet: Remove some unnecessary max_length annotations
Fixes: #238

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-04-06 13:35:15 -04:00
Cole Robinson
f4eed36863 DESIGN: Hiding viewer menu bar has been rejected
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-03-10 16:55:19 -05:00
Jonathan Schwender
f9a0c3ccb2 cli: --cputune: add vcpusched[0-9]* config
This adds the following suboptions to configure <cputune>:

- vcpusched.vcpus
- vcpusched.scheduler
- vcpusched.priority

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2021-02-16 16:37:15 -05:00
Cole Robinson
d304a9b205 tests: More bhyve UEFI testing
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-02-15 13:39:16 -05:00
Roman Bogorodskiy
1bcd442bfd virtinst: bhyve: configure nmdm console
Bhyve only supports nmdm console type, so use it instead of TYPE_PTY.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Roman Bogorodskiy <bogorodskiy@gmail.com>
2021-02-15 13:27:48 -05:00
Roman Bogorodskiy
6c7080a39b virtinst: bhyve: properly configure loader
Bhyve requires explicit loader configuration. So query
domain capabilities, try to find the "official"
firmware and configure all the necessary loader options.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Roman Bogorodskiy <bogorodskiy@gmail.com>
2021-02-15 13:27:48 -05:00
Roman Bogorodskiy
dab099d413 virtinst: prefer SATA bus for bhyve
Choose SATA as a default bus for bhyve as it doesn't support IDE.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Roman Bogorodskiy <bogorodskiy@gmail.com>
2021-02-15 13:27:48 -05:00
Roman Bogorodskiy
2d254f2815 tests: cli: start testing bhyve
Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Roman Bogorodskiy <bogorodskiy@gmail.com>
2021-02-15 13:27:48 -05:00
Cole Robinson
404507b3ad virt-manager: Require pygobject >= 3.31.3
This is the first version that universally treats a None value as
bool False. Most recent code changes have been developed against this
version of pygobject, and several backwards incompatible None usages
have slipped in, and I suspect there's more lurking.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-02-10 12:43:53 -05:00
Cole Robinson
8bf03dad2c spec: gtk3 >= 3.22.0 is required
This is already forced in the code

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-02-10 12:43:53 -05:00
Cole Robinson
db44332791 tests: Fix virt-xml test case
This would have caught the bug Roman just fixed

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-02-10 10:27:35 -05:00
Roman Bogorodskiy
143c6befc3 virtinst: fix error message format string
Fix a regression introduced by commit 71f034d6b where
format string expects kwarg "domain", but "vm" is passed instead.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Roman Bogorodskiy <bogorodskiy@gmail.com>
2021-02-10 10:26:23 -05:00
Pavel Hrdina
cf93e2dbff console: fix error with old pygobject
The code doesn't work as expected. From python documentation:

    x and y

is the same as

    x if not x or y

so in the code if for some reasone `dev` is None the value stored in
`sensitive` will be None as well.

No the code itself works with pygobject >= 3.31.3 where they allowed
None as a valid boolean value, but with older versions it will fail
with this error message:

    TypeError: Argument 1 does not allow None as a value

Resolves: https://github.com/virt-manager/virt-manager/issues/226

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2021-02-05 12:15:46 +01:00
Cole Robinson
d3c627f189 volumeupload: Use 1MiB read size
Rather than 1K. This drastically speeds up the volumeupload case
for a local URI for the cost of some higher runtime memory but
I think that's worth it

Fixes: #221

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-02-03 14:15:57 -05:00
freddii
1c98328e82 fixed typos 2021-02-02 17:02:24 -05:00
Cole Robinson
56cb813d42 cli: Add --tpm persistent_state=
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-01-24 18:54:54 -05:00
Cole Robinson
2862f1be98 cli: Add --memballoon freePageReporting=
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-01-24 18:49:55 -05:00
Cole Robinson
5c1ace02c9 cli: Add --sound audio.id=
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-01-24 18:48:09 -05:00
Cole Robinson
d3517ded62 cli: Add --filesystem fmode, dmode
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-01-24 18:46:47 -05:00
Cole Robinson
5a152712d9 details: Log the active_edits list when warning about unapplied changes
This pops up randomly sometimes for reasons I can't determine yet.
logging this will help narrow it down when it does crop up

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2021-01-19 12:22:31 -05:00
Cole Robinson
60ecc1c223 uitests: createvm: Fix with latest osinfo
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-12-07 14:54:13 -05:00
Cole Robinson
41eda8a431 tests: Remove now redundant LANG overrides
We added a central one in the previous commit

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-12-07 14:32:27 -05:00
Pino Toscano
fdc621e05f tests: force an English UTF-8 locale
Various checks in the test suite try to match for error/status messages,
so using a localized libvirt (or even using translations of an installed
version of virt-manager in the system) makes those check fail.
Hence, force (using $LANG, and unsetting $LANGUAGE) an English UTF-8
locale.

Thanks Cole Robinson for spotting the right place where to inject the
locale settings.

Fixes: #199

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-12-07 13:50:00 -05:00
Martin Pitt
4d0e323227 virtinst: Fix TOCTOU in domain enumeration
Similar to commit 49a01b5482, _fetch_all_domains_raw() has a race
condition where a domain may disappear (from parallel libvirt
operations) in between enumerating and inspecting the objects.

Ignore these missing domains instead of crashing.

https://bugzilla.redhat.com/show_bug.cgi?id=1901081
2020-12-01 13:56:30 -05:00
Igor Ryzhov
19fc6c1708 spec: fix python macro
It looks like there is no %{python3} macro in CentOS 8.
Using %{__python3} should be always safe.

Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
2020-12-01 10:26:43 -05:00
Cole Robinson
e7222b5058 addstorage: Don't pass None to widget.set_active()
Older pygobject can't handle it. Mentioned here:
https://github.com/virt-manager/virt-manager/issues/188

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-11-21 17:17:33 -05:00
Igor Ryzhov
ac9316cce1 virtinst: add support for controller target subelement
Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
2020-11-21 14:47:22 -05:00
Cole Robinson
7541065d09 systray: Appindicator tweaks
- Prefer ayatana if it's available, since that's the modern library
- Fix some pylint and code coverage issues

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-11-16 11:11:19 -05:00
Laurent Bigonville
ac7e6a0966 Try to load AyatanaAppIndicator3 in addition of AppIndicator3
AyatanaAppIndicator3 is the successor or AppIndicator3 it uses the same API for the time being

Just try to load AyatanaAppIndicator3 in addition of AppIndicator3

Fixes: #181
2020-11-16 10:09:19 -05:00
Cole Robinson
ddc55c8ba5 hostdev: Log XML of the source nodedev device
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-11-14 18:17:32 -05:00
Cole Robinson
cd788e9303 Prep for release 3.2.0
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-11-14 16:15:22 -05:00
Weblate
88ec96a932 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2020-11-14 16:13:46 -05:00
Jan Nerad
d380ed2e8e Translated using Weblate (German)
Currently translated at 71.6% (1012 of 1413 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/de/
2020-11-14 16:13:46 -05:00
Samuel Heinzmann
263cbbe5e1 Translated using Weblate (German)
Currently translated at 71.6% (1012 of 1413 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/de/
2020-11-14 16:13:46 -05:00
Pino Toscano
1af30029b5 Translated using Weblate (Italian)
Currently translated at 98.5% (1392 of 1413 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/

Translated using Weblate (Italian)

Currently translated at 98.5% (1392 of 1413 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2020-11-14 16:13:46 -05:00
scootergrisen
40391c67d2 Translated using Weblate (Danish)
Currently translated at 16.0% (227 of 1413 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/da/

Translated using Weblate (Danish)

Currently translated at 15.9% (226 of 1413 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/da/
2020-11-14 16:13:46 -05:00
Oğuz Ersen
ce3df9727b Translated using Weblate (Turkish)
Currently translated at 100.0% (1413 of 1413 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/tr/

Translated using Weblate (Turkish)

Currently translated at 73.8% (1043 of 1413 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/tr/
2020-11-14 16:13:46 -05:00
Github Actions
6946573d72 Refresh translation .pot template 2020-11-14 16:13:46 -05:00
Github Actions
01930b0d58 Refresh translation .pot template 2020-11-14 16:13:46 -05:00
Github Actions
b7e14eef03 Refresh translation .pot template 2020-11-14 16:13:46 -05:00
Github Actions
9a655bd31a Refresh translation .pot template 2020-11-14 16:13:46 -05:00
Cole Robinson
110959a371 tests: test_urls: Fix dead links
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-11-14 16:11:28 -05:00
Cole Robinson
f81c07d2da details: Add simplified wrapper for change_config_helper
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-11-14 16:09:21 -05:00
Cole Robinson
488f153655 fsdetails: Rework XML building logic
Make it work more like gfxdetails. The problem with the current
approach is that it requires effectively rebuilding the whole device
to match the original device when we want to edit a single field,
which is error prone.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-11-14 16:09:21 -05:00
Cole Robinson
fca338d2d1 fsdetails: Remove some dead code
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-11-13 17:05:00 -05:00
Cole Robinson
41023192ca fsdetails: Stop showing the 'driver' combo for qemu
The only valid value now is 'path' which is also the default,
so drop the UI

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-11-13 13:17:41 -05:00
Cole Robinson
b7b75ab8fc fsdetails: Drop driver="handle" UI
It was removed in qemu 4.0.0

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-11-13 13:09:03 -05:00
Cole Robinson
2b864a9294 fsdetails: Remove the combo vs label dynamic
If something would normally be shown only in a label, just
hide the row entirely. This was interesting for viewer XML
properties before we had the XML editor, but now it doesn't
add much

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-11-13 12:53:10 -05:00
Cole Robinson
374ea52be0 fsdetails: Remove wrpolicy UI
This is an obscure setting. If users need it they can set
it manually in the XML editor

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-11-13 12:20:57 -05:00
Cole Robinson
4cfb3aeff1 cloner: more detailed error messages about supported network vols
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-11-11 19:06:32 -05:00
Cole Robinson
6a6c1c13d7 diskbackend: Fix volume lookup for existing rbd disk
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-11-11 19:06:32 -05:00
Cole Robinson
3d07b28a36 device: disk: Rename path property to get/set_source_path
This makes it more clear that 'path' is really a special designation
with a bunch of complicated logic behind it. It's also easier to
grep for

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-11-11 19:06:32 -05:00
Cole Robinson
c4f5812290 device: disk: Group related functions
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-11-11 18:07:50 -05:00
Cole Robinson
b3ff59c75c device: disk: Move <source> XML handling to its own class
Makes DeviceDisk less complicated, helps with readability

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-11-11 18:07:50 -05:00
Cole Robinson
9f930bd329 tests: uitests: fix clone case after recent changes
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-11-11 18:07:50 -05:00
Cole Robinson
98ca65f183 connection: Unconditionally report connection leak
Leaked connection may mean the app keeps libvirtd socket activated
daemon running for longer than necessary, so it's useful to report
this

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-11-10 17:41:20 -05:00
Cole Robinson
2773bc35bf storagepool: cleanup() volumes on pool cleanup()
Fixes connection leaks

Resolves: #172

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-11-10 17:40:31 -05:00
Cole Robinson
d9c6df951f installer: Remove cloudinit media after initial boot
We do this by faking an install phase whenever cloudinit media is
specified, which isn't really the right abstraction and will leak
into virt-install behavior (like doing 2 boots), but it's the simplest
fix for now

Fixes: #178

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-11-10 12:04:25 -05:00
Cole Robinson
b132820244 devices: disk: Skip check_path_search for path=""
virt-manager can trigger this when ejecting cdrom media

Fixes: #180

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-11-10 12:04:25 -05:00
Martin Pitt
49a01b5482 virtinst: Fix TOCTOU in pool and volume enumeration
_fetch_all_pools_raw() and _fetch_vols_raw() have a race condition where
a pool/volume may disappear (from parallel libvirt operations) in
between enumerating and inspecting the objects.

_fetch_vols_raw() already expected that failure in the loop, but not for
the initial storagePoolLookupByName() call.

Also tighten the expected exception: This *should* crash on errors like
AttributeError or SystemExit, just not on dynamic libvirt errors. (Bare
exceptions are highly frowned upon in Python)

https://bugzilla.redhat.com/show_bug.cgi?id=1894359
2020-11-08 17:01:40 -05:00
emojifreak
04ad8df752 Added Debian's armv7l UEFI binary. Closes #174 2020-11-03 13:49:27 -05:00
Cole Robinson
f4dc418e66 virtclone: Only print/log 'clone successful' if we actually clone
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-11-03 13:15:47 -05:00
Cole Robinson
8988572776 virtclone: Drop --print-xml special --auto-clone behavior
For unclear reasons we allowed --print-xml without --file or
--auto-clone, like is required for a traditional clone, which
can lead to some weird behavior.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-11-03 13:03:22 -05:00
Cole Robinson
1a1e4580c0 cloner: Explicitly reject 'network' disks we don't know how to clone
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-11-03 13:03:03 -05:00
Cole Robinson
2d4b85b5bf domain: use makedirs exist_ok=True
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-11-03 12:23:13 -05:00
Charles Arnold
9dc057e3e7 Add /usr/sbin to search path for non-root user
On a fresh install where no previous connection has been made a
non-root user starting virt-manager won't find the installed libvirtd
because the location is not in the user path.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Charles Arnold <carnold@suse.com>
2020-11-03 12:23:13 -05:00
Martin Pitt
7cb6a6062a virtinst: Fix TOCTOU race in user scratch dir creation
When starting many virt-install processes in parallel, some often crash
with

    ERROR    [Errno 17] File exists: '/home/kstest/.cache/virt-manager/boot'

Fix that by ignoring existing directories instead of explicitly testing
for existence.

The `exist_ok` parameter exists since Python 3.2, and the minimum
supported version is 3.4 now.
2020-11-03 11:52:46 -05:00
Cole Robinson
d0650aa48f osdict: Handle possible conflicting os named 'generic'
It's not impossible osinfo-db adds a 'generic' OS of its own, in
which case we will start misbehaving. Rework the way we implement
our synthetic 'generic' OS internally, using a stub Libosinfo.Os()

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-10-21 18:49:11 -04:00
Cole Robinson
b17914591a Prep for release 3.1.0 2020-09-30 18:06:22 -04:00
Cole Robinson
0643adfc49 uitests: Make sure we hit details perf page coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-30 17:44:15 -04:00
Cole Robinson
af63df9793 tests: Fix test_urls after pytest conversion
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-30 16:55:13 -04:00
Cole Robinson
3b96c32c49 po: Fix format error in cs.po
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-30 16:52:13 -04:00
Whired Planck
0c40a60c0c Translated using Weblate (Chinese (Simplified))
Currently translated at 98.9% (1398 of 1413 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_CN/
2020-09-30 16:51:16 -04:00
Oğuz Ersen
7b4abfc238 Translated using Weblate (Turkish)
Currently translated at 71.8% (1015 of 1413 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/tr/
2020-09-30 16:51:16 -04:00
Weblate
bc5f98e833 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/

Update translation files

Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2020-09-30 16:51:15 -04:00
Pino Toscano
d8a69d41e4 Translated using Weblate (Italian)
Currently translated at 98.5% (1392 of 1413 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2020-09-30 16:51:15 -04:00
Fabio Tomat
a30ac4cbdd Translated using Weblate (Friulian)
Currently translated at 39.3% (556 of 1413 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fur/
2020-09-30 16:51:15 -04:00
Yuri Chornoivan
f264994507 Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1413 of 1413 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2020-09-30 16:51:15 -04:00
Oğuz Ersen
7c7a24a0b6 Translated using Weblate (Turkish)
Currently translated at 56.2% (795 of 1413 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/tr/
2020-09-30 16:51:15 -04:00
Göran Uddeborg
bada9d5750 Translated using Weblate (Swedish)
Currently translated at 100.0% (1413 of 1413 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sv/

Translated using Weblate (Swedish)

Currently translated at 98.2% (1388 of 1413 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sv/
2020-09-30 16:51:15 -04:00
Pavel Borecki
f07dde41e7 Translated using Weblate (Czech)
Currently translated at 100.0% (1413 of 1413 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/cs/
2020-09-30 16:51:15 -04:00
Piotr Drąg
36f05e1099 Translated using Weblate (Polish)
Currently translated at 100.0% (1413 of 1413 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pl/
2020-09-30 16:51:15 -04:00
Weblate
8aeec7c6bb Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2020-09-30 16:51:15 -04:00
Whired Planck
35754d8310 Translated using Weblate (Chinese (Simplified))
Currently translated at 98.6% (1399 of 1418 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_CN/
2020-09-30 16:51:15 -04:00
Göran Uddeborg
4f7361c23a Translated using Weblate (Swedish)
Currently translated at 97.1% (1377 of 1418 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sv/
2020-09-30 16:51:15 -04:00
Yuri Chornoivan
9e7de5eb7f Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1418 of 1418 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2020-09-30 16:51:15 -04:00
Oğuz Ersen
737c3fcc7c Translated using Weblate (Turkish)
Currently translated at 56.4% (800 of 1418 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/tr/

Translated using Weblate (Turkish)

Currently translated at 54.7% (776 of 1418 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/tr/
2020-09-30 16:51:15 -04:00
Pino Toscano
4e726f2465 Translated using Weblate (Italian)
Currently translated at 98.5% (1397 of 1418 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/

Translated using Weblate (Italian)

Currently translated at 98.4% (1396 of 1418 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/

Translated using Weblate (Italian)

Currently translated at 97.8% (1387 of 1418 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2020-09-30 16:51:15 -04:00
Pavel Borecki
30dc5121c9 Translated using Weblate (Czech)
Currently translated at 100.0% (1418 of 1418 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/cs/
2020-09-30 16:51:15 -04:00
Piotr Drąg
84c9542328 Translated using Weblate (Polish)
Currently translated at 100.0% (1418 of 1418 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pl/
2020-09-30 16:51:15 -04:00
Weblate
a209ea704d Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2020-09-30 16:51:15 -04:00
Whired Planck
43e1a1ed2f Translated using Weblate (Chinese (Simplified))
Currently translated at 100.0% (1410 of 1410 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_CN/
2020-09-30 16:51:15 -04:00
Oğuz Ersen
ef5a6b02a2 Translated using Weblate (Turkish)
Currently translated at 54.8% (774 of 1410 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/tr/
2020-09-30 16:51:15 -04:00
Göran Uddeborg
08b3d825a6 Translated using Weblate (Swedish)
Currently translated at 97.1% (1370 of 1410 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sv/
2020-09-30 16:51:15 -04:00
Weblate
1092019606 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2020-09-30 16:51:15 -04:00
Yuri Chornoivan
56129a46ef Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1410 of 1410 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2020-09-30 16:51:15 -04:00
Göran Uddeborg
26eb732e59 Translated using Weblate (Swedish)
Currently translated at 91.3% (1288 of 1410 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sv/
2020-09-30 16:51:15 -04:00
Pino Toscano
34512fefce Translated using Weblate (Italian)
Currently translated at 98.2% (1386 of 1410 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2020-09-30 16:51:15 -04:00
Cole Robinson
96996fad30 Added translation using Weblate (Kabyle) 2020-09-30 16:51:15 -04:00
Piotr Drąg
f938c3ba27 Translated using Weblate (Polish)
Currently translated at 100.0% (1410 of 1410 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pl/
2020-09-30 16:51:15 -04:00
scootergrisen
9df7a66dfc Translated using Weblate (Danish)
Currently translated at 15.3% (216 of 1410 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/da/

Translated using Weblate (Danish)

Currently translated at 15.1% (214 of 1410 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/da/
2020-09-30 16:51:15 -04:00
Github Actions
b7b9907b2d Refresh translation .pot template 2020-09-30 16:51:15 -04:00
Cole Robinson
129865aea0 mediacombo: Clear text entry when New VM is launched
We were leaving the ISO field populated with whatever the old value
was. This is likely useful in some cases but it's consistent with
how we handle fields in the rest of the wizard, and has some weird
interaction with OS detection

Fixes: #159

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-30 10:35:21 -04:00
Cole Robinson
f7bd274a55 domcaps: Fix error if enum not found
https://bugzilla.redhat.com/show_bug.cgi?id=1883008

In the example above this is because the VM XML has an invalid machine
type, so domcaps fetching entirely fails, and a get_enum() call
then fails. But this could happen if using virt-manager against an
older libvirt that doesn't advertise the enum

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-28 13:44:34 -04:00
Cole Robinson
9c13d2f878 Remove use of problematic terminology
Following kernel recommendation here:
https://lkml.org/lkml/2020/7/4/229

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-23 14:33:17 -04:00
Cole Robinson
12fe58cd91 uitests: Use drag() method again for window cleanup tests
delete and createvm tests launch a dialog which obstructs the
manager UI. The location can be kinda random, and it might obstruct
selecting the connection in the manager window. Go back to using
the drag() window pattern to make this more deterministic

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-22 11:28:21 -04:00
Cole Robinson
9a5ab50b51 gfxdetails: Use a single 'changed' signal
And absord device building from addhardware. This moves all the
knowledge to gfxdetails, which saves sprinkling it around in other
places

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-21 22:11:17 -04:00
Cole Robinson
e5a51f6374 details: Change Close accelerator to ctrl+shift+w
Close accelerator changes ctrl+w -> ctrl+shift+w
Quit accelerator changes ctrl+q -> ctrl+shift+q

After aafb874c8, if the mouse pointer isn't inside the console
window, it has keyboard focus but ctrl+w will be sent to the vmwindow
and not the VM. ctrl+w is a common shortcut for deleting a word so
this is pretty disruptive if you are typing inside the VM

Use gnome-terminal-esque accelerators starting with ctrl+shift to
reduce the chance of collision.

https://bugzilla.redhat.com/show_bug.cgi?id=1880295

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-21 14:33:25 -04:00
Cole Robinson
79ebcbcb71 viewers: Fix spice audio
Commit 1689ebb25 removed what I thought was an unused audio
handle in the spice viewer code, but apparently it does
something. Strangely some VMs work fine (linux, windows 7),
but my windows 10 VMs need this to actually get audio.
No clue what that's all about

https://bugzilla.redhat.com/show_bug.cgi?id=1881080

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-21 11:35:51 -04:00
Cole Robinson
e58cc956b5 vmwindow: vm state-changed update flow changes
* Don't process events when the window isn't showing
* Only update console/details if that tab is actually selected.
    Otherwise in some corner cases we can connect to the VM console
    while on the details page

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-21 09:06:18 -04:00
Cole Robinson
c0c704e1fa console: Move _change_title behavior to vmwindow
This is where it conceptually belongs

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-21 09:06:18 -04:00
Cole Robinson
95f363d634 vmwindow: Rename some functions for clarity
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-21 09:06:18 -04:00
Cole Robinson
518f230f76 vmwindow: Remove non-events XML refreshing on resource tick
This is an awkward place to put it, and I'm pretty sure it's not
even useful in the non-events case nowadays due to improved
libvirtobject.py infrastructure

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-21 09:06:18 -04:00
Cole Robinson
301577c2f6 details: Make disk_bus_index handling less hacky
In weird corner cases this can trigger tracebacks, if the boot
page is refreshed while the hardware list changed underneath us.
This is a step in the direction of unwinding it.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-21 09:06:18 -04:00
Cole Robinson
05174f3719 uitests: More workaround for newvm wizard focus grab issues
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-20 19:48:22 -04:00
Cole Robinson
295c8a86dd details: Add host-passthrough as an explicit CPU UI choice
Historically we have not advertised host-passthrough because it was
not recommended for general usage. That stance is softening,
tools like gnome-boxes already set it as the default, and users
continue to ask about it.

We may change the default in virt-manager but it will take more
discussion. This is a tiny move in the direction of hiding it less
than we already do.

Drop the label for host-model and call it by its libvirt XML name,
since otherwise it's hard to tell which combo choice is for each
value

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-20 18:21:43 -04:00
Cole Robinson
2f7931da63 createvol: Drop Allocation field in favor of checkbox
Inspired by some discussion from here:
https://bugzilla.redhat.com/show_bug.cgi?id=1759454

Most libvirt storage volume creation doesn't actually do anything
with allocation, besides interpreting cap == alloc and cap != alloc.
The exceptions are zfs volumes, and raw file volumes. But it's unclear
what the usecase is for the latter at all.

This drops the allocation spinner and adds checkbox in its place
'Allocate entire volume now'. When enabled, it sets cap == alloc.

We only show this for file volumes. For qcow2 it defaults to unselected
(sparse), for all others it defaults to selected. If it's not showing,
it defaults to selected.

Bundled with this change is showing this field for qcow2, where
we previously only allowed nonsparse here. Libvirt and qemu-img
support non-sparse qcow2 these days.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-20 17:08:39 -04:00
Cole Robinson
5c1f4b2386 virtinst: storage: gluster pools don't support volume creation
Drop code that implies they do

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-20 16:44:24 -04:00
Cole Robinson
a010c49b8b cli: Fix --os-variant=help introspection
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-20 16:00:46 -04:00
Cole Robinson
81eae9b181 docs: Add github ISSUE_TEMPLATE
Adjust existing docs to better document running code from git

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-20 14:35:05 -04:00
Cole Robinson
092a62552c uitests: More work to drop sleeping and hacks
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-20 14:32:55 -04:00
Cole Robinson
ba08f84b34 addstorage: Return to using qcow2 sparse by default
https://bugzilla.redhat.com/show_bug.cgi?id=1759454

See 15a6a7e2105440df528f75c4df4d2471df28bd1e

The idea behind virt-manager's sparse vs nonsparse default, is that if
the user selected 'raw' for as the default image format, assume they
want to maximize performance, so fully allocate the disk.

qcow2 didn't support anything except sparse, so the sparse=True vs
sparse=False made no difference. So we always set sparse=False

Then qcow2 grows non-sparse support, and virt-manager is suddenly
defaulting to it, which is not the intention.

Default to sparse when requested format isn't raw

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-20 10:11:36 -04:00
Cole Robinson
6f8b9c13a7 uitests: Test raw diskimage default via keyfile
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-20 10:11:36 -04:00
Cole Robinson
6a88f92fd0 preferences: Unconditionally add VM sound devices
This is another preference that was added before anyone ever asked
for it. I'm fine with suggesting users remove the device manually
if they don't want it

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-19 17:10:19 -04:00
Cole Robinson
748639702e preferences: Unconditionally add usbredir devs for spice
Remove the preference option to disable this. This was added with
the initial usbredir support because I was afraid people would
complain. They did complain, but only about the auto redir behavior
of the spice client. We still have a toggle to disable that behavior

If people don't want usbredir devices, I'm comfortable telling
them to remove them manually, or use virt-install

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-19 17:10:19 -04:00
Cole Robinson
8ce83dbc53 uitests: big mess of work
* Convert to pytest style functions
* Move lots of shared code to our App class
* Reduce dogtail sleep amounts to speed up the whole testsuite
* Improve robustness in a lot of areas

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-19 17:10:19 -04:00
Cole Robinson
799c82584c virt-manager: Stop suppressing all warnings
This is hiding useful stuff. It was enabled once upon a time because
it was too noisy but let's see if it gets bad like the past

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-19 14:28:05 -04:00
Cole Robinson
7f310b32c4 uitests: More use of check_onscreen
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-19 13:47:36 -04:00
Cole Robinson
64eb8663a1 uitests: test_cli improvements
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-19 13:47:30 -04:00
Cole Robinson
4193aa2bb0 app: Slight rework of wait_for_exit
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-19 13:47:04 -04:00
Cole Robinson
fa322588b4 tests: Drop most unittest usage from virtinst tests
Kill usage of the TestCase class, move more to pytest standard
style

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-19 13:46:46 -04:00
Cole Robinson
b79ee9565f tests: Rename test_xmlconfig.py to test_misc.py
That's what it is now, just a collection of misc virtinst tests

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-19 13:46:33 -04:00
Cole Robinson
4c4753d910 tests: break out test_disk.py
Move a bunch of misc disk/diskbackend tests to this file

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-19 13:46:22 -04:00
Cole Robinson
0ac9ff3488 tests: Drop a bunch of redundant xmlparse/xmlconfig tests
For the few bits we are hitting specific code paths, break them
out or fold them into other test cases

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-19 13:46:08 -04:00
Cole Robinson
1b93c17564 cli: Add --controller vectors=X
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-19 13:45:07 -04:00
Cole Robinson
71ac3ee044 tests: Convert to use pytest style 'assert'
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-19 13:44:50 -04:00
Cole Robinson
2d8c1c5ab9 tests: capabilities: Fix coverage after string changes
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-17 15:38:42 -04:00
Pino Toscano
748bb7d774 i18n: fix string puzzles in capabilities lookup error msgs
Create complete sentences with all the details available; there are not
many combinations, so this makes it possible to properly translate them.

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-09-17 15:38:42 -04:00
Pino Toscano
a74f22c49a i18n: use a single string for error message
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-09-17 15:38:42 -04:00
Pino Toscano
adeabb6e40 i18n: use plural forms where needed
In particular, when the number of objects depends on a variable.

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-09-17 15:38:42 -04:00
Pino Toscano
fb8a31ba76 i18n: translate UI messages
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-09-17 15:38:42 -04:00
Pino Toscano
76593f8a08 virtinst: use fail_conflicting
Make use of the new helper for showing a standard error message for two
conflicting cli options. This also catches one untranslatable message.

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-09-17 15:38:42 -04:00
Pino Toscano
8501206cb3 cli: add fail helper for 2 conflicting cli options
It will avoid repeating the same message in different places.

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-09-17 15:38:42 -04:00
Pino Toscano
924d766112 i18n: fix string puzzles in virt-xml hotplug/hotunplug/update
Do not use the action string (which is an identifer) as replaced
placeholder in messages for device hotplug/hotunplug/update.
Instead, use complete strings for all the actions, and also for all the
usages (confirmation message, success message, error message).

Since the action is the same for all the devices, create the messages
outside the iteration to avoid translating them more than once.

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-09-17 15:38:42 -04:00
Pino Toscano
8fbb985a8c i18n: improve title of connection dialog
Instead of using the title of the dialog and prepending the connection
label, create a new title as a single string. This way it is possible to
translate this title as single sentence.

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-09-17 15:38:42 -04:00
Pino Toscano
519d409718 i18n: fix string puzzle in volume creation dialog
Use a single label to show the single sentence describing the available
space on the storage pool. This avoids the use of 3 different labels,
partially translated separately, and whose content cannot be moved.

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-09-17 14:25:59 -04:00
Cole Robinson
c7ce770170 Prep for release 3.0.0 2020-09-15 17:14:00 -04:00
Cole Robinson
282f9cf91c domain: Switch to non-deprecated thread.is_alive
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-15 16:27:00 -04:00
Cole Robinson
83fcab0177 connectauth: Drop systemd libvirtd service startup
Latest libvirt uses socket activation, so libvirtd.service in
offline state does not indicate a problem necessarily.

Also on Fedora nowadays we have a weak RPM dependency on
libvirt-daemon which we didn't in the past.

Both things combine to make this code less useful and less accurate,
so let's remove most of it.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-15 14:46:36 -04:00
Cole Robinson
54ae6f2723 tests: uitests: Try to fix some clone flakiness
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-15 13:50:58 -04:00
Cole Robinson
9fdbccec2b Fix pylint raise-missing-from
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-15 12:36:27 -04:00
Chen Hanxiao
3238594028 fix some pylint
virtManager/createvm.py:982:8: W0128: Redeclared variable 'ignore' in assignment (redeclared-assigned-name)

tests/uitests/lib/app.py:12:0: C0411: third party import "from gi.repository import Gio" should be placed before "import dogtail.rawinput" (wrong-import-order)

Signed-off-by: Chen Hanxiao <chenhx.fnst@cn.fujitsu.com>
2020-09-15 12:20:18 -04:00
Cole Robinson
a242894182 cli: Add --os-variant require=on|off
If specified, this errors if no OS name was detected or manually set.
So --os-variant detect=on,require=on will error if no OS is detected.

name= can be used as a fallback, so test and document this case

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-14 20:36:12 -04:00
Cole Robinson
17f47a44c5 cli: --os-variant: add explicit suboptions
This adds the following --os-variant suboptions

* name=, short-id=
* id=
* detect=on|off

Functionally this does not change behavior, just adds explicit
sub options for behavior we already support

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-14 20:15:20 -04:00
Cole Robinson
67703ec7a5 cli: Add --osinfo as alternate name for --os-variant
The --os-variant option naming is pretty crappy and mostly a historical
artifact. Ideally this would be named just `--os` but I'm afraid that
would cause confusion with libvirt's <os> XML

Add --osinfo as an alternate commandline naming. If we ever want to
transition documented use of --os-variant it will help to have the
alternative around for a few releases

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-14 18:12:41 -04:00
Cole Robinson
9e8a72537e hoststorage: Fix variable reference in error path
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-14 14:40:47 -04:00
Göran Uddeborg
a8aec2da33 Translated using Weblate (Swedish)
Currently translated at 88.6% (1247 of 1407 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sv/
2020-09-14 11:34:36 -04:00
Cole Robinson
080e84517e tests: test_dist: filter out harmless xgettext warning
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-14 09:57:23 -04:00
Cole Robinson
e513422166 po/ru.po: Fix msgfmt string error
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-14 09:55:36 -04:00
Cole Robinson
b60403d65b po: Fill in Project-Id-Version to not produce msgfmt errors
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-14 09:54:43 -04:00
Weblate
4eee04a3f2 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2020-09-14 09:45:32 -04:00
Göran Uddeborg
9079596467 Translated using Weblate (Swedish)
Currently translated at 87.0% (1225 of 1407 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/sv/
2020-09-14 09:45:32 -04:00
Pino Toscano
beeb83fb2a Translated using Weblate (Italian)
Currently translated at 98.2% (1383 of 1407 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2020-09-14 09:45:32 -04:00
Pavel Borecki
d1d287c93f Translated using Weblate (Czech)
Currently translated at 99.8% (1405 of 1407 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/cs/
2020-09-14 09:45:32 -04:00
Piotr Drąg
68ee0dc4d3 Translated using Weblate (Polish)
Currently translated at 100.0% (1407 of 1407 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pl/
2020-09-14 09:45:32 -04:00
Yuri Chornoivan
604dd59439 Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1407 of 1407 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2020-09-14 09:45:32 -04:00
Weblate
c9c1dcbc6f Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2020-09-14 09:45:32 -04:00
Whired Planck
434ff783d3 Translated using Weblate (Chinese (Simplified))
Currently translated at 100.0% (1405 of 1405 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_CN/
2020-09-14 09:45:32 -04:00
Yuri Chornoivan
e8b01e3a32 Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1405 of 1405 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2020-09-14 09:45:32 -04:00
Fabio Tomat
46029b1021 Translated using Weblate (Friulian)
Currently translated at 34.1% (480 of 1405 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fur/
2020-09-14 09:45:32 -04:00
Pavel Borecki
4b8893927b Translated using Weblate (Czech)
Currently translated at 99.8% (1403 of 1405 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/cs/
2020-09-14 09:45:32 -04:00
Piotr Drąg
e12128ff55 Translated using Weblate (Polish)
Currently translated at 100.0% (1405 of 1405 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pl/
2020-09-14 09:45:32 -04:00
Weblate
e1ac4a5fe0 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2020-09-14 09:45:32 -04:00
Yuri Chornoivan
2c755e8fda Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1405 of 1405 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2020-09-14 09:45:32 -04:00
Pino Toscano
d901ba475e Translated using Weblate (Italian)
Currently translated at 98.2% (1381 of 1405 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2020-09-14 09:45:32 -04:00
Pavel Borecki
f90ef17d46 Translated using Weblate (Czech)
Currently translated at 99.8% (1403 of 1405 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/cs/

Translated using Weblate (Czech)

Currently translated at 99.7% (1402 of 1405 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/cs/
2020-09-14 09:45:32 -04:00
Piotr Drąg
8050ebca64 Translated using Weblate (Polish)
Currently translated at 100.0% (1405 of 1405 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pl/
2020-09-14 09:45:32 -04:00
Weblate
5bcd441f50 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2020-09-14 09:45:32 -04:00
Yuri Chornoivan
c4f7475562 Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1421 of 1421 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2020-09-14 09:45:31 -04:00
Pavel Borecki
7a8a0df03b Translated using Weblate (Czech)
Currently translated at 99.8% (1419 of 1421 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/cs/
2020-09-14 09:45:31 -04:00
Piotr Drąg
0ff6ac598b Translated using Weblate (Polish)
Currently translated at 100.0% (1421 of 1421 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pl/
2020-09-14 09:45:31 -04:00
Whired Planck
50ce30553b Translated using Weblate (Chinese (Traditional))
Currently translated at 100.0% (1424 of 1424 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_TW/
2020-09-14 09:45:31 -04:00
Weblate
28eca74cd6 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2020-09-14 09:45:31 -04:00
Whired Planck
4fb8b31b0c Translated using Weblate (Chinese (Simplified))
Currently translated at 100.0% (1424 of 1424 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_CN/

Translated using Weblate (Chinese (Simplified))

Currently translated at 100.0% (1424 of 1424 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_CN/
2020-09-14 09:45:31 -04:00
Yuri Chornoivan
5a13623fbf Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1424 of 1424 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2020-09-14 09:45:31 -04:00
Pino Toscano
96191e3e25 Translated using Weblate (Italian)
Currently translated at 98.4% (1402 of 1424 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2020-09-14 09:45:31 -04:00
Pavel Borecki
046a8205d4 Translated using Weblate (Czech)
Currently translated at 99.8% (1422 of 1424 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/cs/
2020-09-14 09:45:31 -04:00
Piotr Drąg
2cfcaf0b62 Translated using Weblate (Polish)
Currently translated at 100.0% (1424 of 1424 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pl/
2020-09-14 09:45:31 -04:00
Weblate
bcb4593bfb Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/

Update translation files

Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2020-09-14 09:45:31 -04:00
Whired Planck
bf0f213931 Translated using Weblate (Chinese (Traditional))
Currently translated at 73.3% (1050 of 1431 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_TW/

Translated using Weblate (Chinese (Simplified))

Currently translated at 100.0% (1431 of 1431 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_CN/
2020-09-14 09:45:31 -04:00
Yuri Chornoivan
0f91e307d1 Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1431 of 1431 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2020-09-14 09:45:31 -04:00
Pavel Borecki
db5b8a4844 Translated using Weblate (Czech)
Currently translated at 99.8% (1429 of 1431 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/cs/
2020-09-14 09:45:31 -04:00
Piotr Drąg
a778444423 Translated using Weblate (Polish)
Currently translated at 100.0% (1431 of 1431 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pl/
2020-09-14 09:45:31 -04:00
Weblate
17766f7bc0 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2020-09-14 09:45:31 -04:00
José Lemos Neto
c0e49a9e2f Translated using Weblate (Portuguese (Brazil))
Currently translated at 76.0% (1116 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pt_BR/
2020-09-14 09:45:31 -04:00
Whired Planck
e9d947808c Translated using Weblate (Chinese (Simplified))
Currently translated at 100.0% (1467 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_CN/

Translated using Weblate (Chinese (Simplified))

Currently translated at 92.2% (1353 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_CN/
2020-09-14 09:45:31 -04:00
Weblate
67024a17f5 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2020-09-14 09:45:31 -04:00
Pavel Hrdina
5093cd1383 Translated using Weblate (Chinese (Simplified))
Currently translated at 71.1% (1044 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_CN/
2020-09-14 09:45:31 -04:00
Huacai Chen
e43fdabbe2 Translated using Weblate (Chinese (Simplified))
Currently translated at 71.0% (1042 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/zh_CN/
2020-09-14 09:45:31 -04:00
Oğuz Ersen
f10a271d4c Translated using Weblate (Turkish)
Currently translated at 50.4% (740 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/tr/
2020-09-14 09:45:31 -04:00
b71324419d Translated using Weblate (Russian)
Currently translated at 100.0% (1467 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ru/
2020-09-14 09:45:31 -04:00
Pavel Hrdina
5902e15675 Translated using Weblate (English (United Kingdom))
Currently translated at 76.5% (1123 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/en_GB/
2020-09-14 09:45:31 -04:00
Kukuh Syafaat
90fab15ce7 Translated using Weblate (Indonesian)
Currently translated at 0.6% (9 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/id/
2020-09-14 09:45:31 -04:00
Pavel Borecki
940d2c4647 Translated using Weblate (Czech)
Currently translated at 100.0% (1467 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/cs/
2020-09-14 09:45:31 -04:00
Weblate
ad69c91b2b Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2020-09-14 09:45:31 -04:00
Pino Toscano
d446f6d10d Translated using Weblate (Italian)
Currently translated at 98.4% (1444 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/

Translated using Weblate (Italian)

Currently translated at 98.2% (1441 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2020-09-14 09:45:31 -04:00
Geert Warrink
42641c1af2 Translated using Weblate (Dutch)
Currently translated at 52.2% (766 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/nl/
2020-09-14 09:45:31 -04:00
scootergrisen
bc11082705 Translated using Weblate (Danish)
Currently translated at 15.8% (233 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/da/

Translated using Weblate (Danish)

Currently translated at 15.2% (224 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/da/
2020-09-14 09:45:31 -04:00
Weblate
5a3c2591c9 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/

Update translation files

Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2020-09-14 09:45:31 -04:00
Github Actions
b999fb8425 Refresh translation .pot template 2020-09-14 09:45:31 -04:00
Cole Robinson
244848d29c Fix some pylint
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-13 19:43:50 -04:00
Cole Robinson
d2b5ce53a3 tests: test_dist: Add 'appstream-util validate' check
And fix some issues it reports

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-13 19:43:50 -04:00
Cole Robinson
2197752739 tests: test_dist: drop unnecessary unittest usage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-13 19:43:50 -04:00
Cole Robinson
7ec7b63f02 ui: Mark some uitests strings as non-translatable
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-13 19:12:24 -04:00
Cole Robinson
43392c5ba7 docs: Point to github as our primary issue tracker
We are phasing out use of bugzilla.redhat.com

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-13 18:25:01 -04:00
Cole Robinson
64222783d2 addhardware: Allow settings USB removable setting
We need to update addstorage when the user changes the bus setting

Fixes: #148

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-13 18:12:13 -04:00
Cole Robinson
6657e23a7a details: Revive maxmem and memory hotplug
This was removed in 7547905d79f but I've changed my mind about
dropping it

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-13 17:59:51 -04:00
Cole Robinson
428948a690 cli: Add disk type=nvme source properties
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-13 09:58:39 -04:00
Cole Robinson
ffc48af4ee cli: Add --disk source.file, source.dir, source.dev
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-13 09:58:39 -04:00
Cole Robinson
65a39a7495 man: Convert .pod files to .rst
Used pod2rst for the initial conversion but a lot of manual fixup
afterwards.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-13 09:58:39 -04:00
Cole Robinson
8560138cf2 cli: Add --xml xpath option for virt-install and virt-xml
The --xml option allows users to request raw XML edits to virt-install
or virt-xml generated XML. This gives users a bit of a workaround
incase we don't have proper support for some XML property. The --xml
option can gain more features in the future if it makes sense, like
setting XML namespaces for example.

Basic usage is like: virt-install --xml ./@foo=bar ...

Which will change the generated <domain> XML to have

<domain foo='bar' ...

virt-xml works similarly. It can only be combined with --edit currently.
This only works with xpaths rooted against the entire document.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-11 15:04:37 -04:00
Cole Robinson
aa8572048b uitests: Add a fixture for passing in VMMDogtailApp
Reproducing what the custom unittest TestCase does. Convert
test_about as a demo

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-11 14:25:53 -04:00
Cole Robinson
ebf76563b8 uitests: Big code reorganization
Break utils.py apart into a whole uitests/lib/ directory with

* lib/_dogtailinit.py: all the dogtail library init we need
* lib/_node.py: extending our dogtail node class with more functions
* lib/app.py: VMMDogtailApp
* lib/util.py: util functions plus all the special helpers previously
    in our custom TestCase
* lib/testcase.py: The TestCase that sets and tears down self.app

Adjust callers to match and make it easier to eventually convert to
native pytest usage

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-11 13:55:54 -04:00
Cole Robinson
aa9fcdfdb2 uitests: details: use treeview search to speed up hardware selection
This uncovered some areas in details.py we weren't handling that
the search view unselects the current selection

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-11 12:22:25 -04:00
Cole Robinson
78cd8c90ea console: Rework default page flow a bit
Move the VM status and viewer open checks into the default page
path as well, otherwise opening the details dialog for an offline
VM attempts to connect to the inactive VM console and logs backtraces

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-11 11:34:06 -04:00
Cole Robinson
3ff829dc1f DESIGN.md: Mention existing VM name search support
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-11 11:12:20 -04:00
Cole Robinson
1b48772bc1 virt-install: Don't reboot VM is user manually stopped it
Similar to behavior we have in virt-manager, if the user destroys the
VM during the VM install process, don't invoke the post install
reboot.

https://bugzilla.redhat.com/show_bug.cgi?id=1818089

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-11 09:00:33 -04:00
Cole Robinson
9c5c1f3e44 virt-install: Move more install process handling into separate functions
Try to save us having to pass around a ton of options, and make
things cleaner for upcoming changes

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-11 09:00:33 -04:00
Cole Robinson
0cd7cc7d77 virt-install: Restrict disk cleanup to small failure scenario
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-11 09:00:33 -04:00
Cole Robinson
9ea97e8537 cli: Drop unused 'domain' option from console callback chain
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-11 09:00:33 -04:00
Cole Robinson
ac51ff8684 cli: Fill in all --filesystem suboptions
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-11 09:00:33 -04:00
Cole Robinson
d24b3ba1d1 cli: Add virtio driver packed= option
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-11 09:00:33 -04:00
Cole Robinson
bc246aeaba cli: Add --iommu comment heading
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-11 09:00:33 -04:00
Cole Robinson
65f93e5d60 cli: support --sysinfo type=fwcfg,entry...
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-11 09:00:33 -04:00
Cole Robinson
5643a560d5 domain: Fix details performance page graph scaling
This was busted in a88a28d0

https://bugzilla.redhat.com/show_bug.cgi?id=1823218

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-11 09:00:33 -04:00
Cole Robinson
ac8591192f console: Add option to disable autoconnect
As part of making virt-manager cooperate better with external viewers,
add an option to disable console autoconnect. When opening a VM window
for a running VM, you'll see a 'Connect to console' button in place
of the spice/vnc viewer. Click that and things proceed like normal.

This is useful to prevent virt-manager from disconnecting a virt-viewer
instance that's already attached to a VM

https://bugzilla.redhat.com/show_bug.cgi?id=1793876

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-09 19:59:31 -04:00
Cole Robinson
bbbfd4b7c8 vmwindow: Default the console widget to 1024x768
When a VM window is launched for the first for a VM, currently we
set the top window size to 800x600 which is small and arbitrary and
is universally shrinks the viewer too much to fit any OS installer
I can find.

Instead do some hacks to resize the window to accomodate a viewer
widget of 1024x768 which seems to be what QXL graphics give us for
win10 and Fedora 32 installers. So for new VMs hitting the OS installer
we don't see scrollbars.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-09 19:37:11 -04:00
Cole Robinson
43512302f7 vmwindow: Cleanup the interaction with vmmConsolePages
- Add ui/console.ui for console-pages and below
- Add move auth and graphics unavailable pages to a new subnotebook
- Move all the menubar handling up into vmwindow
- Clarify the control flow as much as I can come up with

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-09 19:37:11 -04:00
Cole Robinson
48bf5c6ab8 uitests: Fix some clonevm flakiness
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-09 19:22:19 -04:00
Cole Robinson
aafb874c85 viewers: Enable window modifiers when viewer doesn't have keyboard
Right now this is tied to widget focus, which is too strong. This
changes it so that say clicking on the window title or toolbar then
allows the user to use Alt+F to trigger the File menu for example.
This roughly matches how virt-viewer works

https://bugzilla.redhat.com/show_bug.cgi?id=1824480

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-09 11:25:50 -04:00
Cole Robinson
33a61f7f30 prefs: Remove 'Force console accels' option
This is very obscure and definitely not in line with our DESIGN.md
nowadays

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-09 09:15:53 -04:00
Cole Robinson
971a3e58f8 uitests: Fix createvm test after tests/data move
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-09 09:11:23 -04:00
Cole Robinson
ec90d1360d createvm: Help make UI tests more reliable
We check if the page moved forward in uitests by scraping the top
label. Make sure we do that last when the page changes

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-09 08:49:12 -04:00
Cole Robinson
b88e755a52 console: Text console submenu improvements
* Move all the menu building to its own class, for clarity
* Rename the menu 'Consoles' since it contains graphical choice as well
* Strip out the VM console duplicate if it exists
* Simplify the code a bit

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-09 08:49:12 -04:00
Cole Robinson
5473695fe1 installer: Upload unattended and cloudinit data to remote connections
* rename kernelupload.py to volumeupload.py and make the entrypoint
  more generic
* move all upload invocation to the Installer class
* use it with cloudinit and unattended ISO generation if required

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-08 19:24:21 -04:00
Cole Robinson
44033b43bb virt-xml: Handle removing <console> <serial> dup device
This is a quirk of libvirt that the first <device> is usually a
logical duplicate of the first <serial> device. Adjust virt-xml to
understand this quirk and remove both devices at the same time,
like we already do in virt-manager

https://bugzilla.redhat.com/show_bug.cgi?id=1685541

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-08 17:55:09 -04:00
Cole Robinson
e2419869e7 tests: data: Move all cli/ bits to their own directories
Move the content to:

* cli/virtclone/
* cli/unattended/
* fakemedia/

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-08 17:48:40 -04:00
Cole Robinson
900ff8c3e1 tests: Move cli virt-xml input XML to a virtxml/ dir
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-08 17:39:38 -04:00
Cole Robinson
38cd19b0c3 domain: Fix VM deletion with firmare='efi'
Our check for nvram was not complete for that case

https://bugzilla.redhat.com/show_bug.cgi?id=1869135

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-08 17:32:00 -04:00
Cole Robinson
1689ebb251 viewers: spice: remove unused audio channel handle
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-08 17:32:00 -04:00
Cole Robinson
7d69783042 virtManager: misc reference leak fixes
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-08 17:32:00 -04:00
Cole Robinson
d073ee9a48 addstorage: Revive disk serial UI
coreos is going to start using disk serial for ignition disk, so
setting this in the UI for distro testing will become more common

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-08 17:32:00 -04:00
Cole Robinson
c54da68535 addstorage: Absorb advanced field UI
Share the UI for changing all these disk properties:

- shareable
- readonly
- removable
- cache
- discard
- detect zeroes

Move them all under the 'Advanced options' expander in details, and
add the checkbox options to the addhardware wizard.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-08 17:32:00 -04:00
Cole Robinson
8d5439567b uitests: finish statsmanager.py coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-05 17:50:57 -04:00
Cole Robinson
5e495ebd46 migrate: Add XML editor support
Allows the user to tweak the XML at the destination, which is already
something that libvirt supports

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-05 17:50:48 -04:00
Cole Robinson
16ebab2230 clone: Rework the UI
* Drop the network editing, users can use the details window
* Drop the combo box approach in favor of a regular treeview
* Drop a lot validation checks which are redundant with modern
  virtinst. We probably lose some checks but I don't think it's
  too important
* Use the cloner API
* Add uitest coverage

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-05 15:49:55 -04:00
Cole Robinson
b9de8ad919 cloner: Fix some corner cases with name generation
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-05 15:49:55 -04:00
Cole Robinson
5c1a1076c0 cloner: Log the generated XML diff, not the whole thing
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-05 15:49:55 -04:00
Cole Robinson
4a47d32b09 xmlutil: add a diff() helper
And centralize all the scattered difflib calls we have

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-05 15:49:55 -04:00
Cole Robinson
7f1f5e343e codespell: Whitelist 'cloneable'
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-05 15:49:55 -04:00
Cole Robinson
8856b781d0 cloner: Write preserve vs share vs clone into DiskInfo
This let's us move more of the preserve logic to virtclone.py
and prep more things to share with virt-manager

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-05 15:49:55 -04:00
Cole Robinson
e6df73261b cloner: Rename clone_disk -> new_disk
The latter is more clear in most contexts, and will make more
sense for future changes

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-05 15:49:55 -04:00
Cole Robinson
9c1453a253 disk: lookup volumes in disk.set_backend_for_existing_path
Seems like it should be doing this.
Make use of that helper in cloner afterwards

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-05 15:49:55 -04:00
Cole Robinson
8f60e4af47 tests: Add our own test:///default driver XML
test:///default saves changes for the lifetime of the connecting
process, which can cause weird interdependent issues in the test
suite. Duplicating it with driver XML will avoid those issues
popping up.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-05 15:49:55 -04:00
Cole Robinson
f06325904b cloner: Share more clone disk building logic
We use this in virt-manager for nvram move on VM rename, so
let's simplify things for all callers

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-05 15:49:55 -04:00
Cole Robinson
f23a27639f cloner: Big API rework
* Centralize lots of disk building
* Open code virt-clone specific behavior at the source
* Drop a lot or properties
* Move most testing to test_cli.py
* Generally a ton of cleanup

virt-manager clone wizard has not been converted yet so is totally
broken after this commit

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-05 15:49:55 -04:00
Cole Robinson
c0d1e76941 tests: Cover more of cloner.py from test_cli.py
Cover more cases via the virt-clone CLI testing, than just the
test_cloner.py unit style testing.

Change most of the virt-clone --print-xml testing to also attempt the
clone operation as well via a hidden cli option, to ensure we aren't
testing XML of any bogus operations

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-05 15:49:55 -04:00
Cole Robinson
f157aa1839 diskbackend: Simplify path a case of path joining
We are reimplementing os.path.join. Make sure the standard cli
test suite hits this case too

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-05 15:49:55 -04:00
Cole Robinson
f46e1a395c tests: cli: Drop most usage of virt-clone --clone-running
This is just a test suite hack from before we had other methods
of specifying cloneable guests. It will be removed soon

We need to tweak some test XML to fix code coverage after

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-05 15:49:55 -04:00
Cole Robinson
39e8d60bea tests: cli: drop some clone --original-xml arg redundancy
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-05 15:49:55 -04:00
Cole Robinson
92b46245bd uitests: finish connection, connectauth
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-05 15:49:55 -04:00
Cole Robinson
cb49648106 uitests: Finish inspection.py coverage
As much as we can. There's not any current way to actually test
the full guestfs implementation, so we exclude it all

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-05 15:04:36 -04:00
Cole Robinson
55fd4ccd23 uitests: Add connection login console lookup testing
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-05 15:04:36 -04:00
Cole Robinson
485dddf2ed uitests: Add connection user/pass auth testing
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-05 15:04:36 -04:00
Cole Robinson
f6e880b195 uitests: Add connection nodedev and agent event testing
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-05 15:03:51 -04:00
Cole Robinson
306c6be12f uitests: Add connection tick failure testing
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-05 15:03:51 -04:00
Cole Robinson
14232e1aa7 connection: Don't process errors in tick_from_engine
We haven't shown error dialogs for failed connections for a long
while, so all this processing isn't accomplishing anything anymore

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-05 15:03:51 -04:00
Cole Robinson
29f866e6f3 uitests: add connection object blacklist testing
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-02 12:59:25 -04:00
Cole Robinson
a10d746c41 gfxdetails: Update UI a bit
Refactor the internals to cleanly separate the pieces that fill in
the UI, and the pieces that react to UI state to dynamically show/hide
fields.

Improve spice GL warnings while he are here, and several other minor
fixes

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-01 20:10:34 -04:00
Cole Robinson
525afd1aa6 DESIGN: More examples of rejected console features
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-01 20:02:21 -04:00
Cole Robinson
bd4b53e7da netlist: Remove some leftover print debugging
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-01 18:04:29 -04:00
Cole Robinson
ba33a6c99d details: Remove explicit video heads and ram reporting
RAM is rarely changed from the default
heads does not have any explicit virt-manager support
and both are viewable from the XML editor.
So remove the explicit fields for them

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-01 17:32:50 -04:00
Cole Robinson
9b5d9eb9eb systray: add a standalone window impl for uitests
This gives us as much coverage as possible without relying on too much
host desktop config

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-01 16:59:20 -04:00
Cole Robinson
4348d4b128 systray: Don't rebuild the menu on every change
This works fine for the StatusIcon backend, but for the appindicator
backend which communicates every menu changes over dbus this is
super slow. Instead update the menu in place when objects change
state or disappear

https://bugzilla.redhat.com/show_bug.cgi?id=1779362

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-01 16:58:04 -04:00
Cole Robinson
408b3023bc viewers: Remove hidden grab-keyboard gsettings
This was added in 2014 per user request but we never exposed it in the
UI. This is fairly advanced needs from the console viewer IMO and is
better left to console specific tools like virt-viewer, per our
DESIGN.md

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-01 14:27:11 -04:00
Cole Robinson
315f492156 uitests: Remove some debugging
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-01 14:27:11 -04:00
Cole Robinson
c40a9e3fed delete: Move show_instance to the proper class
It shouldn't be associated with the shared baseclass

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-01 14:27:11 -04:00
Cole Robinson
e45a2228dc objects: Erase the notion of connkey
Make it explicit that all uses of this is actually the object
name. We already leaked this abstraction in several places so better
to make it explicit. This also communicates to users that this is a
field that is not immutable so it shouldn't be used as a unique key

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-01 14:27:11 -04:00
Cole Robinson
8ff0da7664 connection: Pass object in -added/-removed signals
And not connkey. connkey == name, and name can change with object
rename, so it's a bad pattern to propagate that connkey can be used
as a static lookup key for objects. This begins unwinding it

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-01 14:27:11 -04:00
Cole Robinson
e4c0191f83 createvm: Only check network selection on final page
Otherwise early 'change' signals can give inconsistent
behavior WRT default 'advanced' expander state

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-09-01 14:27:11 -04:00
Cole Robinson
b3fb88e345 cli: Add --cpu numa.cell.memAccess and discard
https://bugzilla.redhat.com/show_bug.cgi?id=1824373

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-31 13:53:26 -04:00
Cole Robinson
7e3fb3f281 graphics: Default to 'vga' instead of 'qxl' for non-spice
qxl doesn't add anything for the VNC case, and qxl is more likely
to be compiled out of qemu since it is dependent on spice, so vga
is the safer default for getting a working config

https://bugzilla.redhat.com/show_bug.cgi?id=1833704

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-31 13:43:56 -04:00
Pino Toscano
7b8ea00361 tests: add Mageia 5 detection test
Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-08-31 13:20:41 -04:00
Pino Toscano
f6c2e75084 urldetect: add version detection for Mageia
Use the VERSION file not only to detect whether the tree is a Mageia
tree, but also to detect the version.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-08-31 13:20:41 -04:00
Pino Toscano
f98daef031 tests: tweak mageia detection
- create a versioned directory for the current VERSION file, fixing the
  typo in the distro name
- move the test to an own function

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-08-31 13:20:41 -04:00
Cole Robinson
1a3a89d949 uitests: finish delete.py coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-30 15:59:39 -04:00
Cole Robinson
30e021bd3d uitests: finish createvm.py coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-30 14:23:24 -04:00
Cole Robinson
5442b6a890 createvm: Fix checking for empty KVM caps
This code path was never hit because it came after caps.guest_lookup
which errors in this case. We need to check things earlier

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-30 14:23:24 -04:00
Cole Robinson
af0162caa2 createvm: Remove the xen PV-only warning
Nowadays this should be rare or possibly not even exist

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-30 14:23:24 -04:00
Cole Robinson
38405a477c tests: Add *DIR helper variables
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-30 14:23:24 -04:00
Cole Robinson
c36f232370 uitests: Finish console.py and viewers.py coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-30 10:34:44 -04:00
Cole Robinson
e414fc3bdc viewers: Drop old style VNC socket handling
In all modern local cases we will be using openFD to get a direct
file descriptor from the VM, so this code should never be triggered
nowadays

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-29 16:49:52 -04:00
Cole Robinson
940bd3873e console: Replace auth-rejected with auth-error signal
Should be similar here. auth-rejected is hard to trigger anyways

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-29 16:17:45 -04:00
Cole Robinson
d5f7089ef2 uitests: finish engine.py coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-29 16:17:45 -04:00
Cole Robinson
b0294a1bc6 testmock: Split apart the first-run option
Break it into disable-libguestfs, fake-systemd-success, and
firstrun-uri suboptions, and adjust using code to match

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-29 15:04:49 -04:00
Cole Robinson
7769d9a1e4 engine: Move the first run systemd handling to connectauth.py
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-29 13:23:34 -04:00
Cole Robinson
64e3ff1d08 uitests: console/keyring/viewer coverage work
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-29 13:23:34 -04:00
Cole Robinson
2c86eefa5b virt-manager: Drop the DISPLAY error handling
Gtk nowadays doesn't raise an exception, it just exits directly

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-29 13:21:43 -04:00
Cole Robinson
c8ed6534e5 connection: Remove some outdated pretty hv labels
And also the embedded label, our default behavior covers
this well enough for what is likely to be an obscure case

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-29 13:21:21 -04:00
Cole Robinson
87eb36dda1 uitests: Finish virtmanager.py coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-29 12:37:52 -04:00
Cole Robinson
687658832e uitests: details/domain/config coverage additions
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-29 12:37:52 -04:00
Cole Robinson
301892f6b9 serialcon: Modernize code style
* Privatize a bunch of stuff
* Make public API explicit
* Add a few minor public APIs to avoid accessing internal state

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-29 12:37:12 -04:00
Cole Robinson
e9c937691d uitests: Finish serialcon.py coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-29 12:37:12 -04:00
Cole Robinson
fa82508e53 virt-manager: drop libvirt 0.6.0 version check
This is comically old and completely unrealistic anyone would
attempt to use that nowadays.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-29 12:37:12 -04:00
Cole Robinson
6006b7b628 tests: Remove some unused testdriver.xml domains
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-28 10:42:29 -04:00
Cole Robinson
a2ad7b4f2f domain: Add test mocking for IP address APIs
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-28 08:47:20 -04:00
Cole Robinson
f06cc11546 config: Move more password handling to keyring.py
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-28 08:47:20 -04:00
Cole Robinson
ab903ef69b domain: Fix clearing topology when VM has dies= in XML
We need to use the topology.clear() helper to properly empty
out everything

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-27 19:41:28 -04:00
Cole Robinson
34c6d1c7ea virtinst: cpu: Move topology elements to their own class
This is a no-op but will help with a future bug fix

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-27 19:41:28 -04:00
Cole Robinson
ade6c34a96 domain: Have test driver report fake job_info data
Helps us test more of the UI

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-27 19:41:28 -04:00
Cole Robinson
b764773cfe domain: Remove qemu VNC SKIPAUTH bug workaround
This was added in cb182f7e3 in Mar 2017 to work around a bug in
qemu 2.9. This bug only affects the case of virt-manager running
locally with that version, which after three years should be rare
to non-existent. Remove the workaround

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-27 19:41:28 -04:00
Cole Robinson
eda08f4c79 details: Big code modernization
* Privatize a lot of stuff
* Separate out many callbacks as thin wrappers around the real code
* Simplify registering EDIT_ handlers
* Organize things better

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-27 18:10:11 -04:00
Cole Robinson
a289676574 uitests: More use of safer utility helpers
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-27 18:10:11 -04:00
Cole Robinson
eea394b9d3 uitests: Increase details + domain + vmwindow coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-27 18:10:11 -04:00
Cole Robinson
701164c664 details: Don't blacklist machine 'none'
Libvirt has done this for us for a long time

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-27 18:10:11 -04:00
Cole Robinson
7d22f7b5dc details: Fix handling failed 'unapplied changes'
The return values from config_apply were not consistent

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-27 18:10:11 -04:00
Cole Robinson
138856c6df uitests: make manager test less flakey
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-27 18:10:11 -04:00
Cole Robinson
4fd9255f9a details: Remove the threads warning for CPUs that don't support it
This is pretty obscure, and if it's problematic then libvirt
or qemu should be throwing an error or otherwise reporting it

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-27 18:10:11 -04:00
Cole Robinson
70a5cb7b55 gfxdetails: Improve UI interaction with spice GL + rendernode
* Unset rendernode when spicegl is de-selected
* Set rendernode by default when spicegl is first selected

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-27 08:35:52 -04:00
Cole Robinson
632f07b2bb uitests: Give more time for graceful app shutdown
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 16:24:40 -04:00
Cole Robinson
69ebf852ca uitests: make onscreen property work for menus
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 16:24:40 -04:00
Cole Robinson
f74c061061 uitests: Finish asyncjob.py coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 16:24:39 -04:00
Cole Robinson
cfd6d6ead4 uitests: Finish vmmenu.py coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 16:24:39 -04:00
Cole Robinson
4c1b35f7e7 uitests: Finish migrate.py coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 16:01:30 -04:00
Cole Robinson
b06d7c47f3 domain: Fake jobinfo support for the test driver
This let's us test more code, including behavior that's closer to
standard QEMU driver behavior

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 16:01:30 -04:00
Cole Robinson
3425d514be migrate: Remove localhost hostname warning
Latest libvirt actually checks against UUID so this isn't accurate
anymore

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 16:01:30 -04:00
Cole Robinson
25d23b1d8b uitests: finish manager.py coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 16:01:30 -04:00
Cole Robinson
e9ee0f6d4b uitests: add some mock inspection.py testing
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:26:12 -04:00
Cole Robinson
0af6bdb56f inspection: Fill in fake data for test:/// URIs
This helps with testing

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:06 -04:00
Cole Robinson
48695199c5 inspection: Break out _perform_inspection
This clearly separates the pieces where we interact with
libguestfs, vs our internal wiring

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:06 -04:00
Cole Robinson
b59a30ad77 uitests: Finish addhardware.py coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:06 -04:00
Cole Robinson
8f76c97705 uitests: Make createpool test less flaky
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:06 -04:00
Cole Robinson
d140596ce9 uitests: try to make flakey createvm test more robust
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:06 -04:00
Cole Robinson
1684049fa3 virtManager: Misc coverage annotations
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:06 -04:00
Cole Robinson
dc41f61e5e uitests: Add combo selection helpers and use them
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:06 -04:00
Cole Robinson
c405dd2741 setup: Add --tb=native to pytest options
I find it much easier to read

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:06 -04:00
Cole Robinson
3f59d9de84 uitests: More usage of storagebrowser helper
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:06 -04:00
Cole Robinson
73b61ffbc9 uitests: Use our loop check() helper for all asserts
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:06 -04:00
Cole Robinson
627fa2f611 addhardware: Simplify input_pretty_name
Drop the 'Generic' prefix for all strings which isn't particularly
meaningful.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
147f918ffd addhardware: Use dictionary pattern for pretty labels
It's shorter and saves us the pain of adding coverage
for every option

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
ab92693a56 uitests: finish preferences.py coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
b1ddc6344a uitests: make test_createvm.py asserts more robust
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
fd5216c184 uitests: Finish createconn.py coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
35d4687237 uitests: Rename test_newvm.py to test_createvm.py
To mirror the code name

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
bb1180fb40 Move virtmanager test cli handling to testmock.py
We will be adding more stuff here, so let's move it out
of the main virt-manager script

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
5ccbcb898f uitests: Finish netlist.py coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
ea49c1d932 netlist: Rework the 'no network' case
Always force a network selection. If we have to fall back to
manual bridge UI because nothing else exists, show a warning.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
0283f26ace uitests: test createvm.py with an inactive default network
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
153dcba126 uitests: test createvm.py with an empty connection
Fix the 'No networking' createvm case that it shows was broken

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
7fef49e99f uitests: Test createvm.py with a fake session URI
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
463c42773c createvm: Drop explicit warning about no net + URL install
This case should be exceedingly rare, and we already show
a visual warning about 'no network'. So let's drop this

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
aab71cc4d0 tests: Move all testdriver XML to the same dir
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
bc32852e17 connection: Remove unused 'vm-renamed' signal
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
f15cdd732d graphics: Remove spice GL/rendernode version support warnings
The versions we are warning about are all over 4 years old, and
these warnings were initially just informative to help users know
when the config wasn't going to work. Drop most of it. Still warn
in the UI when a VM misconfig will prevent spice GL from working

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
c2dbdbfab1 uitests: Finish snapshot.py coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
5ecacfdfed uitests: Finish error.py coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
4b4f2ddba3 uitests: Finish addstorage.py coverage
We need to wire up some craziness to make path permission
searching fail, but this is a critical area to get correct
so it is worth it

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
95bf8bf6b9 uitests: Cover more createvm validation checks
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
e3be4b677e error: Remove some dead code
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
2f4aa652d3 error: Try not to split val_err over multiple lines
Helps grepping for val_err usage, and grepping for error strings

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
be2b308ae4 createvm: Break out _validate_oscontainer_bootstrap
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
d111df4e62 uitests: Finish uiutil.py coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
fea7f3e262 uitests: Finish storagebrowser.py coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
57f916461f uitests: Finish fsdetails.py coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
7bfe8139c0 uitests: Add module_trace.py coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
28f57cbf2f uitests: Finish oslist.py coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
fe323be0ad uitests: Finish mediacombo.py coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
5c10f4e394 storagebrowse: Fix set_browse_reason
We can't call this at init time, we need to do UI changes on demand

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
c323ecfd55 fsdetails: Rework xml builder APIs
Don't have the caller call a validate function, they all catch
errors anyways. Let the build step raise error if there's a problem

Drop some validation checks that libvirt should be performing for us

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
4c439cda21 uitests: Add vsockdetails full coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
bc9d6cf6d5 Drop some explicit openvz handling
I don't think many, if any, people are using virt-manager with
openvz. Drop the specific handling the filesystem UI, users can use
the raw XML editor if they need special behavior

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
7a63fb95ec object: Finish off non-domain code coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
9d34d1da0b libvirtobject: Centralize most tick() implementations
Basically all non-domain objects just need to check to see
if status changed, which will also refresh the XML if
a change occurs. This all works to ensure we are initializing
XML at tick time

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
f22e060190 Always assume objects support .isActive()
All drivers that support the listAll APIs, which we depend on,
also are new enough to support isActive, so stop checking support

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
9a9eb165ed uitests: Add host*.py coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
6f8c305d62 tests: uitests: Add createvol.py coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
0babd6b27f createnet: Add full uitest coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
886339e8dd virtManager: add coverage annotations and remove dead code
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
27d1b4d4bd uitests: Make test_mediachange more resilient
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
7342d9a11b uitests: Add _click_alert_button helper
Centralizes a pattern we were using all over the place

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
8f4341bee8 host: Move xmleditor init earlier
It can be triggered via callbacks which may fire early,
so initialize it first

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
543ddba9f2 hoststorage: Fix some UI issues with initial offline conn
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
d9b3108436 hostnets: Fix some UI issues with initial offline conn
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
760d98ba64 network: Rework dhcp_leases usage to avoid dead code
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
045c8c108d network: Drop dead code in pretty_format_mode
There isn't any XML that hits this case that I can find.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
766d7c47c3 hostnets: Remove route UI label
This is an uncommon configuration. Users can see
the details in the XML editor

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
d0e725f439 gfxdetails: Remove explicit SDL UI fields
Users can look at the device XML easy enough, and very few people
are using SDL with libvirt

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
deeda106c1 createpool: Remove pool-created callback
The intent is this would select the newly created pool in the
UI after the user creates it. With async events though this
is racy and doesn't tend to work as expected.

It's fixable but it would likely require hanging around for
a period of time waiting for the signal to fire, which
takes more work. Just drop it

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
f61bf516df createpool: Remove 'build' checkbox
We only showed it for disk pools, and it determined whether we
partition the device or not. I don't think this gets much
usage and there are much better tools for that job. If users
aren't sure what they are doing they can lose data.

Drop the UI, which always defaults to build=False for disk
pools, and expect the user to partition the device themselves.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
c6830740f3 tests: uitests: Use keyfile to test initial conn loading
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
8dd3b8ba20 virt-manager: Add --test-options gsettings-keyfile
This will let us test some difficult code paths in the uitests.
Rework the `--test-options first-run` behavior to use a temporary
keyfile rather than the memory backend, to unify the code paths

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-26 15:20:05 -04:00
Cole Robinson
a121c943ef tests: Fix failure with newer pytest
This is with latest packages on Fedora 33, I didn't investigate deeper

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-18 14:33:00 -04:00
Pino Toscano
20c2f633d0 osdict: extend non-EOL distros range to 10 years
Commit d52d9885c85623b8d924dbf0aceecb08b33e9122 added a logic to
consider as EOL a distribution with no EOL date set and release date
earlier than 5 years from the current day. This was done because there
were (and still are, even if fewer now) many old OSes in osinfo-db with
no EOL date set, which were thus considered "supported". Sadly, OSes
that are still supported, like Windows 10, Windows Server 2012, or
earlier versions of RHEL/CentOS/OL 6/7, are now considered "EOL".

As a hack on top of the initial hack, extend the range from 5 years to
10 years: this will consider some of the aforementioned OSes as
supported, without adding too many other OSes.

Of course the long term solution is to make sure all the OSes in
osinfo-db that are EOL upstream have a EOL date set, so there is no more
need to arbitrary exclusion logic.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-08-18 13:50:59 -04:00
Cole Robinson
bea401a2cf domcapabilities: Fix backtrace on python3.9
Apparently we can't set etree 'root.attrib = None' anymore

https://bugzilla.redhat.com/show_bug.cgi?id=1869046

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-18 13:49:16 -04:00
Pavel Hrdina
e8bf16b983 details: fix detection of firmware auto-selection
Commit <15a9502b7b7a263c4d66ff2b3f31c209f58fe0b4> fixed firmware
detection but incorrectly. It will always show only "UEFI" even if
the firmware auto-selection is not used because the function is_uefi()
checks both the old style and the new auto-selection.

We have to check only for the auto-selection option.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2020-08-13 16:40:53 +02:00
Jan-Marek Glogowski
ce5aba6a36 Add USB cdrom and ramfb video
Both are needed to install Windows 10 Arm64 from ISO.

Signed-off-by: Jan-Marek Glogowski <glogow@fbihome.de>
2020-08-12 14:03:58 -04:00
Cole Robinson
3e0155b055 osdict: Fix resource checking inheritance
-1 returned from osdict resource lookup means the value is unspecified.
When we encounter that value we should also check the 'all' arch
category, instead of stop processing.

This fixes some vcpus calculation for --os-variant rhel7.0 with
latest osdict

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-08-11 16:50:50 -04:00
Misono Tomohiro
8744e741d1 virtinst: Fix not to return duplicate entries from all_machine_names()
Since machine's canonical alias can be the same as other machine's
name, current all_machine_names() may return duplicates entries.
This causes the problem that the entry of "virt-5.0" appears twice in
machine selection menu when aarch64 is used.

So, fix this by just not adding the same entry twice.

Signed-off-by: Misono Tomohiro <misono.tm@gmail.com>
2020-07-24 20:12:38 +02:00
Misono Tomohiro
d773c4d934 CONTRIBUTING: Fix uitests test name
--uitest does not work as expected.

Signed-off-by: Misono Tomohiro <misono.tm@gmail.com>
2020-07-24 19:23:29 +02:00
Geert Warrink
eeb40b402a Translated using Weblate (Dutch)
Currently translated at 50.6% (743 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/nl/
2020-07-20 13:05:50 -04:00
Weblate
9bfb043b20 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2020-07-20 13:05:50 -04:00
Oğuz Ersen
20a0ffcd89 Translated using Weblate (Turkish)
Currently translated at 50.4% (740 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/tr/
2020-07-20 13:05:50 -04:00
Piotr Drąg
a7201c07a1 Translated using Weblate (Polish)
Currently translated at 100.0% (1467 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pl/
2020-07-20 13:05:50 -04:00
Yuri Chornoivan
7ed69da5ba Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1467 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2020-07-20 13:05:50 -04:00
Pino Toscano
acc1e6049b Translated using Weblate (Italian)
Currently translated at 97.7% (1434 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/

Translated using Weblate (Italian)

Currently translated at 97.7% (1434 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/

Translated using Weblate (Italian)

Currently translated at 97.7% (1434 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2020-07-20 13:05:50 -04:00
Weblate
e2015c0032 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2020-07-20 13:05:50 -04:00
Piotr Drąg
14dc08d62d Translated using Weblate (Polish)
Currently translated at 100.0% (1467 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pl/
2020-07-20 13:05:50 -04:00
Pino Toscano
7a0f7e9f4a Translated using Weblate (Italian)
Currently translated at 97.2% (1427 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/

Translated using Weblate (Italian)

Currently translated at 96.3% (1413 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/

Translated using Weblate (Italian)

Currently translated at 95.5% (1402 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2020-07-20 13:05:50 -04:00
Yuri Chornoivan
61266880fe Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1467 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/

Translated using Weblate (Ukrainian)

Currently translated at 97.6% (1432 of 1467 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2020-07-20 13:05:50 -04:00
Weblate
e985e3abd8 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2020-07-20 13:05:50 -04:00
Pino Toscano
d39be0dd7b Translated using Weblate (Italian)
Currently translated at 94.1% (1370 of 1455 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2020-07-20 13:05:50 -04:00
Yuri Chornoivan
7cf33ad2a8 Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1455 of 1455 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/

Translated using Weblate (Ukrainian)

Currently translated at 93.1% (1355 of 1455 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2020-07-20 13:05:50 -04:00
Weblate
10faefe655 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/

Update translation files

Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
2020-07-20 13:05:50 -04:00
Pino Toscano
b8e260505f Translated using Weblate (Italian)
Currently translated at 95.2% (1349 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2020-07-20 13:05:50 -04:00
Github Actions
1528ce4f7b Refresh translation .pot template 2020-07-20 13:05:50 -04:00
Pino Toscano
c034aece94 bash completion: remove shebang
The bash completion file is not a script to be executed directly, but
it is sourced by bash. Hence, remove its shebang.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-20 12:56:41 -04:00
Pino Toscano
ebaf153e91 about: use the standard license type
Use the standard gpl-2-0 license type of GtkAboutDialog, instead of the
custom license text: this way, the dialog will show a translated text
with the license type, and a link to the full license text.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-20 12:56:41 -04:00
Cole Robinson
cd603672a8 CI: Add ci.yml
Run RPM build and test suite against latest fedora + virt-preview,
output and upload coverage info to codecov

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-18 19:28:04 -04:00
Cole Robinson
a2829e65e9 tests: Don't show debug output by default on failure
Require --log-level=debug to see output

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-18 19:28:04 -04:00
Cole Robinson
fe1747e2fc tests: Add urldetect.py unit test coverage
Add data/urldetect with a bunch of distro tree content to trigger
full code coverage of virtinst/install/urldetect.py

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-18 19:28:04 -04:00
Cole Robinson
93c8e4aab3 urldetect: Drop attempt at sles9 distro detection
I can't find any publicly available media to test this case, I'm
not sure it does anything useful anyways, so just drop it

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-18 19:28:04 -04:00
Cole Robinson
bf1fcdcd12 urldetect: Remove 'content' parsing for opensuse tumbleweed
tumbleweed uses treeinfo now, so this path shouldn't be hit in
the wild anymore

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-18 19:28:04 -04:00
Cole Robinson
25b3113ba9 osdict: Drop post_install driver bits
osinfo library doesn't return data for these with the fedora 32
version, so it's hard to get coverage testing. Since we aren't
even using this code yet anyways, let's remove it until it is needed

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-18 19:28:04 -04:00
Cole Robinson
2170efc9a5 virtinst: Unify test code paths when run as root
CI runs the code as root by default, fix up some of the differences

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-18 19:28:04 -04:00
Cole Robinson
aa89a48371 xmlutil: Centralize all 'programming error' exceptions
Raise them directly instead of adding the hard to read conditional
into the function

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-17 19:08:27 -04:00
Cole Robinson
380a44318a virtinst: Centralize in_testsuite checking
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-17 19:08:27 -04:00
Cole Robinson
44aa0b093e tests: cli: Clean up global module data a bit
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-17 16:47:58 -04:00
Cole Robinson
ef0c36f0b0 tests: Speed up pytest collection a bit
Point it at tests/ and have it exclude search data/ dirs

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-17 16:47:58 -04:00
Cole Robinson
f6c6f033d9 tests: Move checkprops.py magic skipping to pytest
We want to skip these tests if previous tests failed or were skipped,
but current impl depends on unittest specifics. Move it to pytest

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-17 16:47:58 -04:00
Cole Robinson
61a947d667 tests: Rename clistate -> TESTCONFIG
Makes it more clear it's a constant class, and its purpose

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-17 16:38:40 -04:00
Cole Robinson
c01fbcc885 Rename pylintrc -> .pylintrc
Plain pylint calls pick that up as well

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-17 16:00:32 -04:00
Cole Robinson
62e7f1c521 spec: Move virt-manager.spec.in -> virt-manager.spec
Drop the VERSION templating. Tools today like packit and tito
work best when a working .spec file exists. The extra burden is
we need to update the version at release time, but that's no
big deal

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-17 16:00:32 -04:00
Cole Robinson
b9dfd92bf0 setup: Force 'rpm' to output to the git dir
And modernize it to use subprocess and report error output

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-17 16:00:32 -04:00
Cole Robinson
4226a4c1d5 setup: Kill old test_* command infrastructure
pytest invocations are now preferred. Leave plain `./setup.py test`
as a stub that errors and points to pytest.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-17 16:00:32 -04:00
Cole Robinson
ded69ee2ce CONTRIBUTING: Point to new pytest test steps
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-17 16:00:32 -04:00
Cole Robinson
92844eb2f8 tests: Wire pytest --log-level=debug to cli tests debug infrastructure
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-17 16:00:06 -04:00
Cole Robinson
f086c75560 tests: Add pytest --regenerate-output
Duplicate of ./setup.py test --regenerate-output

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-17 14:57:03 -04:00
Cole Robinson
0aa030245c tests: Move setup.py test_urls suboptions to pytest
Adds --urls-skip-libosinfo, --urls-force-libosinfo, --urls-iso-only,
    and --urls-url-only

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-17 14:57:03 -04:00
Cole Robinson
b90820c17d setup.cfg: Disable warnings with pytest
dogtail, gtk are quite noisy

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-17 14:57:03 -04:00
Cole Robinson
e9b3ed509f tests: Add pytest conftest.py
Makes 'pytest' and 'pytest --cov' work for the standard tests.
uitests run with `pytest --uitests --cov=virtManager`.
test_urls.py, test_dist.py, test_inject.py need to be invoked like

pytest $PATH

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-17 14:57:03 -04:00
Cole Robinson
4f15e2d6eb cli: Fake fdopen to work around argcomplete bug with pytest
argcomplete will uncontionally try to take over fd=9 which causes
problems with pytest capturing

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-17 14:57:03 -04:00
Cole Robinson
247170c066 tests: cli: Make test names easier to match with pytest
pytest doesn't like './' in the name

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-17 13:03:54 -04:00
Petr Benes
2862b68292 cli: Add --graphics websocket= support
Add a --graphics websocket option to configure VNC WebSocket port
as described in https://libvirt.org/formatdomain.html#elementsGraphics

Reviewed-by: Cole Robinson <crobinso@redhat.com>
2020-07-16 14:52:03 -04:00
Pino Toscano
8a085bfea1 i18n: translate UI string
A visible UI string must be translatable.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-15 10:22:26 -04:00
Pino Toscano
2760b20c84 i18n: create single strings for texts/messages
Use single strings with proper placeholders for texts, so there is no
need to join together bits of translated texts.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-15 10:22:26 -04:00
Pino Toscano
392caac8b4 i18n: add missing placeholder name in string
Fixes commit 71f034d6b6aad1c8d08b6e95496327299fe797e9.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-15 10:22:26 -04:00
Cole Robinson
49cf5256d7 pylint: Ignore ngettext builtin
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-14 12:06:20 -04:00
Cole Robinson
3a6ec2fe09 CI: Add note that translations.yml runs on default branch
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-14 11:58:41 -04:00
Cole Robinson
b1f6f64e54 CI: Rename ci.yml -> translations.yml
If we add CI it will be in a different workflow

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-14 11:58:41 -04:00
Pino Toscano
971dbaead0 ci: extract messages periodically
Switch the updates of the translation catalog from after every push to
every 2 days at 6am UTC.

Considering that the update-translation-pot will commit the catalog only
if changed, and that there are usually not that many changes upstream,
it is simpler to update the translation catalog only every couple of
days.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-14 11:58:41 -04:00
Pino Toscano
8ec6ccbddb ci: commit the catalog only if changed
Compare the newly generated catalog with the old one: if it actually
changed (i.e. there are changes beside the creation date), then push it
to the 'translations' branch.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-14 11:58:41 -04:00
Pino Toscano
22fe62be34 i18n: fold placeholder into string
There is not really anything to leave out of the string, simply
translate it as a whole.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-14 11:24:14 -04:00
Pino Toscano
494a453ee8 i18n: use single string for error/warning
Avoids few string puzzles.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-14 11:24:14 -04:00
Pino Toscano
6f30ab2437 i18n: use plural forms where needed
Use plural forms for strings that depend on a runtime value, like a
count. This way they will get the proper string for the actual value.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-14 11:24:14 -04:00
Pino Toscano
cd15c72dfb i18n: fix string puzzle in waiting time string
Use two different strings in case there is a timeout and there is none.

Also add a "the" article to make it slightly better.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-14 11:24:14 -04:00
Pino Toscano
6a28de0f22 i18n: globally install also the ngettext function
It will be used to translate strings with plural forms.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-14 11:24:14 -04:00
Pino Toscano
8872e1e962 i18n: show localized accelerators in Send key menu
Turn the menu labels into GTK accelerator strings, so we can parse them
to convert them into a proper user representation.

There is a small behaviour change: the menu items do not have mnemonics
anymore by default.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-14 11:24:14 -04:00
Pino Toscano
353351458a i18n: fix Python format string
Fixes commit fec9f0b13643a3dc8a33c5b23e200ea35ed12dcd.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-14 11:24:14 -04:00
Pino Toscano
36b3f9bee1 i18n: further improve label for controller
It seems that the index is optional, so use a proper string for this
case.

Fixes commit 00fa6366824669aa6ba65f73fdf8eb115dd2d3b7 in this file.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-14 11:24:14 -04:00
Pino Toscano
bceeb23967 i18n: do not translate regexp
There is no point to translate an internal regular expression; worse,
a wrong translation can break the regular expression.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-14 11:23:57 -04:00
Pino Toscano
15a2354559 i18n: use single strings for connection/uri
Create single strings for connection/uri hints & tooltips, so it is
easier to translate them, and there are not glued like puzzles.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-14 11:23:57 -04:00
Pino Toscano
6a39f2bb8b i18n: use single strings for network list in clone dialog
Create single strings for the networks in the clone dialog, including
all the available information at once instead of join pieces together.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-14 11:23:57 -04:00
Pino Toscano
71f034d6b6 i18n: fix string puzzles in error messages
Do not split the error messages and the error details, but rather use a
single string with proper placeholders. This avoids string puzzles.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-14 11:23:57 -04:00
Pino Toscano
ed836c7138 i18n: avoid string puzzle
Create the complete sentence as single message, instead of joining an
existing message with few words more.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-14 11:23:57 -04:00
Pino Toscano
523497085a i18n: fully translate "running console" messages
Create and pass the whole strings to the internal _run_console()
function: this way there is no need to second guess what the
%(console_type) placeholder is, and the types are actually translatable.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-14 11:23:57 -04:00
Pino Toscano
e300dd5da8 i18n: improve labels for disk
Use whole strings for the labels of disks, including the bus (if
available), and the index.

There are still generic fallbacks for the disk types not explicitly
handled.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-14 11:23:57 -04:00
Pino Toscano
9c7df6a7cd i18n: translate "device on address" string
Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-14 11:23:57 -04:00
Cole Robinson
00fa636682 tests: uitests: Fix after string changes
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-13 15:37:00 -04:00
Pino Toscano
7b46ee1947 i18n: improve label for floppy
Shortcut all the checks, and directly return the whole string (index
included) to show for floppies.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-13 15:37:00 -04:00
Pino Toscano
664197bcc7 i18n: improve label for filesystem
Use a single string with a placeholder for the path to avoid a string
puzzle.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-13 15:37:00 -04:00
Pino Toscano
5609a7f083 i18n: improve vmmAddHardware.disk_pretty_bus
Use a static mapping of translated strings, instead of manipulating the
string.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-13 15:37:00 -04:00
Pino Toscano
224bb91afc i18n: improve label for redirector
Use placeholders for the bus name, and the index; the latter is part of
the string, to avoid a string puzzle.
Also use vmmAddHardware.disk_pretty_bus() to get the proper translated
string of a bus.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-13 15:37:00 -04:00
Pino Toscano
90e2bdcb3e i18n: improve translatability of vmmAddHardware.input_pretty_name
A single "Generic" message glued together with capitalized names of bus
and type is a really bad string puzzle:
a) the parts cannot be moved around, while they could depending on the
   language
b) the type cannot be translated, and things like mouse/keyboard/tablet
   are usually translated
c) "generic" as adjective must get the proper gender depending on the
   name it refers to

Hence, unroll 6 more whole strings for the most common combinations of
type and bus. Otherwise, use strings with the type, as it is needed
because of (c) above. At last, fallback to a generic string, still
allowing (a) above. In both cases of fallback, the bus is still properly
translated.

In all the cases, use constants instead of explicit identifier strings.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-13 15:37:00 -04:00
Pino Toscano
cd1f5c3334 Revert "gfxdetails: Don't mark OpenGL as translatable"
While "OpenGL" itself is a proper name, make it translatable so it can
be translated/translitterated in case it needs to be.

Also the whole string includes the colon, so it must be translatable
also to properly localize it.

This reverts commit e7e7eee2871c850f60cecca66c6289f54e5eba7c.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
2020-07-13 15:37:00 -04:00
Pino Toscano
e391489b49 i18n: translate custom URI string in new conn dialog
Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-13 15:37:00 -04:00
Pino Toscano
106d6b5478 i18n: improve items in destination combo
Translate as a whole the UI description of a URI along with the detail
for it, if available. This way there is no string puzzle, and it is
possible to tune the detail string according to the language.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-13 15:37:00 -04:00
Pino Toscano
839b5501cf i18n: translate whole title in migration dialog
Translate the whole string of a title in the migration dialog, including
the markup, so there is no string puzzle.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-13 15:37:00 -04:00
Pino Toscano
deb6462843 i18n: avoid string puzzle in display autoport string
When updating the checkbox aobut the automatic port, set a full string
(without or with the port) instead of "cutting" an existing label.
Not only it avoids to manipulate a UI string, it also allows translators
to properly translate the whole string that includes a port.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-13 15:37:00 -04:00
Pino Toscano
6d970949f1 i18n: use "Generic OS" as label for generic
Change the label for a generic OS to "Generic OS", and making it
translatable.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-13 15:37:00 -04:00
Pino Toscano
7ab7475aff i18n: translate hint text in OS list popover
Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-13 15:37:00 -04:00
Pino Toscano
d58b3fedaa i18n: improve label for controller
Use a proper string with placeholders for the controller name and index,
to avoid string puzzles.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-13 15:37:00 -04:00
Pino Toscano
d5fc02c6ae i18n: improve labels for TPM
Use separate strings for the path case, and for the generic case (i.e.
the version), to avoid string puzzles.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-13 15:37:00 -04:00
Pino Toscano
9d81aae894 i18n: improve labels for RNG
Use a separate string in case it has an associated device to avoid a
string puzzle.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-13 15:37:00 -04:00
Pino Toscano
aa369e7a8d i18n: improve labels for serial/parallel/console
Split the handling of serial, parallel, and console in their own cases,
as the common code is less than the non-common one.

Use separate strings in case the port number is available to avoid
string puzzles.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-13 15:37:00 -04:00
Pino Toscano
864fbfbbcf i18n: translate labels for NICs
Translate the labels for a NIC, both when a MAC address is available and
when it is not.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-13 15:37:00 -04:00
Pino Toscano
42463cde9c i18n: simplify vmmAddHardware.controller_pretty_desc
Shortcut the specific cases, avoiding string puzzles; keep using
vmmAddHardware.controller_pretty_type() otherwise.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-13 15:37:00 -04:00
Pino Toscano
838c8524d2 i18n: translate all controller types
Translate all the types of controllers (e.g. USB, PCI, etc), so they can
be translated/translitterated in case they need to be.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-13 15:37:00 -04:00
Pino Toscano
2927299411 i18n: improve labels for channels
Use separate string in case we have the channel name, and in case we
have the channel type.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-13 15:37:00 -04:00
Pino Toscano
0145d9838b i18n: fix few spellings
"iSCSI", "KVM", "QEMU", "UNIX", "UUID", "VirtIO", "XML", "vCPU".

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-13 15:37:00 -04:00
Cole Robinson
a5cb0bb165 CONTRIBUTING: mention translations branch
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-12 17:15:33 -04:00
Cole Robinson
e2b1e2d59b tests: dist: Add xgettext warning check
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-12 17:08:10 -04:00
Charles Arnold
837bbf2bd3 Fix check for q35 machine type
This fix could be included independent of the other patches.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
2020-07-12 14:10:24 -04:00
Cole Robinson
f2f2822090 ci: Commit extracted messages after rebase
Otherwise rebase fails because state is dirty

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-12 14:04:10 -04:00
Cole Robinson
4ac7a1fac2 ci: Regenerate .pot only after rebasing to 'translations' branch
Otherwise we will get conflicts

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-12 13:47:15 -04:00
Menno Lageman
25419db9ca virtinst: add support for configuring the IOMMU
Add a --iommu option to configure IOMMU parameters as described in
https://libvirt.org/formatdomain.html#elementsIommu

E.g. 'virt-install --iommu model=intel,driver.aw_bits=48,driver.iotlb=on ...'
will generate the following domain XML:

  <devices>
    <iommu model="intel">
      <driver aw_bits="48" iotlb="on"/>
    </iommu>
  </devices>

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Menno Lageman <menno.lageman@oracle.com>
2020-07-12 09:15:52 -04:00
Geert Warrink
4eb7834c6e Translated using Weblate (Dutch)
Currently translated at 53.2% (755 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/nl/
2020-07-12 08:59:34 -04:00
Pino Toscano
6194a18668 Translated using Weblate (Italian)
Currently translated at 93.7% (1328 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2020-07-12 08:59:34 -04:00
Frediano Ziglio
aef693bf2d Translated using Weblate (English (United Kingdom))
Currently translated at 83.6% (1186 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/en_GB/
2020-07-12 08:59:34 -04:00
Pino Toscano
be8713d14d Translated using Weblate (Italian)
Currently translated at 93.5% (1326 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2020-07-12 08:59:34 -04:00
Pino Toscano
2d9e27f5b2 Translated using Weblate (Italian)
Currently translated at 93.3% (1323 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2020-07-12 08:59:34 -04:00
Pino Toscano
cd9315c663 Translated using Weblate (Italian)
Currently translated at 82.2% (1165 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2020-07-12 08:59:34 -04:00
Frediano Ziglio
f6f0e4b377 Translated using Weblate (Italian)
Currently translated at 82.2% (1165 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/it/
2020-07-12 08:59:34 -04:00
Bendegúz Gyönki
88663d58e0 Translated using Weblate (Hungarian)
Currently translated at 61.6% (873 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/hu/
2020-07-12 08:59:34 -04:00
Pavel Borecki
06af541744 Translated using Weblate (Czech)
Currently translated at 100.0% (1417 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/cs/
2020-07-12 08:59:34 -04:00
Julien Humbert
486525970c Translated using Weblate (French)
Currently translated at 92.9% (1317 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/fr/
2020-07-12 08:59:34 -04:00
Seungyeon Choi
ffc8cfd940 Translated using Weblate (Korean)
Currently translated at 77.8% (1103 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/ko/
2020-07-12 08:59:34 -04:00
Yuri Chornoivan
b849fd3dc0 Translated using Weblate (Ukrainian)
Currently translated at 100.0% (1417 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/uk/
2020-07-12 08:59:34 -04:00
Oğuz Ersen
a8d846e347 Translated using Weblate (Turkish)
Currently translated at 50.1% (711 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/tr/
2020-07-12 08:59:34 -04:00
Dankaházi (ifj.) István
65c5fc91ca Translated using Weblate (Hungarian)
Currently translated at 61.6% (873 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/hu/
2020-07-12 08:59:33 -04:00
Piotr Drąg
ba151532f3 Translated using Weblate (Polish)
Currently translated at 100.0% (1417 of 1417 strings)

Translation: virt-manager/virt-manager
Translate-URL: https://translate.fedoraproject.org/projects/virt-manager/virt-manager/pl/
2020-07-12 08:59:33 -04:00
Cole Robinson
76eca73cc7 Update virt-manager.pot
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-12 08:58:10 -04:00
Cole Robinson
6944550218 Add github action to regenerate virt-manager.pot
We store this in a 'translations' branch so the master branch isn't
constantly spammed. I will merge that branch to master before release

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-12 08:57:29 -04:00
Cole Robinson
e7e7eee287 gfxdetails: Don't mark OpenGL as translatable
Fixes: #70

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-12 07:34:59 -04:00
Cole Robinson
35bfdc26a6 setup: Use xgettext --add-comments=translators
So in the code we can prefix comments with 'translators:' before
translated strings to have them show up in .pot file output

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-11 19:18:38 -04:00
Cole Robinson
14f8d2ff7a setup: Tweak extract_messages
* Use long xgettext options
* Truncate .pot file upfront so every call uses --join-existing

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-11 19:18:38 -04:00
Cole Robinson
fec9f0b136 po: Fix message format warnings printed from xgettext
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-11 19:18:38 -04:00
Cole Robinson
7b98850fdf Replace zanata references with Fedora weblate
Fedora has switched to Weblate for translations:
https://fedoraproject.org/wiki/L10N/Translate_on_Weblate

* Remove zanata.xml
* Adjust CONTRIBUTING and appdata links to point to Fedora's weblate

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-11 14:59:56 -04:00
Pino Toscano
9bc25a11d8 po: remove empty translations
They have literally no translated messages nor any other sign that they
had work in the past.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-11 14:59:56 -04:00
Pino Toscano
81ccaae739 spec: drop intltool BuildRequires
It is no more used now.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-11 14:59:56 -04:00
Pino Toscano
331efe3340 Add the translation catalog
Weblate requires it to be present in the repository, so commit it.

This also makes it easier to translate outside of Weblate.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-11 14:59:56 -04:00
Pino Toscano
61b75ba0fb Handle AppStream files using gettext
Starting from version 0.19.6, gettext has native capabilities to extract
from, and merge back translations in AppStream files.

Hence, use xgettext to extract messages, and msgfmt to create AppStream
files with translations; because of this, there no more need to prefix
with underscore the tags to be translated.

Update the gettext required version in INSTALL.md.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-11 14:59:56 -04:00
Pino Toscano
33d8bc9ae2 Handle desktop files using gettext
Starting from version 0.19, gettext has native capabilities to extract
from, and merge back translations in desktop files.

Hence, use xgettext to extract messages, and msgfmt to create a desktop
file with translations; because of this, there no more need to prefix
with underscore the keys to be translated.

Update the gettext required version in INSTALL.md.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-11 14:59:56 -04:00
Pino Toscano
69a1f5dbc1 Add a LINGUAS file
Create a LINGUAS file with all the existing translations. This will be
used by msgfmt to create desktop, and AppStream files with translations.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
2020-07-11 14:59:56 -04:00
Pino Toscano
a1f0e07cd9 setup: use msgmerge for updating translations
Switch from intltool to msgmerge to merge the translations to the
catalog, as it is much easier.

Remove the writing of the temporary POTFILES.in, as it is no more needed
now.

Also, since now gettext is used at installation time:
- mention the gettext requirement in INSTALL.md
- add the gettext BuildRequires in the RPM spec file

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-11 14:59:56 -04:00
Pino Toscano
d306d7ef7c setup: add a extract_messages command
Add a separate command to extract the messages; this also changes the
way messages are extracted:
- keep using intltool for desktop and AppStream files
- use xgettext directly for Python sources, and UI files; this is way
  more flexible than intltool

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-11 14:59:56 -04:00
Pino Toscano
fdc902e461 setup: split listing of .in sources for POTFILES
Extract them from _generate_potfiles_in() to an own
_generate_meta_potfiles_in() function.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-07-11 14:59:56 -04:00
Cole Robinson
a8d2438d5a devices: interface: Rename is_conflict_net -> check_mac_in_use
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-06 10:17:10 -04:00
Cole Robinson
f27e203732 cli: Skip MAC collision error with --check mac_in_use=
There's valid cases where a VM can be defined with a conflicting MAC
address. Prior to  ebd6091cc8e4 and related refactorings we were more
lax here if the conflicting VM wasn't running, but now we are blocking
some valid usage.

Hoist the validation check up to cli.py and add --check mac_in_use=off
to skip the validation. Advertise it like we do for other checks, so
now a collision error will look something like:

The MAC address '22:11:11:11:11:11' is in use by another virtual
machine. (Use --check mac_in_use=off or --check all=off to override)

Reported-by: Pino Toscano <ptoscano@redhat.com>
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-06 10:17:10 -04:00
Cole Robinson
5733d8941c addhardware: Fix invoking netlist validate()
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-06 10:17:10 -04:00
Cole Robinson
183fa0c8df ui: Unmark accessible names as translatable
They are only for the UI tests

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-05 08:25:35 -04:00
Cole Robinson
6a74a6a548 urldetect: Fix SafeConfigParser deprecation warning
It is an alias for ConfigParser in python 3.2+ plus

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-05 08:12:47 -04:00
Cole Robinson
fd9131e203 DESIGN: Add links to more explicitly removed features
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-04 19:06:21 -04:00
Cole Robinson
3ea9a96961 tests: pylint: Silence some false positives
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-04 18:05:27 -04:00
Cole Robinson
4c84d086ec tests: codespell: ignore 'hda'
codespell thinks it is a typo for 'had'

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-07-04 18:05:27 -04:00
Han Han
2310ac4123 docs: Add disk io mode io_uring
Support the io_uring io mode, introduced since Libvirt v6.3.0.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Han Han <hhan@redhat.com>
2020-07-04 18:05:27 -04:00
Han Han
0af0f8fa2f disk: Remove unused constant IO_MODE_THREADS
Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Han Han <hhan@redhat.com>
2020-07-04 18:05:27 -04:00
Daniel Henrique Barboza
ae3e92f0f5 tpm.py: make MODEL_SPAPR the default when running in ppc64
Users are fond of using "--tpm /dev/tpm0" to create a TPM device
for their VMs. ppc64 users, however, are experiencing errors because
the default TPM model is 'tpm-tis', which does not work in ppc64, and
they need to specify 'model=tpm-spapr' to work around that.

This patch makes the default TPM model change to 'tpm-spapr' when
running virt-install on a ppc64 host. A new test was added in test_cli.py
to test this new condition. This also keeps the 100% coverage of
the tpm.py file.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
CC: Satheesh Rajendran <sathnaga@linux.vnet.ibm.com>
CC: Stefan Berger <stefanb@linux.ibm.com>
Signed-off-by: Daniel Henrique Barboza <danielhb413@gmail.com>
2020-07-04 17:56:57 -04:00
Daniel Henrique Barboza
721108002d netlist.py: remove the extra 'None' return in get_network_selection()
Commit v2.2.1-200-g4c3c53f7 ("virtManager: Remove network portgroup
UI") removed 'portgroup', the fourth value of the returned tuple in
get_network_selection(), and all related code that was using this
extra value.

That change forgot to change the line where, if no rows are found, a
tuple with "None" values is returned. The "None" tuple is still
returning 4 "None" values. Since no remaining code is checking for
a fourth value, this is benign and has no impact in the logic.

'pylint' does not seem to care though, and it is complaining about
'unbalanced-tuple-unpacking' because, in the condition mentioned above,
a fourth "None" value is returned and no one is bothering checking for
it.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Daniel Henrique Barboza <danielhb413@gmail.com>
2020-07-04 17:56:57 -04:00
Daniel Henrique Barboza
ec87485852 test_xmlconfig.py: use single quote strings in testDiskNumbers
codespell complains that one of the asserts is a typo:

tests/test_xmlconfig.py:92: ba  ==> by, be

Using single quote strings in that assert will make codespell
pass. For consistency, let's change all the strings in the
test to be single quoted.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Daniel Henrique Barboza <danielhb413@gmail.com>
2020-07-04 17:56:57 -04:00
Daniel Henrique Barboza
21f1c90c2b codespell_dict.txt: add 'msdos' string
This will avoid codespell flagging 'msdos' as a typo.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Daniel Henrique Barboza <danielhb413@gmail.com>
2020-07-04 17:56:57 -04:00
Daniel Henrique Barboza
29963ac986 virtinst/progress.py: change 'fo' to make codespell happy
'codespell' returns errors on this file in the format of:

virtinst/progress.py:527: fo  ==> of, for

This has to do with the 'fo' instance variable of the TextMeter
class. The code was introduced in commit v1.2.1-131-gd5d6cfff,
when parts of the urlgrabber code were copied to avoid dependency
on python-urlgrabber.

Looking at how 'fo' is used, an alternative would be rename it to
'output', so let's make codespell and ourselves happier with less
lint errors.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Daniel Henrique Barboza <danielhb413@gmail.com>
2020-07-04 17:56:57 -04:00
Daniel Henrique Barboza
bdb2bed3e9 virtinst: trivial codespell fixes
Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Daniel Henrique Barboza <danielhb413@gmail.com>
2020-07-04 17:56:57 -04:00
Daniel Henrique Barboza
97eda595d3 virtManager/clone.py: codespell fix
Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Daniel Henrique Barboza <danielhb413@gmail.com>
2020-07-04 17:56:57 -04:00
Cole Robinson
371bcb547a spec: Switch to latest Fedora bytecompile macros
https://docs.fedoraproject.org/en-US/packaging-guidelines/Python_Appendix/#manual-bytecompilation

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-05-27 15:06:53 -04:00
Hugo Gualandi
3941b7f723 Fix Send Key translation in pt_BR
Enviar Chave -> Enviar Tecla
2020-05-27 15:03:18 -04:00
Cole Robinson
7d6b5d86cd po: Add fur.po and id.po from zanata
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-05-27 15:02:40 -04:00
SlurmMcKenzie
3cd64ca0ea po: de: Fix translation
Reviewed-by: Cole Robinson <crobinso@redhat.com>
2020-05-27 15:02:28 -04:00
Cole Robinson
b9f4e6e5fa po: Update from zanata
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-05-27 14:56:21 -04:00
Cole Robinson
b4181e7d77 tests: test_urls: Update
* latest SL is detected as centos again
* ubuntu URLs have moved, bump them forward

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-05-27 14:42:37 -04:00
Fabiano Fidêncio
b55b7e9462 urldetect: Deal with ubuntu 20.04 legacy installer
Ubuntu 20.04 has a new installer, which is yet not supported by
virt-install / osinfo-db, and this made ubuntu switch their URLs
for the old installer to current/legacy-images/... instead of
current/images/...

Let's adapt URL detect so it can deal with this new "legacy"
style.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2020-05-27 14:42:37 -04:00
Tony James
4cdf2dc37d Fix typo in virt-install man page 2020-05-27 14:26:48 -04:00
Han Han
f34f73622d rng: add builtin rng backend model
The builtin rng backend uses getrandom syscall to generate random, no
external rng source needed, introduced from libvirt v6.1.0.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Han Han <hhan@redhat.com>
2020-04-21 13:05:42 -04:00
Cole Robinson
f6eee380a2 preferences: Fix dialog when invalid keygrab is set
https://bugzilla.redhat.com/show_bug.cgi?id=1810106

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-04-13 12:44:47 -04:00
Cole Robinson
e79b550419 Fix pylint with latest pylint version
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-03-30 16:04:12 -04:00
Stefan Berger
cd1713c6f2 tpm: add SPAPR (ppc64) device model
Add support for the tpm-spapr device model for pSeries VMs.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Stefan Berger <stefanb@linux.ibm.com>
2020-03-30 15:59:37 -04:00
Cole Robinson
1afdc7ae32 createvm: Rework to track all Guest/Installer params explicitly
Rather than build a guest and installer instance depending on where
we are in the UI, track each input property in an explicit class, so
we can rebuild the guest/installer on demand with data accumulated
up to that point.

This makes the flow easier to follow and simplifies a lot of hacks we
have to do when backing up through the wizard, because we are trying
to unwind changes from an existing object, rather than just blowing
it away and easily reassembling it with updated info.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-02-05 19:39:45 -05:00
Cole Robinson
eb605cccd8 tests: uitests: More createvm testing
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-02-05 19:39:45 -05:00
Cole Robinson
01eb65bd61 tests: Don't report UID/GID in fake caps data
Otherwise uitests can have different behavior depending on host state

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-02-05 19:39:45 -05:00
Cole Robinson
150b6ac95e virt-install: Add --reinstall=DOMAIN option
This allows using virt-install's install logic on an existing VM

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-02-03 09:03:02 -05:00
Cole Robinson
9385e8689b cli: Move some domain helpers from virt-xml to cli
We will need these elsewhere for upcoming patches

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-02-03 08:41:46 -05:00
Cole Robinson
8732b2d52b virtinst: installer: Add _make_cdrom_device helper
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-02-03 08:41:46 -05:00
Cole Robinson
5c64d35756 tests: uitests: Add a NewVM failure test
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-02-03 07:05:11 -05:00
Cole Robinson
b24892448c tests: Add armv7l domcaps data, and use it
Rather than using a hacked x86 domcaps data

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-02-03 07:05:11 -05:00
Cole Robinson
c0c69b1708 tests: uitests: Make NewVMManual more robust
There's a timing issue with changing pages

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-02-03 07:05:11 -05:00
Cole Robinson
bea5e56c26 virtinst: connection: Add is_privileged
Replace the is_session and is_system distinction with variants
of is_privileged. This matches what libvirt uses internally, and
will help with supporting qemu:///embed at some point

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-02-03 07:05:11 -05:00
Cole Robinson
9a0d49a718 virtinst: uri: Rework MagicURI to work with passed in fakeuri
Rather than individual options for each possible hypervisor,
and annotations like 'remote' or 'session', just have it take a
fake URI to mock

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-02-03 07:05:11 -05:00
Cole Robinson
1b6e33e8b9 tests: osdict: Finish coverage
Requires libosinfo git which has a bug fix to help trigger
post install code in osdict.py

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-02-03 07:05:11 -05:00
Cole Robinson
f380d43e58 cli: Print more info about console commands
Googling for 'Graphics requested but DISPLAY is not set' shows there's
some confusion about virt-install's behavior in this area. This gives
more output in several related cases about what commands we are
running and the state of the VM

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-02-03 07:05:11 -05:00
Cole Robinson
226c25b07d CONTRIBUTING: Add note that test coverage shouldn't regress
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-02-03 07:05:11 -05:00
Cole Robinson
67ef81895e virtManager: Convert to CSS for most color usage
* Add CSS data in config.py and install it
* Strip out all hardcoded colors and use style class annotations
* Fix colors to be more theme appropriate to fix dark theme look

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-02-03 07:05:11 -05:00
Cole Robinson
1ad470c021 inspection: Some cleanups
* Simplify the queue data, just push in VM data to refresh
* Do less work in threads
* Slight rework of updating inspection data in the VM

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-02-01 22:02:59 -05:00
Cole Robinson
53aba9204d connection: Fix stats polling
Commit 419f8cd31b1 messed up the dopoll rework, which meant we
never called stats polling on the master object list. Fix it, but
do so by unwinding the redundant internal _update routines

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-02-01 21:28:07 -05:00
Cole Robinson
489ef8fb7c DESIGN: Reference that SPICE multihead was explicitly rejected
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-30 16:19:23 -05:00
Cole Robinson
9ddf2799a8 tests: More work to make dir search test host independent
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-30 16:18:20 -05:00
Cole Robinson
8e7745f5e1 tests: Don't check against host UID
We are using static test suite data to compare against resolved
host username

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-30 10:15:21 -05:00
Cole Robinson
82be5dccad cli: Add --disk type= support
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-29 19:17:54 -05:00
Cole Robinson
8c0704a921 diskbackend: Treat /dev paths on remote connections as 'block'
Currently if the path isn't managed on a remote connection we
treat it as file. Add this simple heuristic to improve the common
case.

https://bugzilla.redhat.com/show_bug.cgi?id=1726202

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-29 19:07:27 -05:00
Cole Robinson
5573aeb441 createnet: Fix XML editor error when dhcp fields are empty
We need to handle the case when ip == None

https://bugzilla.redhat.com/show_bug.cgi?id=1726586

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-29 18:53:31 -05:00
Cole Robinson
635073eef5 createnet: Drop row coloring validation
Because we are a single screen now, just let libvirt perform
the validation for us

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-29 18:53:31 -05:00
Cole Robinson
d15eafc9d6 ui: manager: Don't allow de-selecting rows
We should always have something selected, there's not really any
point to allow de-selecting a row that I can think of, and it brings
up some weird menu UI.

https://bugzilla.redhat.com/show_bug.cgi?id=1679577

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-29 18:34:38 -05:00
Cole Robinson
140a1f3b15 cloner: Drop ability to clone a paused VM
Generally this doesn't work with qemu metadata locking nowadays,
and it was never a safe idea to begin with, because disk contents
could be in an inconsistent state.

https://bugzilla.redhat.com/show_bug.cgi?id=1725330

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-29 18:34:38 -05:00
Cole Robinson
1e1cd4c564 cloner: Clear domain <title> as well
Otherwise in virt-manager the two VMs will be identical

https://bugzilla.redhat.com/show_bug.cgi?id=1687334

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-29 18:34:38 -05:00
Cole Robinson
3859725739 createvm: Fix showing 'Import' disk UI
We were triggering the wrong install page number, after adding
the Manual Install option

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-29 18:34:38 -05:00
Cole Robinson
b671c7cf41 libvirtobject: Always define even if XML isn't different
This should be a rare occurence, and it ensures that the UI reflects
the latest XML

https://bugzilla.redhat.com/show_bug.cgi?id=1356407

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-29 18:34:28 -05:00
Cole Robinson
7313f9ff6a diskbackend: Add full local clone test coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-29 09:09:40 -05:00
Cole Robinson
e7bb021c4c diskbackend: Add lots of test coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-29 08:38:18 -05:00
Cole Robinson
04c0d48ef7 devices: disk: Always set a stub storage backend
This reworks the existing code to never have storage_backend = None,
instead carrying around a stub class, and resolving the actual
storage info when necessary. This makes the logic easier to follow.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-29 06:52:29 -05:00
Cole Robinson
d46b89ec09 devices: disk: Remove dead code in get_target_prefix
The goal of this was to handle the case of a new libvirt bus that
we didn't know the prefix for. I suspect all new buses will in practice
use the 'sd' prefix, so this will never trigger

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-29 06:52:29 -05:00
Cole Robinson
519fed3b91 addhardware: Remove dead virtio-scsi collision code
The way we set controller_model earlier, means all the virtio-scsi
allocation code is essentially never set. That code does still fix
a valid case of when trying to add a scsi device when there isn't
any remaining slots open, but that should be rare enough that I'm
fine telling the user to edit manually set up a controller themselves
first.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-29 06:52:29 -05:00
Cole Robinson
e1bcd42aa0 guest: Move bootorder helpers out of the osinfo code area
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-29 06:44:41 -05:00
Cole Robinson
ac202f40ac tests: uitests: Fix live hotplug test after delete rework
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-29 06:44:41 -05:00
Cole Robinson
bd4b841b10 addhardware: Remove IO and scsi reservation options
These were removed from the Details dialog previously, but I forgot
to remove them from addhardware too

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-29 06:44:41 -05:00
Cole Robinson
4cb775773f devices: disk: Add change_bus()
Taken from virt-manager code. Move it here because it is strictly
an XML operation, and it will be easier to unit test

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-29 06:44:33 -05:00
Cole Robinson
0f295ec5dc devices: disk: Add more test coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-29 06:40:43 -05:00
Cole Robinson
5d643f8fd9 devices: disk: Drop dead code
The way the previous block is structured, this condition will
never trigger

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-28 20:03:50 -05:00
Cole Robinson
01ccaf03be setup: Run codespell on more files
And fix the results

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-28 14:31:28 -05:00
Cole Robinson
c3b4a713c1 DESIGN: Add more links to explicitly rejected requests
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-28 14:23:23 -05:00
Cole Robinson
d9d5caad0d virtinst: connection: Drop is_closed() helper
We have is_open, just use that

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-28 11:42:33 -05:00
Cole Robinson
4f7e25e9fe uitests: Fix with latest delete wizard
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-28 11:39:14 -05:00
Cole Robinson
0e355b218a delete: Improve text for storage deletion
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-28 11:39:14 -05:00
Cole Robinson
e48ce4a31e delete: Default to not removing storage for disk removal
This is the old default we've always used, so better to stick with it

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-28 11:39:14 -05:00
Cole Robinson
03a6272f81 delete: Code cleanups
* Comment the individual classes
* Move abstract methods to their own logical section
* Simplify some shared code calls

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-28 11:39:14 -05:00
Cole Robinson
1a9e2f4f76 delete: Don't run UI routines from a thread
Pull the remove_devobj_internal call outside of the async job,
otherwise we can have X11 threading issues

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-28 11:39:14 -05:00
Lily Nie
3ab35320a1 Use remove_devobj_internal function instead of vm.remove_device
remove_devobj_internal function handles more things than vm.remove_device.
We should call it first before performing the storage deletion.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
2020-01-28 11:39:14 -05:00
Lily Nie
1e36ce05e3 Change remove_devobj_internal to a static method,and move it to vmmDeleteStorage
So that the callback doesn't need to be passed into the init function,
and vmmDetails can call that function directly

Reviewed-by: Cole Robinson <crobinso@redhat.com>
2020-01-28 11:39:14 -05:00
Lily Nie
af59cd9825 details: remove all usage of 'self' in remove_devobj_internal function
Reviewed-by: Cole Robinson <crobinso@redhat.com>
2020-01-28 11:39:14 -05:00
Lily Nie
71befc0f5d details: add a remove_devobj_internal function
Reviewed-by: Cole Robinson <crobinso@redhat.com>
2020-01-28 11:39:14 -05:00
Cole Robinson
11d6536542 guest: Finish off test coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-27 13:08:12 -05:00
Cole Robinson
dbcebeb734 guest: Move VM replace helper to cloner
It's the only user. Rework it a bit and add full coverage

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-27 13:08:12 -05:00
Cole Robinson
796ba8f3c5 guest: Fix --graphics spice usage if USB is disabled
We already have a check for this for adding a tablet device, do
the same for redirdev devices

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-27 13:08:12 -05:00
Cole Robinson
860dba6923 guest: Remove disable_default_memballoon
The Guest code isn't triggerable because of the way the cli code
was invoking it, as a <memballoon> device would always be added.
Because libvirt accepts model=none, and that's what '--memballoon none'
will translate to anyways, we don't need any special handling here

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-27 13:08:12 -05:00
Cole Robinson
fd71d7fea5 guest: Remove bogus conditional
This incorrectly always evaluates to True. But no one ever complained
so let's keep that behavior the same

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-27 13:08:12 -05:00
Cole Robinson
6d2483f09d virtinst: install: Fill out more test coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-27 13:08:12 -05:00
Cole Robinson
3440d8c59d urlfetcher: move mock code to the testsuite
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-27 13:08:12 -05:00
Cole Robinson
c64009ecdd domaincapabilities: Finish test coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-27 13:08:12 -05:00
Cole Robinson
dcab14e0b4 domain: cpu: Finish test coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-27 13:08:12 -05:00
Cole Robinson
6f95ebc7fd devices: controller: Add get_attached_devices
Move the opencoded impl out of virt-manager details.py and into
virtinst, since this is entirely about XML comparison. Add tests for
it

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-27 13:08:12 -05:00
Cole Robinson
ec580f82a2 tests: Cover Guest.find_device and Device.compare_device
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-27 07:38:53 -05:00
Cole Robinson
3e5d530fce devices: interface: add coverage for new bridge changes
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-27 07:00:29 -05:00
Cole Robinson
e40f71a689 tests: cli: Cover DeviceVideo bochs default
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-27 06:57:52 -05:00
Cole Robinson
91d4c39bb6 tests: cli: cover --controller address=X failure
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-27 06:57:37 -05:00
Cole Robinson
eb5e087366 tests: Add full coverage for pollhelpers and VirtinstConnection
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-27 06:57:37 -05:00
Cole Robinson
cf76c1517c connection: Simplify keepAlive error checking
This checking is overly involved, keepAlive is not an essential
feature, so just log an error if it fails

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-27 06:57:37 -05:00
Cole Robinson
f023b9f8c9 connection: Drop dead __getattr__ code
__getattr__ is only called when an attr is not already found
in __dict__, so this path will never trigger

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-27 06:57:37 -05:00
Cole Robinson
7ccba87966 connection: Share helper function for fetch APIs
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-27 06:57:37 -05:00
Cole Robinson
156926b78d connection: Drop glib usage for cache dir
Our fallback implementation is the same as glib for all usage we
care about, so don't bother with calling glib

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-27 06:57:37 -05:00
Cole Robinson
49d16912c3 setup: Skip coverage report when tests are aborted or skipped
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-27 06:57:37 -05:00
Cole Robinson
e784376699 tests: Rename all test files to have test_ prefix
This will help for a possible future conversion to pytest

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-27 06:57:37 -05:00
Cole Robinson
78c8aef75e tests: Move all data directories to data/
This cleans up the file hierarchy a bit

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-27 06:57:37 -05:00
Cole Robinson
8fe0a208db Move virt-* code into their modules
This layout is closer to what most python modules have nowadays.
It also simplifies testing and static analysis setup.

Keep virt-* wrappers locally, for ease of running these commands
from a git checkout.

Adjust the wrapper binaries we install on via packaging to be
pure python, which makes things like running gdb easier.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 18:27:20 -05:00
Cole Robinson
3538a8df79 details: Fix perf icon with adwaita-icon-theme
We need to fallback to a more generic value if the
preferred icon is not around

https://bugzilla.redhat.com/show_bug.cgi?id=1756236

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 15:41:21 -05:00
Cole Robinson
d0d672e6d5 virt-install: Change PXE warning to be less authoritative
https://bugzilla.redhat.com/show_bug.cgi?id=1693891

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 14:26:19 -05:00
Cole Robinson
b5e3b724cf Add DESIGN.md
This is derived from the mailing list discussion here:
https://www.redhat.com/archives/virt-tools-list/2019-June/msg00108.html

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 12:14:18 -05:00
Cole Robinson
1002128c7b oslist: Only handle 'activate' if the oslist is visible
Otherwise when we press enter for an already selected OS, it chooses
the first alphabetic entry in the list, overwriting our selection

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 11:39:34 -05:00
Cole Robinson
c6e85295e8 createvm: Grab OS list focus for manual install page
Since the page requires input and can't progress until the user enters
some value here, grab focus for the OS list

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 11:39:34 -05:00
Cole Robinson
ba24d877bf createvm: Remove 'Network boot (PXE)', add 'Manual install'
For the dialog flow, these options are the same, the only effect
is that there's no longer an initial network boot phase.

PXE is dependent on an external server setup that is not common
in the scheme of things, so giving it a first class option on the
front of the new VM wizard isn't really sensible. Users that want
to PXE boot can easily do so via the 'customize before install'
option, or just manually create a VM and edit the boot device as
they see fit.

Explicitly advertising a Manual option is nicer for users that
just want to create a VM and deal with install later, among many
other minor use cases.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 11:39:34 -05:00
Cole Robinson
18358d5096 tests: uitests: Make find() exception output nicer
Overwrite the internal exception, which is not interesting

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 11:39:34 -05:00
Cole Robinson
f073ad6fb6 createvm: Remove kernel/initrd/dtb/kernel args UI
Add an info message that these can be set via the
'Customize before install' option. Duplicating this doesn't add a ton
of value here IMO

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 11:39:34 -05:00
Cole Robinson
0bf65e6ce8 preferences: Remove old Interface confirm option
This hasn't been relevant since that UI was removed

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 11:39:34 -05:00
Cole Robinson
d410773af8 virtManager: Remove virInterface polling
There are no more users of interface objects in the code. Remove
all the polling support, and all the remaining references to
interface objects throughout the code base

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 11:39:34 -05:00
Cole Robinson
212c5f813d createnet: Add field for specifying forward device
And drop the explicit forward device listing. Similar to what
we did with bridge/macvtap domain <interface>

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 11:39:34 -05:00
Cole Robinson
c92c454fde virtManager: Drop interface list for bridge and macvtap
Some related bits were discussed here:
https://www.redhat.com/archives/virt-tools-list/2019-June/msg00117.html

macvtap is problematic for inexperienced users so we shouldn't
be broadly advertising it, plus our device listing was incomplete
anyways.

Both bridge and macvtap device listing are largely dependent on
the libvirt virInterface APIs, which have varying degrees of
completeness across distros and are not particularly reliable to
begin with.

Drop both of these in favor of the available support for manually
specifying a device name

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 11:39:34 -05:00
Cole Robinson
8ed9eef905 netlist: Use same default policy as virt-install
virt-manager's logic is hard to follow, and gives weird results
by just choosing the first bridge device it finds more or less.

Use virt-install's logic: bridge if it is the default route,
otherwise network 'default' if it exists

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 11:39:34 -05:00
Cole Robinson
869eb2dc8f devices: interface: Cache default bridge lookup for process lifetime
Saves us possibly hammering the logs if this goes wrong. We are
about to start using it more in virt-manager

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 11:39:34 -05:00
Cole Robinson
9a72df3128 devices: interface: Rework default_source functions slightly
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 11:39:34 -05:00
Cole Robinson
66e1eb7324 netlist: Add 'Macvtap device...' manual entry
Similar to the bridge option. We will be removing the explicit
device listing support soon, so this will be required for specifying
a macvtap device

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 11:39:34 -05:00
Cole Robinson
00da972b14 netlist: Rename 'Specify shared device' to 'Bridge device...'
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 11:39:34 -05:00
Cole Robinson
227d6982ae virtManager: Drop macvtap 'source mode' UI
Some related bits were discussed here:
https://www.redhat.com/archives/virt-tools-list/2019-June/msg00117.html

"""
  * macvtap is kinda problematic in general because it doesn't provide
    out of the box host<->guest communication, and it requires a
    special XML option just to get working ipv6. Users that know they
    want it usually know this distinction, but if someone chooses it
    without understanding the implications it can cause confusion.
    This puts it hovering the intermediate/advanced user line which
    makes me want to not advertise it as prominently as we currently do,
    with an explicit list of host interfaces
"""

Part of this is that the only source_mode that will work in a useful
way for the vast majority of users is mode=bridge. Any of the other
modes either require special hardware, permissions, or other
configuration. Default to bridge mode. The XML editor is there for
anyone that knows they need something different

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 11:39:34 -05:00
Cole Robinson
4c3c53f773 virtManager: Remove network portgroup UI
portgroups are a way to group logical chunks of settings inside
a <network> object. They are a quite advanced feature that I expect
many few users are using, and the ones that are using it are certainly
advanced enough to edit the XML directly.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 11:39:34 -05:00
Cole Robinson
8263d5c705 netlist: Reorganize row building a bit
This should be a no-op.

* Remove unused is_active field
* Access row indexes with named fields
* Move the row building outside the main class, to make it clear
    these are just helper methods

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 11:39:34 -05:00
Cole Robinson
a18117ae30 createvm: Remove the PXE install network warning
This is pretty obscure, and PXE installs will likely be reworked
in the near future. Drop it

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 11:39:34 -05:00
Cole Robinson
4fce7dde9a virtManager: Remove LXC idmap UI
This is pretty obscure, and requires a large amount of UI surface
to handle correctly. Users can use the XML editor if they know they
need or want this.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 11:39:32 -05:00
Cole Robinson
137b73df75 virtManager: Only allow editing disk bus for new VM
This was proposed here:
https://www.redhat.com/archives/virt-tools-list/2019-June/msg00117.html

"""
* disk: bus editing: maybe keep this for the customize wizard, but
it should go away for existing disks, changing it for an existing VM is
definitely a 'shoot yourself in the foot' type of thing for most users
"""

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 11:39:18 -05:00
Cole Robinson
7547905d79 virtManager: Remove max memory UI and memory hotplug support
This was proposed here:
https://www.redhat.com/archives/virt-tools-list/2019-June/msg00117.html

"""
* UI maxmem and maxcpu notions, and related memballoon and cpu hotplug
operations. These have been in the UI forever but I'm not sure people
actually use them. cpu hotplug has always been a mess, and unless the
user plans ahead by setting a high maxmem value ballooning is only good
for reducing memory. These all sound like advanced usage to me that
just confuses the typical usecase of adding more mem or vcpus to an
offline VM. And the hotplug operations with virsh are simple to invoke.
So I'd like to drop this from the UI
"""

The remaining field sets both max and current memory in the
inactive XML

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 11:24:22 -05:00
Cole Robinson
0335c9ce62 virtManager: Remove maximum VCPUS API and VCPU hotplug
This was proposed here:
https://www.redhat.com/archives/virt-tools-list/2019-June/msg00117.html

"""
* UI maxmem and maxcpu notions, and related memballoon and cpu hotplug
operations. These have been in the UI forever but I'm not sure people
actually use them. cpu hotplug has always been a mess, and unless the
user plans ahead by setting a high maxmem value ballooning is only good
for reducing memory. These all sound like advanced usage to me that
just confuses the typical usecase of adding more mem or vcpus to an
offline VM. And the hotplug operations with virsh are simple to invoke.
So I'd like to drop this from the UI
"""

The remaining UI field now sets both maximum and current VCPU
allocation.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 11:24:20 -05:00
Cole Robinson
b4b497e28f virtManager: Remove network virtualport UI
This was proposed here:
https://www.redhat.com/archives/virt-tools-list/2019-June/msg00117.html

"""
* network virtualport configuration: this is some really obscure
stuff for configuring VEPA for macvtap devices. I don't think it gets
any usage in practice. I think a smaller subset of this UI is shared
with openswitch config but I believe it's just a single field, we
could keep that even though I don't think many people use it either
"""

This removes it all. The openvswitch piece was not properly wired
up anyways, since it requires setting virtualport type for a bridge.
For users that know they need that, they can add it via the XML
editor.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 11:22:18 -05:00
Cole Robinson
3c861131dd virtManager: error: Break long lines in error dialogs
Errors from libvirt can be super long, and stretch out the dialog like
crazy.

This causes some changes in test suite output, so adjust tests to
match

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-26 11:21:59 -05:00
Cole Robinson
a162a3b845 virtManager: Remove disk driver_io UI
This was proposed here:
https://www.redhat.com/archives/virt-tools-list/2019-June/msg00117.html

The default driver_io value we use seems to be sufficient. It's very
rare to hear that users need to change the value to something
different, and if they do, they are advanced enough users that can
edit the XML directly IMO.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-25 14:30:07 -05:00
Cole Robinson
6924e16aaf cli: Clarify that --controller address= is not the preferred pattern
Remove it from the man page, and add a local comment to the code

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-25 14:30:07 -05:00
Cole Robinson
b3ea89f218 virtinst: device: Remove set_addrstr()
There's only one user now, in cli.py. Open code it there

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-25 14:30:07 -05:00
Cole Robinson
2367e70efa virtManager: Remove magic spapr-* device handling
We have lots of spapr-* pretty printing and some magic handling
spread around the codebase. These devices have fallen out of favor
and are rarely used, so drop the special handling

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-25 14:30:07 -05:00
Cole Robinson
b583ea7e66 virtManager: Remove disk SCSI reservations UI
This is another advanced feature with a limited appeal. Users that
know they need this can set it directly with the XML editor

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-25 14:30:07 -05:00
Cole Robinson
d9c0384607 virtManager: Remove disk SGIO UI
This is a very advanced field that is only shown for a quite
advanced disk device='lun' config. Users that know they need this
can easily set the value via the XML editor

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-25 14:30:07 -05:00
Cole Robinson
79fe886ac8 virtManager: Remove disk format/driver_type UI
This was proposed here:
https://www.redhat.com/archives/virt-tools-list/2019-June/msg00117.html

"""
* disk: storage format: this was from before the days when we
storage-ified everything and we could get the disk format wrong, telling
qemu it has a raw image when it's qcow2. shouldn't be needed anymore for
normal virt usage
"""

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-25 14:30:07 -05:00
Cole Robinson
1066867583 virtManager: Remove disk serial UI
This was proposed here:
https://www.redhat.com/archives/virt-tools-list/2019-June/msg00117.html

"""
* disk: serial: I know this is useful in some cases but seems quite
obscure. I think the XML editor is fine unless there's some common
usecase I'm missing
"""

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-25 13:45:43 -05:00
Cole Robinson
bd82ef6529 virtManager: Remove spice tlsport UI
This was discussed here:
https://www.redhat.com/archives/virt-tools-list/2019-June/msg00117.html

tlsPort is an advanced config feature. With the XML editing support,
it's less important to have this as a first class UI element. Users
that know they need this setting can set it directly in the XML

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-24 17:04:29 -05:00
Cole Robinson
ee9f93074b Remove virt-convert
This was raised here:
https://www.redhat.com/archives/virt-tools-list/2019-June/msg00117.html

Quoting from that:

"""
virt-convert takes an ovf/ova or vmx file and spits
out libvirt XML. It started as a code drop a long time ago that could
translate back and forth between vmx, ovf, and virt-image, a long dead
appliance format. In 2014 I converted it to do vmx -> libvirt and ovf ->
libvirt which was a CLI breaking change, but I never heard a peep of a
complaint. It doesn't seem to do a particularly thorough job at its
intended goal, I've seen 2-3 bug reports in the past 5 years and
generally it doesn't seem to have any users. Let's kill it. If anyone
has the desire to keep it alive it could live as a separate project
that's a wrapper around virt-install but there's no compelling reason to
keep it in virt-manager.git IMO
"""

Nothing has changed since then, so here is the removal.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-24 17:04:29 -05:00
Cole Robinson
cdbc3f56e6 cli: kill --graphics keymap=local, and hostkeymap module
Removing this was discussed here:
https://www.redhat.com/archives/virt-tools-list/2019-June/msg00117.html

This is the old default, where we would try to determine a static
keymap value from host graphics config files, and set that in the
XML.

We haven't defaulted to this for a long time, setting a static keymap
is suboptimal generally, and the file parsing code is not up to date
for modern host config. So let's remove it

The hostkeymap module is now unused, so remove it and all the custom
testing for it.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-24 17:04:29 -05:00
Cole Robinson
7251ea25c2 virtManager: Remove graphics keymap UI
Removing this was discussed here:
https://www.redhat.com/archives/virt-tools-list/2019-June/msg00117.html

For a decade, qemu and xen and virt-manager work together to
make setting a manual keymap redundant. Advertising it in the UI does
more harm than good, because users may think they need to specify
one when in the vast majority of cases it will give worse behavior.

With the XML editing UI, users still have a way to do this by hand
if they really know what they are doing.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-24 17:04:29 -05:00
Cole Robinson
188fd4adb1 cli: Drop keymap santizing
We shouldn't be validating against a static list of keymaps,
instead we should let libvirt or the hypervisor throw and error.

Also the accompanying code is about to be removed.

It's possible this will break command line usage for some users, like
if they were passing keymap=US and depending on our logic to lower()
it for them. I think this should be rare, and IMO it's acceptable to
tell users to just fix their command line, which should work correctly
with older versions too, so it should be a one time fix.

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-24 17:04:29 -05:00
Cole Robinson
419f8cd31b pollhelpers: Streamline usage a bit
* Explicitly define the build 'cb', don't use lambda
* Rename pollhelpers arguments, clarifying use of cb
* Check support status in pollhelpers
* Move 'dopoll' checking up a level in vmmConnection

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-24 17:04:29 -05:00
Cole Robinson
3ad646fef1 pollhelpers: Kill old style polling
All the major hypervisor drivers have supported listAllDomains
since rhel6 vintage libvirt. Most other driver types have had the APIs
since their introduction, or for just as long.

I will be surprised if this affects anyone in any material way

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-24 17:04:18 -05:00
Cole Robinson
4147f760e8 connection: Explicitly error if domain listing APIs are not supported
This will be more important when we drop old domain polling APIs,
because it will be more likely we encounter an old libvirt or weird
connection without the expected API support

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-24 15:39:41 -05:00
Cole Robinson
1aff5a611e connection: Remove is_*_capable wrappers
Call the conn.support check directly. Move the check logging to
the initial startup path

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-24 15:39:41 -05:00
Cole Robinson
670e2fe11a tests: uitests: Fix for latest storage delete changes
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-24 15:39:41 -05:00
Cole Robinson
e046b2f26f ui: about: Add year 2020
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-24 15:18:56 -05:00
Cole Robinson
33eabb2a17 tests: clitest: Add --unattended reg-login= coverage
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-24 11:34:48 -05:00
Lily Nie
b2a424baa6 delete: remove redundant code
Reviewed-by: Cole Robinson <crobinso@redhat.com>
2020-01-24 10:27:15 -05:00
Fabiano Fidêncio
a9aeca60bb unattended: Add reg-login option to --unattended
As osinfo-db introduced the first usage of reg-login, let's also
add support for such option when using --unattended.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2020-01-24 10:05:03 -05:00
Lily Nie
3c6a5f4536 delete: Add _destroy_vm method
Reviewed-by: Cole Robinson <crobinso@redhat.com>
2020-01-21 19:53:53 -05:00
Lily Nie
928c049c9d delete: Add _delete_disks method
Reviewed-by: Cole Robinson <crobinso@redhat.com>
2020-01-21 19:53:53 -05:00
Lily Nie
52782a4958 delete: Add _delete_vm method
Reviewed-by: Cole Robinson <crobinso@redhat.com>
2020-01-21 19:53:53 -05:00
Lily Nie
8ae0c8ca0e delete: Add _vm_active_status method
Reviewed-by: Cole Robinson <crobinso@redhat.com>
2020-01-21 19:53:53 -05:00
Lily Nie
92200ef413 delete: Add _get_title_text method
Reviewed-by: Cole Robinson <crobinso@redhat.com>
2020-01-21 19:53:53 -05:00
Lily Nie
1ae83cbb82 delete: Add _get_disk_datas method
Reviewed-by: Cole Robinson <crobinso@redhat.com>
2020-01-21 19:53:53 -05:00
Lily Nie
4971e47566 delete: Add vmmDeleteStorage class
We should try to hide all the self.vm vs self.disk differences into
individual functions to make the code easier to follow and to avoid
touch those values by accident in the future

Reviewed-by: Cole Robinson <crobinso@redhat.com>
2020-01-21 19:53:53 -05:00
Cole Robinson
ec50dbd15d devices: disk: Ensure abspath when checking search permissions
Reported-by: Junqin Zhou <juzhou@redhat.com>
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-18 15:27:01 -05:00
Cole Robinson
08313ede2b man: virt-install: Improve --tpm docs
* Stop listing sub options, since there's multiple, and most won't
  need to be specified.

* Give an example for type=emulator

Reported-by: Junqin Zhou <juzhou@redhat.com>
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-18 15:27:01 -05:00
Cole Robinson
9346c22134 baseclass: Log if emit() called from non-MainThread
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-15 15:19:55 -05:00
Cole Robinson
5e63e87a8a cli: Default lxc:/// memory to 1024, and print it
My previous patch was misguided as pointed out by Pavel:
https://github.com/virt-manager/virt-manager/issues/73#issuecomment-574680435

And it was setting incorrect memory, which I missed because the tests
are busted here. Add a hack to work around that

Bump up the default to 1024, and print it, so the user can tell if
the default is not to their liking

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-15 11:07:42 -05:00
Cole Robinson
925948a19e virt-install: Add some coverage exclusions
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-15 11:00:21 -05:00
Lin Ma
15a9502b7b details: Fix showing the firmware type in case of firmware auto selection
For a shutoff VM, If user select uefi firmware auto selection, e.g.
<os firmware='efi'>
...
</os>

Its firmware information is set to 'BIOS' in details, This is incorrect.
This fixes it.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Lin Ma <lma@suse.com>
2020-01-15 10:21:46 -05:00
Cole Robinson
af3d678bdd domain: Only log once about waiting for qemu agent for set_time
Rather than one every wait period, which spams the debug logs

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-14 14:21:30 -05:00
Michael Weiser
b7a223030b virtManager: object: domain: Stop set time thread
Wire up stoppping of the time setting thread for actions that make
setting of guest time pointless.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Michael Weiser <michael.weiser@gmx.de>
2020-01-14 14:10:28 -05:00
Michael Weiser
f29196f3af virtManager: object: domain: Increase set time timeout
With the potential for annoyance eliminated, raise the timeout for guest
agent connectivity to 30 seconds.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Michael Weiser <michael.weiser@gmx.de>
2020-01-14 14:10:28 -05:00
Michael Weiser
9aa5997dd7 virtManager: object: domain: Add timeout config
Make the guest agent wait timeout and sleep interval properties of the
thread manager class better visibility and easier adjustment.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Michael Weiser <michael.weiser@gmx.de>
2020-01-14 14:10:28 -05:00
Michael Weiser
bfafe1e4b2 virtManager: object: domain: Spawn thread for set time
Sleeping in a loop waiting for the qemu guest agent to come online would
leave an annoying progress dialog while the domain would actually be
fully useable already. Additionally, multiple progress dialogs could
actually accumulate on screen if the user managed to suspend/resume fast
enough or the timeout was just long enough.

Defer regular retries into a separate thread to allow the progress
dialog to disappear immediately after the actual action completed. The
thread is encapsulated in a new class _vmmDomainSetTimeThread which
holds state, decides whether to at all wait for an agent to come online
or even try to set the guest time in the first place. It also holds
state (thread running or not), configuration (timeout and retry
interval) and provides an interface to start and stop the time setting
operation.

A later patch will wire up stopping the operation.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Michael Weiser <michael.weiser@gmx.de>
Suggested-by: Cole Robinson <crobinso@redhat.com>
2020-01-14 14:10:28 -05:00
Michael Weiser
4f8a27688d virtManager: object: domain: Refactor guest time setting
Sleeping in a loop waiting for the qemu guest agent to come online
leaves an annoying progress dialog while the domain may actually be
fully useable already. Additionally, multiple progress dialogs can
actually accumulate on screen if the user manages to suspend/resume fast
enough or the timeout is just long enough.

To avoid these, we want to defer retries into a separate thread to allow
the progress dialog to disappear immediately after the actual action
completed.

In preparation for that, add a new class _vmmDomainSetTimeThread that
will eventually manage that separate thread for guest time setting
operations. Move the current code for waiting for the qemu guest agent
into it without any semantic changes.

Make set_time() and agent_read() of vmmDomain accessible from the
outside so that _vmmDomainSetTimeThread can call back into them. Add
has_agent() to be able to find out if the domain has an agent configured
without leaking the actual agent config.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Michael Weiser <michael.weiser@gmx.de>
Suggested-by: Cole Robinson <crobinso@redhat.com>
2020-01-14 14:10:28 -05:00
Michael Weiser
827c948121 virtManager: object: domain: Simplify agent ready check
Just return the boolean value of the condition for simlicity.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Michael Weiser <michael.weiser@gmx.de>
2020-01-14 14:10:28 -05:00
Cole Robinson
e4f68764b0 virt-install: Set default memory to appease lxc:///
AFAICT the driver doesn't really do anything with it, but libvirt
XML requires it. So just default to --memory 64

Fixes: #73

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-14 13:10:03 -05:00
Pino Toscano
9b7c819c64 Install the AppStream file to the canonical location
The canonical location for AppStream XML files has been changed to
/usr/share/metainfo four years ago at least, with /usr/share/appdata
left as legacy location. It is time to switch to the right location.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-01-14 12:40:44 -05:00
Cole Robinson
a9cbc4e583 error: Set a cap on error dialog text size
Otherwise we can get some crazy sized dialogs with errors from
libvirt

https://bugzilla.redhat.com/show_bug.cgi?id=1786873

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-14 12:40:39 -05:00
Pino Toscano
b1b9e4b688 Avoid string puzzle
Do not join two parts of sentences together, because it is problematic
to translate. Instead, use a different sentence depending on the
condition.

Fixes commit d52c9d1ffa2d8c204fbb2a714f89b007fa6227ec.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
2020-01-14 12:40:25 -05:00
Cole Robinson
637781fca2 cli: Add --serial type= arg, with back compat alias char_type
'type' is the expected naming here

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-12-24 12:02:53 -05:00
Lily Nie
2138cca6a5 Handle the warning messages for disk device and non-disk device differently
add a remove-non-disk function and move the yes/no confirmation handling there

Reviewed-by: Cole Robinson <crobinso@redhat.com>
2019-12-23 16:43:05 -05:00
Michael Weiser
d62ca8220b details: snapshots: Warn of saved state on creation
Add a confirmation dialog when creating a new snapshot if there is saved
memory state so the user is aware that memory state will not be part of
the snapshot.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Michael Weiser <michael.weiser@gmx.de>
Suggested-by: Cole Robinson <crobinso@redhat.com>
2019-12-23 16:27:52 -05:00
Michael Weiser
a8c25450bd details: snapshots: Drop saved state on restore
Refuse to restore a non-running state from snapshot while there is saved
memory state in order to avoid filesystem corruption. Present a message
to the user to that effect and let them choose to either abort the
operation or drop the saved state before restoring the snapshot.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Michael Weiser <michael.weiser@gmx.de>
Suggested-by: Cole Robinson <crobinso@redhat.com>
2019-12-23 16:27:52 -05:00
Michael Weiser
8084639cd8 virtManager: object: domain: Fix snapshot run check
snap.is_running() returns a boolean and checking that against
VIR_DOMAIN_RUNNING worked by pure coincidence only. Just use the bool
value and give it a more speaking name while at it.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Michael Weiser <michael.weiser@gmx.de>
2019-12-23 15:35:38 -05:00
Cole Robinson
6bec5474db virt-install: Check --transient status in domain --wait
Otherwise when the VM shuts down, we will report an error, because
the VM doesn't exist anymore. The check_domain_inactive() helper
already handles this case, we just weren't using it in the --wait loop.

https://bugzilla.redhat.com/show_bug.cgi?id=1785643

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-12-22 18:03:19 -05:00
Lily Nie
d52c9d1ffa Offer to delete the storage files without removing the VM
we should let users decide whether they want to also delete the
storage files or just dev from UI when they click the Remove button

Reviewed-by: Cole Robinson <crobinso@redhat.com>
2019-12-18 16:29:58 -05:00
Lily Nie
8b7854af1f Modify the remove_xml_dev function
add a remove_disk function,so that we can do some special things when remove a disk

Reviewed-by: Cole Robinson <crobinso@redhat.com>
2019-12-18 16:29:58 -05:00
Christian Ehrhardt
2a63003133 virtManager: disambiguize LXC
LXC can be many things and in particular when seeing just "LXC" in the
virt-manager UI one might think of either
- Libvirt-LXC => https://libvirt.org/drvlxc.html
- Linuxcontainers LXC => https://linuxcontainers.org

Clarify that this is specifically Libvirt-LXC

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Christian Ehrhardt <christian.ehrhardt@canonical.com>
2019-12-17 17:56:54 -05:00
Michael Weiser
adbcb06dd4 virtManager: object: domain: Set time on unpause and revert
Wire up setting of guest time on snapshot restore and resume from pause.
Do not try to set time if the restored snapshot does not contain a
running domain state.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Michael Weiser <michael.weiser@gmx.de>
Suggested-by: Cole Robinson <crobinso@redhat.com>
2019-12-17 17:51:05 -05:00
Michael Weiser
fa7d3eeb7b virtManager: object: domain: Check for guest agent
For qemu, only run the API if the VM has the qemu guest agent in the
XML. If it is present, wait for it to come online instead of
unconditionally retrying a number of times.

Reuse agent function agent_ready() from refresh_interface_addresses()
and refactor it into two methods of which get_agent() can be used to
check for agent presence and further work with the channel object.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Michael Weiser <michael.weiser@gmx.de>
Suggested-by: Cole Robinson <crobinso@redhat.com>
2019-12-17 17:51:05 -05:00
Michael Weiser
163eea6924 virtManager: object: domain: Restrict time sync to qemu
Only run the API for qemu and test drivers, they are the only ones
that support it. This will save spamming logs with error output.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Michael Weiser <michael.weiser@gmx.de>
Suggested-by: Cole Robinson <crobinso@redhat.com>
2019-12-17 17:51:05 -05:00
Michael Weiser
8457145608 virtManager: object: domain: Set time on resume
Use a potentially available agent inside the domain to update guest time
after resume. Based on the same function in Nova[1].

[1] 414df1e56e

Signed-off-by: Michael Weiser <michael.weiser@gmx.de>

Reviewed-by: Cole Robinson <crobinso@redhat.com>
https: //bugzilla.redhat.com/show_bug.cgi?id=1222069
Signed-off-by: Michael Weiser <michael.weiser@gmx.de>
2019-12-17 17:51:05 -05:00
Fabiano Fidêncio
616ac2ebe3 installerinject: Check for genisoimage and mkisofs before calling it
Let's check for both genisoimage and mkisofs as some distros will ship
mkisofs without linking it to genisoimage, as OpenSUSE Leap 15.1 does.

And, I know, genisoimage is a requirement of the project. However, it's
not packaged on OpenSUSE Leap 15.1 while mkisofs is present there.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-12-17 17:09:26 -05:00
Michal Privoznik
66be1d009f domcapabilities: Whitelist upstream qemu edk2 paths
Upstream qemu installs
/usr/share/qemu/edk2-$ARCH-(?secure-)code.fd FW images. Whitelist
them too.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
2019-12-17 16:27:49 -05:00
Cole Robinson
e879097d1b cli: Clean up process if execv fails
Like if /bin/true is missing, as it was on freebsd. Use /bin/test
instead which appears to have a higher likelyhood of existing

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-12-11 17:57:35 -05:00
Cole Robinson
78ad233653 tests: abide logging options for clitests
We need to restore logging after calling the cli tools. Centralize
the logging reset behavior since we need that too

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-12-11 17:57:28 -05:00
Pavel Hrdina
39366c37f6 controller: don't set default controller index
Libvirt is able to figure this out and it will make usage of the CLI
options more user-friendly.

For example if users wants to add a new pcie-root-port to existing VM
they have to figure out the latest controller index and call it like
this:

    virt-xml \
        --add-device \
        --controller pci,model=pcie-root-port,index=$nextIndex \
        $VM

After this change it will be simply:

    virt-xml \
        --add-device \
        --controller pci,model=pcie-root-port \
        $VM

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
Reviewed-by: Cole Robinson <crobinso@redhat.com>
2019-12-04 12:38:28 +01:00
Pavel Hrdina
29f9f5f2d7 virt-xml: fix defined_xml_is_unchanged
Commit <53f075ab76e1c372474ae0d88f202e487d9f213f> added a warning if the
VM XML is not changed after removing default devices but the code was
incorrect.  We have to compare strings instead of string vs Guest object
and also the condition was inverted.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2019-12-03 13:04:37 +01:00
Cole Robinson
5f0155508d man: Document --autoconsole
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-25 17:20:37 -05:00
Cole Robinson
b31b28a15e man: Document --cloud-init option
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-25 17:14:21 -05:00
Cole Robinson
7fee1a2814 cli: Fix --cloud-init and --unattended 'none' handling
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-25 14:19:09 -05:00
Cole Robinson
747c1e9d11 virt-install: Move cloudinit password printing before guest start
Otherwise if the timeout is hit, the user may miss VM boot output

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-25 14:03:49 -05:00
Cole Robinson
04b15f0dba cloudinit: Don't regenerate root password
Store the first one we generate for later usage

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-25 14:03:49 -05:00
Cole Robinson
da996317f8 cli: cloudinit: default to --autoconsole text with --cloud-init
Cloud images all work nicely with text output, and it's likely
the preferred native way to connect to the guest vs graphical.
Plus it simplifies generated password copy+paste

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-25 14:03:49 -05:00
Cole Robinson
c5da0d7b07 virt-install: Don't pause for cloudinit pass if stdin is closed
Like if run in a script without any stdin open. Have the test suite
actually hit this path

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-25 14:03:49 -05:00
Cole Robinson
226378d522 unattended: Fix errors when running as root
Tries to use 'root' as VM username, which is forbidden

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-25 12:02:27 -05:00
Cole Robinson
530befc222 unattended: fix error message variable order
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-25 11:49:38 -05:00
Cole Robinson
e488696cef cli: Add explicit --autoconsole option
Allows the user to override our implicit '--autoconsole default'
handling

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-25 06:22:14 -05:00
Cole Robinson
85a33caa76 cli: Expose default console handling through _AutoconsoleData
Rework all console queries to go through that object API

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-25 06:20:42 -05:00
Cole Robinson
44c519200c cli: Add _AutoconsoleData and use it
This will be expanded later to track explicit requests for certain
console types

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-24 18:12:06 -05:00
Cole Robinson
1676f05a59 virt-install: Split out show_console_warnings
And only call it once console handling is in play

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-24 18:12:06 -05:00
Cole Robinson
4ef519229d virt-install: Drop warning about '--console none'
This should be rarely if ever used, don't warn the user about this
case

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-24 17:25:51 -05:00
Cole Robinson
b55a959e5e installer: Use standard scratchdir for cloudinit tempfiles
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-23 10:38:49 -05:00
Cole Robinson
18ff22f732 cloudinit: Add license header
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-22 22:59:27 -05:00
Cole Robinson
a67237b221 cloudinit: Rework file building
* Ensure files are cleaned up if we fail mid run
* Ensure temp user-data and meta-data files are cleaned up
* Move dest file naming into cloudinit.py

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-22 22:57:43 -05:00
Cole Robinson
ed6436e455 tests: Move cloudinit test data to its own sub directory
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-21 17:38:46 -05:00
Cole Robinson
89fc06f642 cli: Add --cloud-init meta-data=/path/to/meta-data
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-21 17:34:39 -05:00
Cole Robinson
e1bd5f92cf cli: Add --cloud-init user-data=/path/to/user-data
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-20 17:47:34 -05:00
Cole Robinson
9a3f73710e cloudinit: Only print generated password if it was requested
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-20 17:47:34 -05:00
Cole Robinson
f107aaab02 cloudinit: split out _create_userdata_content
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-20 17:32:49 -05:00
Athina Plaskasoviti
7ae6a60086 cloudinit: Move random password printing and sleeping to virt-install
Fixed:
- Added a do_log flag to print_stdout(), to avoid logging of printed random password.
- Excluded timeout in virt-install from testing

Signed-off-by: Athina Plaskasoviti <athina.plaskasoviti@gmail.com>
2019-11-20 16:41:10 -05:00
AthinaPl
b4daeba6b5 cloudinit: Add ssh-key=/path/to/key cli option
Login to VM with:
ssh root@vm_ip_address

Signed-off-by: AthinaPl <athina.plaskasoviti@gmail.com>
2019-11-20 16:41:10 -05:00
Athina Plaskasoviti
3014644f25 cloudinit: Scrub password from logs
Signed-off-by: Athina Plaskasoviti <athina.plaskasoviti@gmail.com>
2019-11-20 16:41:10 -05:00
Athina Plaskasoviti
1b43ae8716 cloudinit: Fix password expiration
Password expiration happens in case of one time random password generation.
When user provides password from file, don't expire the password.

Signed-off-by: Athina Plaskasoviti <athina.plaskasoviti@gmail.com>
2019-11-20 16:41:10 -05:00
Athina Plaskasoviti
7a2c53612f cloudinit: Add root-password-generate=yes|no instead of root-password=xxxx
Now --cloud-init defaults to root-password-generate=yes,disable=yes.
Option for plaintext password given through the cli is completely removed.

Reviewed-by: Fabiano Fidêncio <fidencio@redhat.com>
Signed-off-by: Athina Plaskasoviti <athina.plaskasoviti@gmail.com>
2019-11-20 16:41:10 -05:00
Athina Plaskasoviti
050d4dd62a cloudinit: Add cli option root-password-file=/path/to/file
Reviewed-by: Fabiano Fidêncio <fidencio@redhat.com>
Signed-off-by: Athina Plaskasoviti <athina.plaskasoviti@gmail.com>
2019-11-20 16:41:10 -05:00
Athina Plaskasoviti
66d95c6792 cloudinit: Move password generation inside class CloudInitData
Function generate_password() provides random 16 digit password and
get_root_password() handling root_password assignment.

Signed-off-by: Athina Plaskasoviti <athina.plaskasoviti@gmail.com>
2019-11-20 16:41:10 -05:00
Athina Plaskasoviti
db0e524e8d cloudinit: Add basic testing for cli option --cloud-init
Tests now cover default --cloud-init behavior, and
root-password=(generate and given password),disable=no.

Signed-off-by: Athina Plaskasoviti <athina.plaskasoviti@gmail.com>
2019-11-20 16:41:10 -05:00
Athina Plaskasoviti
9266cc47c1 cloudinit: Change iso suffix for cloud image installations
Generated iso now called ...-cloudinit.iso.

Signed-off-by: Athina Plaskasoviti <athina.plaskasoviti@gmail.com>
2019-11-20 16:41:10 -05:00
Athina Plaskasoviti
dadaf8eb45 cloudinit: Fixed broken testsuite
Signed-off-by: Athina Plaskasoviti <athina.plaskasoviti@gmail.com>
2019-11-20 16:41:10 -05:00
Athina Plaskasoviti
0e5b1b3048 cloudinit: Clean up create_metadata and create_userdata functions from unused/unwanted arguments
Signed-off-by: Athina Plaskasoviti <athina.plaskasoviti@gmail.com>
2019-11-20 16:41:10 -05:00
Athina Plaskasoviti
0bbfc80b68 cloudinit: Add disable=yes|no
Cli option to permanently disable cloud-init after first boot by user request.
Handled so that bare --cloud-init defaults to --cloud-init root-password=generate,disable=yes.

Signed-off-by: Athina Plaskasoviti <athina.plaskasoviti@gmail.com>
2019-11-20 16:41:10 -05:00
Cole Robinson
ec47c9dafc cloudinit: Fix setting root password in user-data 2019-11-20 16:41:10 -05:00
Athina Plaskasoviti
19317024cc Introduction of cloud-init configuration in virt-install
Usage:
--cloud-init

Signed-off-by: Athina Plaskasoviti <athina.plaskasoviti@gmail.com>
2019-11-20 16:41:05 -05:00
Cole Robinson
c311b28979 cli: Add 'clearxml' arg for options it doesn't apply to
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-20 16:40:00 -05:00
Fabiano Fidêncio
1d9d91910a installertreemedia: Respect os_variant when setting kernel_url_arg
Currently, the kernel_url_arg is get based on the cached data. However,
when the cached data is created, the store is already set to a "generic"
distro and the os_variant is not respected when getting the
kernel_url_arg.

In order to avoid ignoring os_variant when looking up the kernel_url_arg,
let's also take into the consideration the the os_variant passed via
command line, which was used to set Guest's osinfo name, returning then
the expected value to the caller.

Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-11-20 16:04:09 -05:00
Fabiano Fidêncio
b78b8a96cf virt-install: Respect --os-variant
When the user explicitly passes --os-variant via command line, its value
must be respected, always.

By setting the os name earlier, we force the os-variant to be respected
when the installer creates the Distro Store.

Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-11-20 16:04:09 -05:00
Fabiano Fidêncio
54edd0a0a6 unattended: Never use "root" as user-login
When running virt-install as root, user-login would be automatically set
to "root", causing an installation failure in the most part of the
distros (if not all of them).

In order to avoid such failures, let's raise a runtime error in case the
user-login used is "root".

Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-11-20 16:04:09 -05:00
Cole Robinson
82b75a93b6 delete: Add _DiskData class for tracking path delete metadata
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-20 15:22:03 -05:00
Cole Robinson
57a1f19841 delete: Clean up code layout a bit
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-20 14:47:07 -05:00
Cole Robinson
5d8bd316c1 tests: test_urls: Reset cached guest os_variant before short circuit test
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-12 16:16:55 -05:00
Fabiano Fidêncio
cdcec1fb03 unattended: Add option to set the user-login
Let's allow setting the login of the guest user.

Using the user from the system is a quite good fallback, but would break
unattended installations when running virt-install as root. Thus, for
those cases, it makes sense to have the option of setting the user
login.

Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-11-12 16:07:07 -05:00
Cole Robinson
0e9905d057 uitests: Fix memory hotplug test with latest libvirt
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-12 14:23:08 -05:00
Cole Robinson
fb2bfd610f details: Use Guest.lookup_domcaps helper
This ensures the Guest object domcaps cache is primed as well, which
prevents the CPU security features handling from constantly refetching
domcaps info.

We need to tweak the cache invalidation check in Guest to handle
some of the test suite hackery we do

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-12 14:20:36 -05:00
Cole Robinson
5d91237386 domcaps: Tweak cpu security feature log statements
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-12 14:17:21 -05:00
Cole Robinson
d934d6f266 domcaps: Fix check for uncached security features
We need to check against None, which is the initial value, otherwise
a host with none of the security features present will repeatedly poll
libvirt baseline APIs

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-11-12 14:17:21 -05:00
Michael Weiser
51d84c54cb connection: Avoid repeated default pool creation attempts
During startup virtinst.StoragePool.build_default_pool() tries to
determine whether the default storage pool already exists. Because
events have not yet been processed, the list of existing storage pools
is still empty. Therefore it seems as if it does not exist yet and
build_default_pool() falls back to creating it which causes an error
message from libvirtd in the system log:

libvirtd: operation failed: pool 'default' already exists with uuid.

Move default pool creation after event processing to avoid these
redundant creation attempts.

Signed-off-by: Michael Weiser <michael.weiser@gmx.de>
2019-11-12 12:28:34 -05:00
Florian Ludwig
ae19d6d6ec fix resizing of spice clients with guest resizing enabled
Fixes 1414718
2019-11-12 11:46:35 -05:00
Cole Robinson
062ff8227a tests: Update output with latest libvirt
Which forces disk type='file' when <source> is missing

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-10-22 10:29:19 -04:00
Pavel Hrdina
df48a77e6a virtinst: fix detection if baselineHypervisorCPU API is available
With libvirt-python >= 4.4.0 and libvirt < 4.4.0 we would receive
libvirt.libvirtError exception because the python binding knows about
the function but it's not supported by libvirt.  However, in case that
the python binding is older then 4.4.0 it will raise AttributeError
because the function is not implemented in python binding as well.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2019-10-22 13:42:21 +02:00
Fabiano Fidêncio
d9736db9d9 addhardware: Add "bochs" display to the video list
https://bugzilla.redhat.com/show_bug.cgi?id=1753644

Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-10-04 11:17:14 -04:00
Fabiano Fidêncio
8f4c53ea96 video: Prefer "bochs" when it's supported.
Preferring "bochs" display device is the way to go when dealing with a
Linux guest using UEFI and that's quite well described here:
https://www.kraxel.org/blog/2019/09/display-devices-in-qemu/

https://bugzilla.redhat.com/show_bug.cgi?id=1753644

Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-10-04 11:17:10 -04:00
Fabiano Fidêncio
2e20b128a1 domcapabilities: Add supports_video_bochs()
Returns whether bochs display is supported, according to the domain
capabilities.

Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-10-04 11:15:09 -04:00
Fabiano Fidêncio
1547e16d62 domcapabilities: Get video devices
domcapabilities already handles disk and hostdev. Let's add support for
getting video devices as well.

Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-10-04 11:15:09 -04:00
Cole Robinson
651e5b6d75 devices: video: Simplify model hvm check
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-10-03 15:41:44 -04:00
Cole Robinson
534f2e03d0 guest: Drop set_capabilities_defaults call from get_uefi_path
Callers need to handle this themselves, and all callers do AFAICT

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-10-03 15:35:59 -04:00
Cole Robinson
4e07c3d8f3 Fix tests with latest osinfo-db
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-10-03 06:57:42 -04:00
Cole Robinson
355d7fed80 installer: Clean up unattended preinstall drivers
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-10-02 11:58:37 -04:00
Fabiano Fidêncio
b6e4e4538d virt-install: Use virtio-win drivers if possible
Let's ensure the Windows guests being installed through unattended
installations, which are able to have pre installable drivers intalled,
will use virtio devices when possible.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-10-02 11:58:34 -04:00
Fabiano Fidêncio
e7704d3c8b guest: Add add_extra_drivers()
Let's add a new API to set extra drivers that can be used during
installation time when performing unattended installations. This is
needed for pre-installing virtio-win drivers on Windows guests.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-10-02 11:58:34 -04:00
Fabiano Fidêncio
e32e609243 installer: install the pre-installable drivers
Let's download and install the pre-installable drivers, if they're
available.

The reason we're only dealing with pre-installable drivers here is that
post-installable drivers would have to keep the unattended is available
accross reboots, resulting in a file that can't be cleaned up at this
point.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-10-02 11:58:34 -04:00
Fabiano Fidêncio
ef8c772be7 guest,osdict: Pass down extra_devs to supports_virtio*() methods
Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-10-02 11:58:34 -04:00
Fabiano Fidêncio
35f6938c10 osdict: Pass down extra_devs to _device_filter()
Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-10-02 11:58:34 -04:00
Fabiano Fidêncio
afd3a98c1d osdict: Add extra_devs to supports_* methods
Similarly to what has been done for _device_filter(), let's add
"extra_args" parameter to support_* methods so we can pass them down to
_device_filter().

Only supports_virtio* methos would actually need the extra argument, but
let's be consistent here and add it to all supports_* methods.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-10-02 11:58:34 -04:00
Fabiano Fidêncio
e522a0edcb osdict: Add extra_devs to _device_filter()
Let's add "extra_devs" to _device_filter() so we can pass a list of
devices which can be used by an OS but are not part of the distro / OS
itself.

By doing this, we also expand the _device_filter() check and take those
into account when they're passed.

That's exactly the case of pre-installable drivers for Microsoft
Windows.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-10-02 11:58:34 -04:00
Fabiano Fidêncio
efb0220510 osdict: Add get_pre_installable_devices()
Let's add a new method to get the devices which are supported when
taking advantage of a pre / post installable drivers.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-10-02 11:58:34 -04:00
Fabiano Fidêncio
e59585b58b unattended: Add method to download drivers
This will be used by unattended installations in order to download both
pre & post installable drivers.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-10-02 11:58:34 -04:00
Fabiano Fidêncio
eac05bfbec osdict: Add supports_unattended_agents()
The post-installable drivers provided by osinfo-db are merely agents,
which are not a blocker for an installation to succeed using virtio &
having a bootable guest.

Let's add this method as a counter part of supports_unattended_drivers()
and use it in the future, when we re-work the installation code of
virt-install and are able to perform installations of MSIs.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-10-02 11:58:34 -04:00
Fabiano Fidêncio
89a2a71328 osdict: Re-purpose supports_unattended_drivers()
supported_unattended_drivers() was originally added as a way to tell
whether a guest could support pre & post installable drivers.

This is wrong for two reasons:
- virt-install cannot deal with post-installable drivers/agents;
- pre-installable drivers are the only ones needed in order to perform
  an unattended installation taking advantage of virtio-win drivers;

Knowing that, let's only check for pre-installable drivers in
supported_unattended_drivers().

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-10-02 11:58:34 -04:00
Fabiano Fidêncio
9465da4174 urlfetcher: Deal with 'file://' in _LocalURLFetcher()
osinfo-db may contain files pointing to local paths, which will have the
format 'file:///usr/share/...'.

With the current code, virt-install would just bail as it doesn't
understand the 'file://' schema. Let's start using urllib (which is
already imported in the very same file) and parse the URL so both
'file:///usr/share/...' and '/usr/share/...' would work.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-10-02 11:58:34 -04:00
Fabiano Fidêncio
96af1de49f unattended: Avoid invalid chars on hostname
Some installations (Microsoft Windows was the problematic one here) will
bail if the Computer's name / hostname contains one of the following
characterers:  "[{|}~[\\]^':; <=>?@!\"#$%`()+/.,*&]".

Let's take a safe path and ensure that we never set those, replacing
them by "-".

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-10-02 11:58:34 -04:00
Cole Robinson
aadaaf8785 manager: Don't hardcode black text color
Improves readability on dark theme

Resolves: #52

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-10-02 10:32:04 -04:00
Fabiano Fidêncio
d6d97c6587 osdict: Choose the most appropriate tree when a profile is set
As some OSes, as Fedora, have variants (which we rely to be standardised
on osinfo-db side), let's select the most appropriate variant according
to the selected profile of the unattended installation.

Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-09-11 16:22:40 -04:00
Fabiano Fidêncio
0f1acc9f8f osdict: Always return the most generic tree
Some OSes, as Fedora, have variants (which we rely to be standardised on
osinfo-db side), which we can use to return the most generic tree
possible, in case no profile is specified, in order to avoid failing to
install a "Workstation" system because a "Server" variant tree was used.

https://bugzilla.redhat.com/show_bug.cgi?id=1749865

Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-09-11 16:22:40 -04:00
Cole Robinson
0eb571f9e1 cli: Add --tpm backend.encryption.secret=
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-09-04 08:29:58 -04:00
Menno Lageman
0254558e6e cli: add --features kvm.hint-dedicated.state=
QEMU version 2.12.1 introduced a performance feature under commit
be7773268d98 ("target-i386: add KVM_HINTS_DEDICATED performance hint").
Support for this performance hint was added in libvirt 5.7.0 by commit
cb12c59dac04 ("qemu: support for kvm-hint-dedicated performance hint").

This patch extends virt-install's existing --features option to insert the
appropriate XML into the guest definition if this feature is specified
on the command line.

    E.g. --features='kvm.hint-dedicated.state=on' would result
    in the following XML:

      <features>
        ...
        <kvm>
          <hint-dedicated state='on'/>
        </kvm>
        ...
      </features>

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Menno Lageman <menno.lageman@oracle.com>
2019-09-03 14:04:18 -04:00
Cole Robinson
1f0c262051 cli: Add --controller driver.iothread
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-08-28 13:17:32 -04:00
Cole Robinson
cee3f6b48e cli: Add --disk driver.iothread
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-08-28 12:43:56 -04:00
Athina Plaskasoviti
2e49041d85 cli: Add --clock timer[0-9]*.catchup options
Added:
-timer[0-9]*.catchup.threshold
-timer[0-9]*.catchup.slew
-timer[0-9]*.catchup.limit

Catchup attributes need timer with assigned tickpolicy=catchup.

XML Mapping:

<clock>
  ...
  <catchup threshold="X" slew="X" limit="X"/>
  ...
</clock>

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Athina Plaskasoviti <athina.plaskasoviti@gmail.com>
2019-08-19 15:39:47 -04:00
Athina Plaskasoviti
cc60d558c0 cli: Add --cputune memorytune options
--memorytune[0-9]*.vcpus
--memorytune[0-9]*.node[0-9]*.id
--memorytune[0-9]*.node[0-9]*.bandwidth

XML Mapping:

<cputune>
  ...
  <memorytune vcpus="X">
    <node id="X" bandwidth="X"/>
  </memorytune>
  ...
</cputune>

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Athina Plaskasoviti <athina.plaskasoviti@gmail.com>
2019-08-19 15:39:47 -04:00
Athina Plaskasoviti
9cea262b85 cli: Add --cputune cachetune options
- cachetune[0-9]*.vcpus
- cachetune[0-9]*.cache[0-9]*.level
- cachetune[0-9]*.cache[0-9]*.id
- cachetune[0-9]*.cache[0-9]*.type
- cachetune[0-9]*.cache[0-9]*.size
- cachetune[0-9]*.cache[0-9]*.unit

XML Mapping:

<domain>
...
  <cputune>
  ...
    <cachetune vcpus="X">
      <cache level="X" id="X" type="X" size="X" unit="X"/>
    </cachetune>
  ...
  </cputune>
...
</domain>

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Athina Plaskasoviti <athina.plaskasoviti@gmail.com>
2019-08-19 15:39:47 -04:00
Erik Skultety
3d5a72e18a man: virt-install: Fix a couple of launchSecurity related typos
Signed-off-by: Erik Skultety <eskultet@redhat.com>
Reviewed-by: Martin Kletzander <mkletzan@redhat.com>
2019-08-14 09:25:26 +02:00
Cole Robinson
92f6109eef tests: osdict: Add coverage testing for driver helpers
Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Cole Robinson <crobinso@redhat.com>
2019-08-06 17:59:05 -04:00
Fabiano Fidêncio
7bc40eeed1 osdict: Add supports_unattended_drivers()
Let's add a method which tells us whether pre & post installable drivers
are supported when performing unattended installations.

This is going to help us in the future in order to force virtio-win
usage when unattended installing guests which support it.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-08-06 17:59:05 -04:00
Fabiano Fidêncio
ff337843e6 osdict: Add get_{pre,post}_installable_drivers_location()
Let's add two new methods to get the pre & post installable drivers'
location, returning a list of URLs (strings).

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-08-06 17:59:05 -04:00
Fabiano Fidêncio
8ab2e49e36 osdict: Add _get_{pre,post}_installable_drivers()
Let's add two new *private* methods to get the pre & post installable
drivers, returning a list of OsinfoDeviceDrivers;

Those are going to be used later on this series in order to get the
drivers' locations.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-08-06 17:59:05 -04:00
Fabiano Fidêncio
3009888a0e urlfetcher: Don't override fullurl when it's explicitly set
acquireFile method receives an optional "fullurl" argument. In case it's
not passed, its value is set as the same value of the filename. However,
when fullurl is passed, it should be used and not overriden by the
filename, otherwise fetcher.acquireFile() will just bail.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-08-06 17:59:05 -04:00
Fabiano Fidêncio
5324582747 urlfetcher: Force a flush after writing to a file
While downloading really small files, on some file systems, the files
may not be flushed on time for whatever reason they've been downloaded.

This issue was noticed after trying to perform unattended installations
and noticing that some files, particularly really small ones, where just
empty.

While the original issue would be fixed by doing the flush on
_HTTPURLFetcher::_write(), let's also force it on _URLFetcher::_write()
to do the same.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-08-06 17:59:05 -04:00
Athina Plaskasoviti
7f8648c53d cli: Add --boot initdir, inituser, initgroup options
XML Mapping:

<os>
...
<initdir>X</initdir>
<inituser>X</inituser>
<initgroup>X</initgroup>
...
</os>

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Athina Plaskasoviti <athina.plaskasoviti@gmail.com>
2019-08-03 19:34:18 -04:00
Fabiano Fidêncio
6c7a586a9c osdict: Remove extra new line
Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-08-01 21:05:45 -04:00
Fabiano Fidêncio
f4d91dfcd2 unattended,installer*: Deal with multiple install scripts
Windows' unattended installations have more than one installation script
in order to perform a "post" installation of some drivers
(spice-guest-tools, actually).

In order to do so, let's:
- Change unattended::_lookup_rawscript() to return a list of scripts;
  - And also rename it to _lookup_rawscripts();
- Change unattended::prepare_install_script to return a list of scripts;
  - And also rename it to prepare_install_scripts
- Change installer::_prepare_unattended_data() to deal with a list of
  scripts;
  - And also do the "renaming" changes accordingly;
- Change installertreeinfo::_prepare_unattended_data() to deal with a
  list of scripts;
  - And also do the "renaming" changes accordingly;
  - Mind that this change is not exactly needed as Linux unattended
    installations have only one install script. However, the change has
    been done ir order to be consitent with the changes done in the
    installer;
- Change installertreeinfo::_prepare_kernel_args() to deal with a list
  of scripts;
  - And also do the "renaming" changes accordingly;
  - As the changes above, this one is not exactly needed for the very
    same reason;

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-08-01 21:05:45 -04:00
Cole Robinson
9c051fe65f osdict: Use media_create_from_location_with_flags
If it's available, because it fixes detection of non-bootable
media, like debian s390x
2019-08-01 19:15:08 -04:00
Cole Robinson
e77066b713 osdict: Use get_short_id_list
Some osed have multiple short-ids, like debian10 also has debianbuster.
Use the API if it's available. This will make it easier to remove
our back compat aliases eventually
2019-08-01 18:57:36 -04:00
Cole Robinson
cd72213b85 storage: Exclude a line from code coverage
To get back to 100% coverage
2019-07-31 17:53:51 -04:00
Cole Robinson
b85a5558f9 tests: Fix testsuite with older libosinfo
We need to handle if get/set_installation_url is missing
2019-07-31 17:43:49 -04:00
Cole Robinson
b20c5764bc man: Document the --keywrap option 2019-07-28 18:11:04 -04:00
Athina Plaskasoviti
e70ead5098 cli: Add --blkiotune device[0-9]*.read_bytes_sec/write_bytes_sec/read_iops_sec/write_iops_sec options
XML Mapping:

<blkiotune>
  <device>
    ...
    <read_bytes_sec>X</read_bytes_sec>
    <write_bytes_sec>X</write_bytes_sec>
    <read_iops_sec>X</read_iops_sec>
    <write_iops_sec>X</write_iops_sec>
    ...
  </device>
</blkiotune>

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Athina Plaskasoviti <athina.plaskasoviti@gmail.com>
2019-07-25 19:13:13 -04:00
Fabiano Fidêncio
414ffa5ef8 virt-install: Use minutes instead of seconds on get_time_string()
get_time_string() currently uses self._wait_secs, while it should use
self._wait_mins, resulting on confusing messages when using `--wait`
option, as shown below:

fidencio@laerte ~/src/upstream/virt-manager $ ./virt-install --install fedora30 --unattended --wait 20
 ...
Waiting 1200 minutes for installation to complete.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-07-25 19:13:13 -04:00
Athina Plaskasoviti
9afe51a0f8 cli: Add --keywrap cipher[0-9]*.name=aes|des, cipher[0-9]*.state=on|off
XML Mapping:

<domain>
...
  <keywrap>
    <cipher name="X" state="X"/>
  </keywrap>
...
</domain>

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Athina Plaskasoviti <athina.plaskasoviti@gmail.com>
2019-07-23 16:59:32 -04:00
Cole Robinson
567463a07c tests: Drop iso symlinking
This was originally added so we had stable paths in the XML. It's
not required anymore, and if it becomes an issue we should fix it
by scrubbing the compared xml
2019-07-17 17:47:46 -04:00
Cole Robinson
2897951ce1 tests: Drop os.system calls
Use python native code instead. This seems to avoid an occasional
crash or abort of some sort with latest libosinfo
2019-07-17 16:54:59 -04:00
Cole Robinson
ef46af706a storage: Don't leave thread stranded on error
Move thread callback outside the StorageVolume class, so we are
forced to explicitly pass in every bit it may act on. Ensure we
always cancel and clean up the thread
2019-07-17 12:57:38 -04:00
Fabiano Fidêncio
7148727a05 osdict: Use identify_tree()
Let's use identify_tree(), which is part of libosinfo v1.6.0 release,
instead of using guess_os_from_tree().

The API has been implemented on libosinfo in order to be consistent with
what was already done for medias.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-07-16 16:54:30 -04:00
Fabiano Fidêncio
4d3b756e70 unattended: Use generate_*_for_tree()
Let's use generate_for_tree() and generate_command_line_for_tree()
methods whenever it's possible.

This method, similarly to generate_for_media() and
generate_command_line_for_media() will take an OsinfoTree as parameter
and will use its info in order to better decide how to properly generate
the install-script and kernel command-line.

It's important to mention that those APIs are part of libosinfo v1.6.0
release and that's the reason the check for them has been added.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-07-16 16:54:30 -04:00
Fabiano Fidêncio
6aa18520c6 unattended, installer: Pass _OsTree to prepare_install_script()
Later on, it'll be used to generate the install-script and the kernel
command-line based on the specific tree being used.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-07-16 16:54:30 -04:00
Fabiano Fidêncio
0a3dcdd1b9 installertreemedia: Add get_os_tree()
Let's allow to get the tree object from InstallerTreeMedia class.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-07-16 16:54:30 -04:00
Fabiano Fidêncio
5c494cef66 installertreemedia: Add os_tree to the _LocationData class
Let's get the _OsTree object and have it added to the _LocationData
class.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-07-16 16:54:30 -04:00
Fabiano Fidêncio
016cc1d866 urldetect: Add get_os_tree()
Let's add a method that allows the tree object to be retrieved from the
_DistroTree class.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-07-16 16:54:29 -04:00
Fabiano Fidêncio
6c15382847 urldetect: Store _OsTree object
As already done for _OsMedia, let's store the _OsTree object detected
as it'll be used later on in order to improve the installer script and
the kernel command line used for (tree based) unattended installations.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-07-16 16:54:29 -04:00
Fabiano Fidêncio
0e60a25066 osdict: Return a _OsTree instead of OsinfoTree when guessing an OS
Instead of returning an OsinfoTree, let's be consistent with what we
already do in guess_os_from_iso() and return our internal _OsTree
object.

This change doesn't affect any code as the only place using it doesn't
care about the returned tree object.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-07-16 16:54:29 -04:00
Fabiano Fidêncio
7fee11a29c osdict: Add _OsTree() class
Similarly to the _OsMedia() class, let's create a _OsTree() class which,
at least for now, has only one method that returns the OsinfoTree
object.

Although this class & method are not extrictly needed, having them makes
the code more consistent.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-07-16 16:54:29 -04:00
Cole Robinson
f4d62660f1 tests: Don't use the root logger
Stops logging spam from requests
2019-07-16 16:53:22 -04:00
Cole Robinson
0df8577e11 test_urls: dont try ftp:// with --force-libosinfo 2019-07-16 16:53:14 -04:00
Cole Robinson
3eeef679da test_urls: Remove dead mageia link 2019-07-16 16:53:08 -04:00
Athina Plaskasoviti
2b24a85884 cli: Add --clock timer[0-9]*.track, timer[0-9]*.mode, timer[0-9]*.frequency options
XML Mapping:

<clock>
...
  <timer track="X" mode="X" frequency="X"/>
...
</clock>

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Athina Plaskasoviti <athina.plaskasoviti@gmail.com>
2019-07-15 16:11:51 -04:00
Cole Robinson
a15770fbaf Fix codespell errors 2019-07-12 16:10:39 -04:00
Cole Robinson
0c223ab21f guest: Don't set default uefi if firmware= is set 2019-07-12 16:01:21 -04:00
Fabiano Fidêncio
e5980863dd unattended: Always set "media" as install-source for ISOs
Let's set "media" as installation source for all the ISOs, even the
net-installer ones, as this can be dealt with on osinfo-db side.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-07-12 15:07:22 -04:00
Fabiano Fidêncio
e775dd09f6 unattended: Use generate_*_for_media when possible
Let's use generate_for_media() generate_command_line_for_media() methods
whenever it's possible.

This method, differently from generate() and generate_command_line(),
will take an OsinfoMedia as parameter and will use its info in order to
better decide how to properly generate the install-script and the kernel
command-line.

It's important to mention that those APIs were released as part of
libosinfo v0.2.12, from May 26th, 2015. Knowing it's out for 4+ years
from the moment of this comment, I'm taken the path as not checking
whether the libosinfo used has this API or not.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-07-12 15:07:22 -04:00
Fabiano Fidêncio
a3b9d6ffc4 unattended: Pass OsinfoMedia to OSInstallScript
Let's pass the OsinfoMedia object down to the OSInstallScript class so
it can be used, later on, to generate the install-script and kernel
command-line specifically for the media being used.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-07-12 15:07:22 -04:00
Fabiano Fidêncio
224d29b799 osdict: Add get_osinfo_media() to _OsMedia class
Let's add a way to get the OsinfoMedia from the _OsMedia class. It's
going to be needed in order to properly generate the command line for
the unattended installations, when doing an installation from a media.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-07-12 15:07:22 -04:00
Fabiano Fidêncio
6d8bf5dff1 unattended: Simplify _generate_debug()
Instead of a creating a new Config object and setting and the needed
fields, let's just save the original user & admin passwords, set the
"[SCRUBBLED]" one for generating the debug output, and reset the
original values after that.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-07-12 15:07:22 -04:00
Cole Robinson
e678d94b45 tests: Add debian10 URL testing 2019-07-11 14:29:17 -04:00
Pavel Hrdina
3c6e85375d guest: fix warning message when machine type is changed for secure boot
Introduced by commit <3586d1897>.

Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1727811

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2019-07-08 10:57:46 +02:00
Cole Robinson
dbfdc099d8 Prep for release 2.2.1 2019-07-03 20:25:19 -04:00
Cole Robinson
aaa065d38e createpool: Add more coverage testing 2019-07-03 19:37:01 -04:00
Cole Robinson
616a7f2dd5 createpool: Simplify LVM volume group UI
Only show the volgroup name, and nothing else, which is all mostly
extraneous

https://bugzilla.redhat.com/show_bug.cgi?id=1316977
2019-07-03 19:37:01 -04:00
Cole Robinson
105553563a storage: Simplify source pool enumeration
Don't return an XML object stub, just return the relevant data.
Make it explicit that we currently are only supporting lvm
enumeration
2019-07-03 19:37:01 -04:00
Cole Robinson
4d86e1129b createpool: Add _get_visible_text helper 2019-07-03 19:37:01 -04:00
Cole Robinson
fd8847c24e storage: test default_target_path 2019-07-03 19:37:01 -04:00
Cole Robinson
199e9593bf storage: test default_source_name 2019-07-03 19:37:01 -04:00
Cole Robinson
f21d7e4c27 storage: Add explicit StoragePool.lookup_default_pool
Rather than adding an option to build_default_pool which is only
used in one location
2019-07-03 19:37:01 -04:00
Cole Robinson
67bb8fabdb storage: Drop redundant validation
libvirt catches most of this, and it's not all that useful to
duplicate it ourselves
2019-07-03 19:37:01 -04:00
Cole Robinson
9d7b20d3de storage: Add lots of coverage testing and exemptions 2019-07-03 19:37:01 -04:00
Cole Robinson
f64655a843 storage: Replace pool supports_property with supports_X
Makes usage more explicit, and easier to track for coverage testing
2019-07-03 19:37:01 -04:00
Cole Robinson
b8074b4505 storage: Replace volume supports_property with supports_format
Helps to make usage more explicit
2019-07-03 19:37:01 -04:00
Cole Robinson
657b2bcb26 storage: move supports_volume_creation to virtManager
It's the only user
2019-07-03 19:37:01 -04:00
Cole Robinson
4a0b7f61c8 storage: move pool pretty printing to virtManager
It's the only user
2019-07-03 19:37:01 -04:00
Fabiano Fidêncio
51d28f042b unattended: Don't log user & admin passwords
Logging user & admin passwords in the command-line is a security issue,
let's avoid doing so by:
- Not printing the values set by the user when setting up the
install-script config file;
- Removing the values used in the install-scripts, when printing their
content;

'CVE-2019-10183' has been assigned to the virt-install --unattended
admin-password=xxx disclosure issue.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-07-03 13:25:26 -04:00
Fabiano Fidêncio
58c6876450 unattended: Read the passwords from a file
Let's not expose the user/root password in the CLI and, instead, let's
rely on a file passed by the admin and read the password from there.

'CVE-2019-10183' has been assigned to the virt-install --unattended
admin-password=xxx disclosure issue.

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
2019-07-03 13:25:26 -04:00
Cole Robinson
5312a9611b virt-install: Revive --wait 0 as alias for --noautoconsole
This was the behavior prior to last release, and we received
a bug report about it. Revive it, but warn about the recommended way
to do it

https://bugzilla.redhat.com/show_bug.cgi?id=1724287
2019-07-03 13:12:19 -04:00
Cole Robinson
f3e7b9a8f0 cli: Finish off test coverage 2019-07-03 13:12:10 -04:00
Cole Robinson
3a1f10c6c5 cli: Remove warnings about spice and GL
libvirt catches the missing support here, and the warnings are not
accurate because these values can work with SDL and EGL headless.
2019-07-02 14:58:44 -04:00
Cole Robinson
afdb25e158 cli: Add more 'no cover' annotations 2019-07-02 14:58:44 -04:00
Cole Robinson
1277f5ebb1 clitest: Add non-testsuite virt-install stub
For hitting some logging code paths that are disabled for the
testsuite
2019-07-02 12:55:53 -04:00
Cole Robinson
5824cccf23 tests: test_urls: Add a fedora ftp:// example 2019-07-01 19:32:57 -04:00
Cole Robinson
6a1b0254bf diskbackend: Handle unexpected error from test_urls 2019-07-01 18:53:16 -04:00
Cole Robinson
2df7a6bab4 tests: test_urls: Actually test centos7 aarch64 2019-06-25 10:15:42 -04:00
Cole Robinson
2c49c3887c tests: test_urls: Better error report overwriting 2019-06-24 19:39:07 -04:00
Cole Robinson
267f226134 xmleditor: Fix the gtksource version checking
Previous commit was incomplete
2019-06-18 10:50:49 -04:00
Cole Robinson
e4b4834a58 uitests: newvm: More attempts to make the PXE test less flakey 2019-06-18 10:01:26 -04:00
Cole Robinson
cf04920211 INSTALL.md: We enforce python >= 3.4, not >= 3.3 2019-06-18 09:55:08 -04:00
Cole Robinson
876c0c014d INSTALL.md: Document dep on gtksourceview
https://bugzilla.redhat.com/show_bug.cgi?id=1721341
2019-06-18 09:55:01 -04:00
Cole Robinson
033e97021e xmleditor: Handle gtksourceview3 as well as gtksourceview4
API differences don't seem to affect our usage
2019-06-18 09:54:58 -04:00
Athina Plaskasoviti
b6563b90e5 cli: Add --numatune options memnode[0-9]*.cellid, memnode[0-9]*.mode, memnode[0-9]*.nodeset
XML Mapping:

<numatune>
...
  <memnode cellid="X" mode="X" nodeset="X"/>
...
</numatune>

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Athina Plaskasoviti <athina.plaskasoviti@gmail.com>
2019-06-17 17:41:25 -04:00
Andrea Bolognani
eda3c22458 guest: Add memory balloon by default
libvirt already does this for pretty much all QEMU guests, but
ARM virt guests for example don't get a memory balloon by default
at that level of the stack.

virt-manager is in a good position to make sure defaults are
consistent across architectures, and there's no downside in having
the device in the XML passed to libvirt anyway.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2019-06-17 13:52:07 -04:00
Andrea Bolognani
fb81adea7e cli: Add special treatment for --memballoon none
We want to start adding a memory balloon automatically to
guests, but we also need to make sure that it can be explicitly
disabled at the user's request.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2019-06-17 13:50:11 -04:00
Andrea Bolognani
72fc6781c8 osdict: Add supports_virtioballoon()
Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2019-06-17 13:50:11 -04:00
Andrea Bolognani
1502417566 tests: Add a couple of virt-xml memballoon tests
We're going to slightly change how the device is handled in
a minute, and we want to make sure we don't break existing
functionality while doing so.

Note that the existing singleton-config-* test cases already
provide coverage for both enabling and disabling the memory
balloon in virt-install.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
2019-06-17 13:50:11 -04:00
Cole Robinson
8c5e0797e5 tests: dist: Drop forbidden import test
It's broken, and in practice it has not turned out to be an issue
preventing gdk or gtk from leaking into virtinst
2019-06-17 13:32:55 -04:00
Cole Robinson
c92693a276 setup: Remove dep on importing virtinst
Import BuildConfig directly from the source file using import hackery.
buildconfig.py is independent of virtinst code so it already does
the right thing. Add some checking to make sure this doesn't regress
in the future.

Drop the now unneeded RPM deps.
2019-06-17 13:18:50 -04:00
Pavel Hrdina
d097e66324 spec: add build dependencies that are now required for build
Recent changes refactored a code in a whey that running setup.py
requires more python modules and we need to reflect that in our
spec file in order to build RPMs.

We should not need all of these as they are not used but that will
require a lot of code changes.  We should eventually fix it.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2019-06-17 12:08:34 +02:00
1031 changed files with 402179 additions and 300837 deletions

3
.codespellrc Normal file
View File

@ -0,0 +1,3 @@
[codespell]
ignore-words = tests/data/codespell_dict.txt
skip = *.pyc,*.iso,*.xml,*/po/*

View File

@ -1,7 +1,14 @@
[run]
source=virtinst/
[report]
skip_covered = yes
#omit=virtinst/_progresspriv.py
exclude_lines =
# Have to re-enable the standard pragma
pragma: no cover
# Don't complain if tests don't hit defensive assertion code:
raise NotImplementedError
.*DevError.*

43
.github/ISSUE_TEMPLATE/bug_report.md vendored Normal file
View File

@ -0,0 +1,43 @@
---
name: Bug report
about: Create a report to help us improve
---
<!--
If you are using distro provided packages and you have not confirmed
the bug exists in this repo with the latest code, then please file a
bug with your distro instead. Testing the code in this repo is
pretty easy, see CONTRIBUTING.md for details.
If your bug involves connecting to the VM graphical console, please
help us out and run through these debugging steps to help narrow
down where the issue may be:
https://github.com/virt-manager/virt-manager/wiki/Debugging-VM-graphical-display-issues
Thank you!
-->
**Describe the bug**
A clear and concise description of what the bug is.
**To Reproduce**
Steps to reproduce the behavior:
1. Go to '...'
2. Click on '...'
3. Run command '...'
4. See error
**Expected behavior**
A clear and concise description of what you expected to happen.
**Screenshots**
If applicable, add screenshots to help explain your problem.
**System (please complete the following information):**
- Distribution: [e.g. Fedora 40]
- virt-manager version:
- libvirt version:
**Additional context**
Add any other context about the problem here.

View File

@ -0,0 +1,25 @@
---
name: Feature request
about: Suggest an idea for this project
---
<!--
If you are requesting a feature or UI change, please read DESIGN.md
first, especially the section at the end about previously rejected
features.
Thank you!
-->
**Is your feature request related to a problem? Please describe.**
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
**Describe the solution you'd like**
A clear and concise description of what you want to happen.
**Describe alternatives you've considered**
A clear and concise description of any alternative solutions or features you've considered.
**Additional context**
Add any other context or screenshots about the feature request here.

9
.github/dependabot.yml vendored Normal file
View File

@ -0,0 +1,9 @@
version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
target-branch: "main"
commit-message:
prefix: "ci"

17
.github/workflows/black.yml vendored Normal file
View File

@ -0,0 +1,17 @@
name: Check code formatting with black
on:
pull_request:
workflow_dispatch:
push:
jobs:
black:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
- uses: pre-commit/action@v3.0.1
with:
extra_args: black --all-files

55
.github/workflows/ci.yml vendored Normal file
View File

@ -0,0 +1,55 @@
name: Test on fedora:latest
on: [push, pull_request]
jobs:
# Test on fedora:latest with stock distro packages
test:
runs-on: ubuntu-latest
container:
image: fedora:latest
steps:
- name: Install base RPM packages
run: |
# glibc-langpacks-en needed to work around python locale issues
# git-core needed for codecov/codecov-action
dnf install -y \
git-core \
rpm-build \
dnf-plugins-core \
glibc-langpack-en \
python3-pytest python3-pytest-cov
- uses: actions/checkout@v4
- name: Install RPM build deps
run: |
dnf install -y \
gettext \
python3-devel \
python3-docutils \
meson
- name: Build RPM and test install
run: |
git config --global --add safe.directory $PWD
meson setup build \
-Dupdate-icon-cache=false \
-Dcompile-schemas=false \
-Dtests=disabled
meson dist -C build
rpmbuild -tb build/meson-dist/virt-manager*.tar.xz
dnf install -y \
~/rpmbuild/RPMS/noarch/virt-install*.rpm \
~/rpmbuild/RPMS/noarch/virt-manager-common*.rpm
- name: Run test suite and generate coverage report
run: |
pytest --cov --cov-report=xml
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v5
with:
token: ${{ secrets.CODECOV_TOKEN }}

14
.github/workflows/codespell.yml vendored Normal file
View File

@ -0,0 +1,14 @@
name: Scan with codespell
on:
pull_request:
workflow_dispatch:
jobs:
codespell:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: codespell-project/actions-codespell@v2

View File

@ -0,0 +1,63 @@
name: Test against libvirt.git
on:
# Run every 3 days at midnight
schedule:
- cron: '0 0 */3 * *'
jobs:
test-against-libvirt-git:
# Only run this if on the main 'virt-manager/virt-manager' repo, not forks
if: "contains(github.repository, 'virt-manager/virt-manager')"
runs-on: ubuntu-latest
container:
image: fedora:latest
steps:
- name: Install RPM build and libvirt deps
run: |
# glibc-langpacks-en needed to work around python locale issues
dnf install -y \
rpm-build \
dnf-plugins-core \
glibc-langpack-en \
python3-pytest \
python3-pytest-error-for-skips
dnf install -y \
gettext \
python3-devel \
python3-docutils \
meson
dnf builddep -y libvirt
- uses: actions/checkout@v4
- name: Build RPM and test install
run: |
git config --global --add safe.directory $PWD
meson setup build \
-Dupdate-icon-cache=false \
-Dcompile-schemas=false \
-Dtests=disabled
meson dist -C build
rpmbuild -tb build/meson-dist/virt-manager*.tar.xz
dnf install -y \
~/rpmbuild/RPMS/noarch/virt-install*.rpm \
~/rpmbuild/RPMS/noarch/virt-manager-common*.rpm
- name: checkout and build libvirt
run: |
git clone --depth=1 https://gitlab.com/libvirt/libvirt
cd libvirt
meson build
ninja -C build
cd ..
- name: Run test suite
run: |
# Treat any `skips` as `errors`. We should only be
# skipping tests on old libvirt versions
./libvirt/build/run pytest --error-for-skips

68
.github/workflows/translations.yml vendored Normal file
View File

@ -0,0 +1,68 @@
name: Translations
on:
schedule:
# Implicitly runs on default branch
# every two days at 6:00 UTC
- cron: '0 6 */2 * *'
jobs:
# This job will run meson compile -C build virt-manager-pot on top of git main
# and force push that to the 'translations' branch. That branch will
# always have an up to date .pot file for use in weblate
update-translation-pot:
# Only run this if on the main 'virt-manager/virt-manager' repo, not forks
if: "contains(github.repository, 'virt-manager/virt-manager')"
runs-on: ubuntu-latest
container:
image: fedora:latest
steps:
- name: Install deps
run: |
dnf install -y \
git \
diffutils \
gettext \
python3-devel \
python3-docutils \
meson
- uses: actions/checkout@v4
with:
# This fetches full git history. We need that for proper
# branch updating
fetch-depth: 0
- name: Extract messages and push to translations branch
run: |
git config --global user.email "actions@github.com"
git config --global user.name "Github Actions"
git fetch --all
git rebase remotes/origin/translations
cp po/virt-manager.pot old.pot
meson setup build \
-Dupdate-icon-cache=false \
-Dcompile-schemas=false \
-Dtests=disabled
meson compile -C build virt-manager-pot
ec=0
diff -q -I 'POT-Creation-Date' old.pot po/virt-manager.pot || ec=$?
case "${ec}" in
0) ;;
1)
git commit po/virt-manager.pot \
--message "Refresh translation .pot template"
remote_repo="https://${GITHUB_ACTOR}:${{ secrets.GITHUB_TOKEN }}@github.com/${GITHUB_REPOSITORY}.git"
git push "${remote_repo}" HEAD:translations
;;
*)
echo "diff failed with exit status ${ec}" >&2
exit 1
;;
esac

12
.gitignore vendored
View File

@ -3,19 +3,9 @@
*.gmo
/build
/dist
po/virt-manager.pot
/.coverage
/MANIFEST
/data/gschemas.compiled
/man/virt-manager.1
/man/virt-install.1
/man/virt-clone.1
/man/virt-convert.1
/man/virt-xml.1
/virt-manager.spec
/virtinst/build.cfg
/coverage.xml

View File

@ -1,4 +0,0 @@
[gitpublishprofile "default"]
base = master
to = virt-tools-list@redhat.com
prefix = virt-manager PATCH

View File

@ -1,9 +1,15 @@
Alexander Todorov <alexx@redbull.brq.redhat.com>
Cole Robinson <root@crobinso1.boston.redhat.com>
Daniel P. Berrange <berrange@roquette.boston.redhat.com>
Daniel P. Berrange <berrange@dhcp-4-245.virt.boston.redhat.com>
Daniel P. Berrange <berrange@dhcp-5-251.virt.boston.redhat.com>
Daniel P. Berrange <berrange@localhost.localdomain>
Guido Günther <agx@sigxcpu.org>
Hugh O. Brock <hbrock@puck.indigologic.com>
Athina Plaskasoviti <athina.plaskasoviti@gmail.com>
Daniel P. Berrangé <berrange@redhat.com>
Chen Hanxiao <chenhanxiao@cn.fujitsu.com>
Guido Günther <agx@sigxcpu.org>
Radostin Stoyanov <rstoyanov1@gmail.com>
Alexander Todorov <atodorov@redhat.com> <alexx@redbull.brq.redhat.com>
Cole Robinson <crobinso@redhat.com> <root@crobinso1.boston.redhat.com>
Daniel P. Berrangé <berrange@redhat.com> <berrange@localhost.localdomain>
Daniel P. Berrangé <berrange@redhat.com> <berrange@roquette.boston.redhat.com>
Daniel P. Berrangé <berrange@redhat.com> <berrange@dhcp-5-251.virt.boston.redhat.com>
Daniel P. Berrangé <berrange@redhat.com> <berrange@dhcp-4-245.virt.boston.redhat.com>
Daniel P. Berrangé <berrange@redhat.com> <dan@berrange.com>
Hugh Brock <hbrock@redhat.com> <hbrock@puck.indigologic.com>

25
.packit.yaml Normal file
View File

@ -0,0 +1,25 @@
# See the documentation for more information:
# https://packit.dev/docs/configuration/
upstream_package_name: virt-manager
downstream_package_name: virt-manager
specfile_path: build/virt-manager.spec
srpm_build_deps:
- gettext
- python3-devel
- python3-docutils
- meson
actions:
post-upstream-clone:
- meson setup build -Dupdate-icon-cache=false -Dcompile-schemas=false -Dtests=disabled
jobs:
- job: copr_build
# Run on every PR
trigger: pull_request
# Defaults to x86_64 unless architecture is explicitly specified
targets:
- fedora-all

10
.pre-commit-config.yaml Normal file
View File

@ -0,0 +1,10 @@
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0
hooks:
- id: check-yaml
- repo: https://github.com/psf/black
rev: 25.1.0
hooks:
- id: black

View File

@ -3,13 +3,15 @@
# can either give multiple identifier separated by comma (,) or put this option
# multiple time (only on the command line, not in the configuration file where
# it should appear only once).
disable=Design,Similarities,invalid-name,missing-docstring,line-too-long,too-many-lines,superfluous-parens,bad-whitespace,locally-disabled,no-self-use,unnecessary-lambda,star-args,fixme,global-statement,bare-except,anomalous-backslash-in-string,broad-except,cyclic-import,bad-continuation,locally-enabled,unidiomatic-typecheck,redefined-variable-type,bad-option-value,wrong-import-position,consider-using-ternary,no-else-return,len-as-condition,inconsistent-return-statements,useless-object-inheritance,consider-using-in,useless-return,assignment-from-none,chained-comparison
disable=Design,Similarities,invalid-name,missing-docstring,line-too-long,too-many-lines,superfluous-parens,bad-whitespace,locally-disabled,no-self-use,unnecessary-lambda,star-args,fixme,global-statement,bare-except,anomalous-backslash-in-string,broad-except,cyclic-import,bad-continuation,locally-enabled,unidiomatic-typecheck,redefined-variable-type,bad-option-value,wrong-import-position,consider-using-ternary,no-else-return,len-as-condition,inconsistent-return-statements,useless-object-inheritance,consider-using-in,useless-return,assignment-from-none,chained-comparison,import-outside-toplevel,use-a-generator,consider-using-with,consider-using-f-string,unspecified-encoding,use-maxsplit-arg,possibly-used-before-assignment
enable=fixme
[MASTER]
# Don't pickle any data for cross run comparison reports
persistent=no
# Make sure pylint checks against gtk3
init-hook="import gi; gi.require_version('Gtk', '3.0')"
[REPORTS]
@ -29,5 +31,5 @@ dummy-variables-rgx=_+$|(_[a-zA-Z0-9_]*[a-zA-Z0-9]+?$)|dummy|^ignored_|^unused_|
# This is the standard argument regex, with two 'ignore' variations added
ignored-argument-names=_.*|^ignored_|^unused_|ignore.*|.*_ignore
# gettext function _() is built in
additional-builtins=_
# gettext builtins
additional-builtins=_,ngettext

View File

@ -1,22 +1,32 @@
# Contribute to virt-manager
## Run code from git
Generally virt-* tools can be run straight from git. For example
for virt-manager:
```
git clone https://github.com/virt-manager/virt-manager
cd virt-manager
./virt-manager --debug
```
The other tools like `virt-install` should work similarly. This
expects you already have a distro provided version of virt-manager
installed which pulled in all the necessary dependencies. If not,
see [INSTALL.md](INSTALL.md) for more hints about finding the
correct dependencies.
## Bug reporting
The preferred place for bug reports is bugzilla.redhat.com. This
is documented more at https://virt-manager.org/bugs/
Bug reports should go to our [github issue tracker](https://github.com/virt-manager/virt-manager/issues).
Small issues can be reported in the
[github issue tracker](https://github.com/virt-manager/virt-manager/issues).
Anything that's non-trivial, or is a feature request, should be filed in
bugzilla.
The bug tracker is for issues affecting the latest code only.
If you are using a distro provided package like from Ubuntu or
Fedora, please file a bug in their bug tracker.
Please only file issues if they apply to the latest version of
virt-manager. If you are using an older version from a distro,
please file a bug with them.
When filing a bug, please reproduce the issue with the `--debug`
flag passed to the tool and attach the full output in the bug
report.
If you suspect the bug also affects upstream code, please confirm
it by running the latest code using the steps above.
## Writing patches
@ -24,20 +34,25 @@ report.
The following commands will be useful for anyone writing patches:
```sh
./setup.py test # Run local unit test suite
./setup.py pylint # Run pylint/pycodestyle checking
meson test -C build
```
Any patches shouldn't change the output of 'test' or 'pylint'. Depending
Any patches shouldn't change the output of 'pytest' or 'pylint'. Depending
on what version of libvirt or pylint is installed, you may see some
pre-existing errors from these commands. The important thing is that
any changes you make do not add additional errors.
The 'pylint' command requires [`pylint`](https://github.com/PyCQA/pylint)
and [`pycodestyle`](https://github.com/pycqa/pycodestyle) to be installed.
The 'test' command requires [`pylint`](https://github.com/PyCQA/pylint),
[`pycodestyle`](https://github.com/pycqa/pycodestyle) and
['pytest'](https://github.com/pytest-dev/pytest/) to be installed.
If [`codespell`](https://github.com/codespell-project/codespell) is installed,
it will be invoked as well.
Patches to `virtinst/` code should ideally not regress code coverage
testing. Run `pytest --cov` to see a coverage report
before and after your contribution, and ensure no new lines show up.
Maintainers can help you out if you aren't sure how to test your code.
One useful way to manually test virt-manager's UI is using libvirt's
unit test driver. From the source directory, Launch virt-manager like:
```sh
@ -64,12 +79,16 @@ UI. See the files in the ui/ directory.
## Submitting patches
The [virt-manager git repo](https://github.com/virt-manager/virt-manager)
is hosted on github. Small patches are acceptable via github pull-request,
but anything non-trivial should be sent to the
[virt-tools-list mailing list](https://www.redhat.com/mailman/listinfo/virt-tools-list).
is hosted on github. All patches should be submitted there.
Sending patches using `git send-email` is preferred, but `git format-patch`
output attached to an email is also fine.
## UI design
If you are planning to add a feature to virt-manager's UI, please read
[DESIGN.md](DESIGN.md) first. Features that do not fit the goals specified
in that document may be rejected. If you are unsure if your feature is a
good fit for virt-manager, please ask on the mailing list before you start
coding!
## Introductory tasks
@ -82,11 +101,14 @@ that still need to be added to our command line.
## Translations
Translations are handled at `fedora.zanata.org`. Please register for a Fedora
account and request access to a translation team, as described at
[Translate on Zanata](https://fedoraproject.org/wiki/L10N/Translate_on_Zanata),
and contribute at
[virt-manager at Zanata](https://fedora.zanata.org/project/view/virt-manager/).
Translations are handled through the Weblate instance hosted by the Fedora Project.
* https://translate.fedoraproject.org/projects/virt-manager/virt-manager/
* More info about translating as part of Fedora: https://fedoraproject.org/wiki/L10N/Translate_on_Weblate
* The up to date translation `.pot` template is stored in the `main` branch
* Translations are submitted by Weblate as pull requests, usually merged to the
`main` branch before release and whenever needed (e.g. before updating the
`.pot` template)
## Advanced testing
@ -94,9 +116,10 @@ and contribute at
There's a few standalone specialty tests:
```sh
./setup.py test_ui # dogtail UI test suite. This takes over your desktop
./setup.py test_urls # Test fetching media from live distro URLs
./setup.py test_initrd_inject # Test live virt-install --initrd-inject
pytest --uitests # dogtail UI test suite. This takes over your desktop
pytest tests/test_urls.py # Test fetching media from live distro URLs
pytest tests/test_inject.py # Test live virt-install --initrd-inject
```
All test 'test*' commands have a `--debug` option if you are hitting problems. For more options, see `./setup.py test --help`.
To see full debug output from test runs, use
`pytest --capture=no --log-level=debug ...`

14
COPYING
View File

@ -1,12 +1,12 @@
GNU GENERAL PUBLIC LICENSE
Version 2, June 1991
GNU GENERAL PUBLIC LICENSE
Version 2, June 1991
Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
Preamble
Preamble
The licenses for most software are designed to take away your
freedom to share and change it. By contrast, the GNU General Public
@ -56,7 +56,7 @@ patent must be licensed for everyone's free use or not licensed at all.
The precise terms and conditions for copying, distribution and
modification follow.
GNU GENERAL PUBLIC LICENSE
GNU GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. This License applies to any program or other work which contains
@ -255,7 +255,7 @@ make exceptions for this. Our decision will be guided by the two goals
of preserving the free status of all derivatives of our free software and
of promoting the sharing and reuse of software generally.
NO WARRANTY
NO WARRANTY
11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
@ -277,9 +277,9 @@ YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
POSSIBILITY OF SUCH DAMAGES.
END OF TERMS AND CONDITIONS
END OF TERMS AND CONDITIONS
How to Apply These Terms to Your New Programs
How to Apply These Terms to Your New Programs
If you develop a new program, and you want it to be of the greatest
possible use to the public, the best way to achieve this is to make it

140
DESIGN.md Normal file
View File

@ -0,0 +1,140 @@
## virt-manager UI design philosophy
**virt-manager** is a UI toolbox-style frontend for libvirt. It provides UI access to common virt management tasks and operations. virt-manager aims to provide a simple UI, but not too simple that it excludes valid usecases. virt-manager prioritizes stability over features. Given the user definitions defined below, our goals are:
* **_Basic virt users_** should be able to meet their needs with virt-manager.
* **_Intermediate virt users_** should find virt-manager sufficiently flexible for their needs.
* **_Advanced virt users_** will not find explicit UI support for their advanced use cases, but virt-manager should still function correctly in the face of their manually configured advanced virt usage. virt-manager should not get in their way.
Here are some things that virt-manager explicitly is not:
* **gnome-boxes**: a heavily desktop integrated VM manager with an emphasis on UI design and simplifying virt management. They prioritize a seamless designed experience over flexibility, our goals are different.
* **virt-viewer/remote-viewer**, **vncviewer**: our graphical VM window should 'just work' for most needs but any advanced console configuration is left up to these other better suited tools.
* **VirtualBox**, **VMWare Workstation**: It's a nice idea to aim to be the equivalent of those apps for the QEMU+KVM+Libvirt stack. But to get there would require a level of resource investment that is unlikely to ever happen.
* **oVirt**, **Openstack**: virt-manager does not aim to support management of many hosts with many VMs. virt-manager won't reject this case and we try within reason to keep it working. But the UI is not designed for it and we will not change the UI to facilitate these style of usecases.
## How do we evaluate UI changes
When is it worth it to expose something in the UI? Here's some criteria we will use:
* **How many users do we expect will use it**: This is handwavy of course but some things come up in email/IRC discussion regularly, and some are mentioned once in 5 years.
* **How critical is it for users who need/want it**: if it's an absolute blocker just to get a working config for some people, that can influence the discussion
* **How self explanatory is the feature**: 'Enable 3D acceleration' is fairly self explanatory. Disk io native vs threads, not so much.
* **How dangerous or difficult to use is the feature**: If it works in only specific cases or renders the VM unbootable for certain scenarios, this matters.
* **How much work is it to maintain, test**
* **How much work is it to implement**: If something requires significant app specific logic on top of libvirt, libosinfo, or spice-gtk that would also be useful to other virt apps, it is suspect. We should be aiming to share common functionality
## User definitions
### Basic virt user
They know little or nothing about libvirt, qemu, and kvm, but they understand the high level concept of a virtual machine. They have a Windows or Linux distro ISO and they want to create a VM and interact with it graphically. They should be able to figure out how to do that by running virt-manager and following the UI. The defaults we provide for new VMs should be sufficient for their needs.
After the VM is installed, the UI should facilitate intuitive UI tasks like:
* lifecycle operations: start/stop/pause the VM; save, snapshot the VM; delete, clone the VM
* rename the VM; change the VM title or description
* eject/insert CDROM media; change VM boot order
* increase VM memory
* attach a host USB device to the VM; possibly add an additional disk to the VM
* graphical operations like send a keycombo, screenshot
### Intermediate virt user
They know more about virt in general but we do not assume they have ever edited libvirt XML or run the qemu command line. They are a more intermediate tech user anyways. They may know about less standard virt features and they want to enable them for their VMs. Or they are using VMs as part of a specific workflow, possibly for a development environment, or hosting personal services on their own network, or managing VMs on a remote host. This is the fuzzy area. We want to support these people but each request needs to be handled on a case by case basis.
Here's some of the things the current UI supports that fit this bucket:
* Management of remote virt hosts
* Management of non-qemu/kvm libvirt drivers: lxc, vz, xen, bhyve
* Support for non-x86 VM creation: aarch64, armv7l, ppc64, s390x
* Change VM CPU model or mode
* UEFI config for new VMs
* VM direct kernel/initrd boot
* VM serial console access
* VM use of network bridge or macvtap
* Spice/virgl 3D acceleration usage
* Libvirt storage pool management
* Libvirt virtual network management
* Ideally every VM UI edit operation should be justifiable in this context
### Advanced virt user or usecase
An advanced virt user likely has some experience with libvirt XML or the qemu command line. They may know that they need some specific libvirt XML value for their VMs. They may be running virt in an environment that depends on non-trivial non-standard host configuration.
We want virt-manager to still be useful to these users for fulfilling basic and intermediate needs, but not get in the way or prevent usage of their advanced config, within reason.
Some examples:
* **usecase**: managing many hosts and many VMs
* **usecase**: require tweaking anything but the most standard <domain> performance options
* **usecase**: generally anything that requires special host or guest configuration outside virt-manager
* **user**: Generally anybody that knows the qemu command line or specific XML config options they want
## Previously rejected/removed UI elements
* VM properties
* [disk driver io=threads|native](https://github.com/virt-manager/virt-manager/commit/a162a3b845eee24f66baf63b3aeb82523b274b0d)
* [disk scsi reservations](https://github.com/virt-manager/virt-manager/commit/b583ea7e66cd0b7117971cf55365355f78dd3670)
* [disk detect_zeroes](https://github.com/virt-manager/virt-manager/commit/8377b7f7b69ed0716fbe2c2818979a273bcb7567)
* [graphics spice TLS port](https://github.com/virt-manager/virt-manager/commit/bd82ef65292cc47cffc27b8f67d7987679c61bf3)
* [graphics keymap selection](https://github.com/virt-manager/virt-manager/commit/7251ea25c2936b69284366abc787f1b33c199b15)
* [network virtualport](https://github.com/virt-manager/virt-manager/commit/b4b497e28f3f3e32a05f4cf78c21f07022ee824b)
* [Any explicit `<clock>`/`<timer>` config](https://www.redhat.com/archives/virt-tools-list/2019-January/thread.html#00041)
* [Raw `<genid>` config](https://www.redhat.com/archives/virt-tools-list/2019-April/msg00001.html)
* [Fine grained `<cpu><feature>` config](https://www.redhat.com/archives/virt-tools-list/2014-January/msg00180.html)
* [Host network management via libvirt interface APIs](https://blog.wikichoon.com/2019/04/host-network-interfaces-panel-removed.html)
* [VM hugepages/hugetlbfs](https://bugzilla.redhat.com/show_bug.cgi?id=1688641)
* Most VM tuning: `<cputune>`, `<blkiotune>`, `<numatune>`, fine grained `<vcpus>` listing
* Editing existing machine type/arch/ostype, UEFI config. Only advanced users can make it work, and they can edit the XML.
* Defaults
* [Defaulting to sky high maxmem and maxvcpus](https://github.com/virt-manager/virt-manager/issues/141)
* Tight desktop integration stuff: registering as a default file handler, registering as a gnome search provider, etc. This is gnome-boxes territory
* Serial console config options like [buffer scrollback size](https://bugzilla.redhat.com/show_bug.cgi?id=1610165). Use `virsh console` or cli tools if need flexibility.
* Advanced VNC/SPICE viewer config. virt-viewer should be the target app
* VNC bit depth config
* advanced mouse/keyboard grab support
* advanced SPICE viewer options
* [hiding viewer window borders/decorations](https://www.redhat.com/archives/virt-tools-list/2019-January/msg00000.html) [(and another)](https://github.com/virt-manager/virt-manager/pull/233)
* [hiding window menu bar](https://bugzilla.redhat.com/show_bug.cgi?id=1091311)
* [keypress delay](https://bugzilla.redhat.com/show_bug.cgi?id=1410943)
* [SPICE/QXL multidisplay support](https://bugzilla.redhat.com/show_bug.cgi?id=885806)
* support for [manual key combinations](https://bugzilla.redhat.com/show_bug.cgi?id=1014666), or adding custom values.
* Any feature that goes beyond what virt-viewer or other clients provide. virt-manager should not be the home for clever console/viewer behavior
* UI scalability features to manage large amounts of VMs
* [custom manager columns for VM organizing](https://www.redhat.com/archives/virt-tools-list/2019-April/msg00059.html)
* [organizing VMs into collections/groups](https://bugzilla.redhat.com/show_bug.cgi?id=1193303) ([and another](https://bugzilla.redhat.com/show_bug.cgi?id=1548879))
* multiselect operations on VMs/other objects ([like storage](https://bugzilla.redhat.com/show_bug.cgi?id=1698879))
* hiding offline VMs or other view options
* [Advanced VM name search support](https://github.com/virt-manager/virt-manager/issues/147). Note: GTK provides some support already: in the manager window, CTRL+F to open a searchbox, searches match from the beginning of VMs only, use arrow keys to jump between matches. Use VM 'title' field to customize how it is named in the manager window.
## Use of the bug tracker
We plan to keep open bugs only for:
* bugs/problems that are actively affecting users, which the developers plan to fix eventually.
* features/improvements that the developers plan to implement eventually.
The bug tracker will not be used as a wishlist. Users are free to
file RFEs there, but they may be closed.
* A feature/enhancement request that does not match the design guidelines, will be CLOSED->WONTFIX, with an explanation
* A feature/enhancement request that would be nice to have but the developers do not plan to fix, will be CLOSED->DEFERRED, with an explanation.
## References
* [The original mailing list thread for this document](https://www.redhat.com/archives/virt-tools-list/2019-June/msg00108.html)
* [Follow on discussion about some feature removals](https://www.redhat.com/archives/virt-tools-list/2019-June/msg00117.html), [and a follow up](https://www.redhat.com/archives/virt-tools-list/2019-July/msg00005.html)

View File

@ -6,35 +6,29 @@ changes, it can be done from the source directory:
./virt-manager
```
For more details on that, see [CONTRIBUTING.md](CONTRIBUTING.md)
To install the software into `/usr/local` (usually), you can do:
```sh
./setup.py install
meson setup build
meson install -C build
```
To build an RPM, you can run:
```sh
./setup.py rpm
```
`setup.py` generally has all the build and install commands, for more info see:
- `./setup.py --help-commands`
- `./setup.py install --help`
- [Python Standard Build and Install](https://docs.python.org/3/install/#standard-build-and-install)
## Pre-requisite software
A detailed dependency list can be found in
[virt-manager.spec.in](virt-manager.spec.in) file.
A detailed dependency list can be found in [virt-manager.spec.in](virt-manager.spec.in) file.
Minimum version requirements of major components:
- python >= 3.3
- gettext >= 0.19.6
- python >= 3.4
- gtk3 >= 3.22
- libvirt-python >= 0.6.0
- pygobject3 >= 3.22
- pygobject3 >= 3.31.3
- libosinfo >= 0.2.10
- gtksourceview >= 3
On Debian or Ubuntu based distributions, you need to install the
`gobject-introspection` bindings for some dependencies like `libvirt-glib`

View File

@ -1,15 +0,0 @@
# to be included/excluded from the tarball produced by sdist
include COPYING CONTRIBUTING.md INSTALL.md NEWS.md README.md
include MANIFEST.in
include setup.py
include virt-*
recursive-include data *
exclude data/gschemas.compiled
recursive-include man *
recursive-include po *
recursive-include tests *
recursive-include ui *
recursive-include virtManager *
recursive-include virtconv *
recursive-include virtinst *
global-exclude *.pyc

129
NEWS.md
View File

@ -1,5 +1,120 @@
# Virtual Machine Manager News
## Release 5.0.0 (November 26, 2024)
- virt-clone: colne serial files (Oleg Vasilev)
- virt-clone: Copy disk permissions as well (Martin Kletzander)
- virt-install: Add properties for AMD SEV-SNP (Daniel P. Berrangé)
- virt-install: Add passt backend for user network interface
- virt-install: Add support for --sound multichannel,stream (Lin Ma)
- virt-install: Add support for --tpm backend.debug,backend.source (Lin Ma)
- virt-xml: add --edit --convert-to-q35
- virt-xml: add --edit --convert-to-vnc
- virt-xml: Add --edit --boot uefi
- virt-manager: Fix opening graphical console with egl-headless (Feng Jiang)
- virt-manager: Add support to create external snapshots
- virt-manager: Default to scaling=Always for consoles
- virt-manager: switch to not forking by default
- cli: Add more --disk options (Lin Ma)
- cli: Add --memdev target.address_base for virtio-mem and virtio-pmem (Lin Ma)
- cli: Add --features kvm.pv-ipi.state=on|off (Lin Ma)
- cli: Add --video model.blob=on|off (Lin Ma)
- Add missing Hyper-V features and enable most of them by default
- Add loongarch support (Xianglai Li)
- Add support for hvf domain type (Mohamed Akram)
- Support creating sparse volumes on ZFS pools (Iain Buclaw)
- UEFI improvements for riscv64 and loongarch64 VMs (Andrea Bolognani)
- Add graphics to riscv64 and aarch64
- build: switch from setuptools to meson
- diskbackend: Drop support for sheepdog (Lin Ma)
- cli: Deprecate --cpu host in favor of --cpu host-model (Andrea Bolognani)
## Release 4.1.0 (August 04, 2022)
- Fix build with setuptools-61 (Peter Alfredsen, Miro Hrončok)
- add UI and cli support for qemu-vdagent channel (Jonathon Jongsma)
- cli: More --iothreads suboptions (Lin Ma)
- launch_security: Use SEV-ES policy=0x07 if host supports it (Charles
Arnold)
- cli: Add support for URL query with disks (Martin Kletzander)
## Release 4.0.0 (March 02, 2022)
- virt-install --os-variant/--osinfo is now a hard requirement for most
cases
- Add 'Enable shared memory' UI checkbox (Lin Ma)
- add UI preference to default to UEFI for new VMs (Charles Arnold)
- Add virtiofs filesystem driver UI option
- Fill in all --cputune, --cpu, --shmem, --input, and --boot suboptions
(Hugues Fafard)
- virt-* mdev improvements (Shalini Chellathurai Saroja)
- bhyve improvements (Roman Bogorodskiy)
- Revive network portgroup UI
- enable a TPM by default when UEFI is used (Daniel P. Berrangé)
- Use cpu host-passthrough by default on qemu x86
- use virtio-gpu video for most modern distros
- Default to extra pcie root ports for q35
- set discard=unmap by default for sparse disks and block devices
- We now require xorissofs for --location ISO
- We now use setuptools rather than just plain distutils
## Release 3.2.0 (November 14, 2020)
- Slim down filesystem device editor UI
- Fix TOCTTOU virt-install bugs (Martin Pitt)
- Several other bug fixes
## Release 3.1.0 (September 30, 2020)
- Return to using qcow2 sparse by default with libvirt 5.0.0+
- Make VM window shortcuts less likely to conflict with guest usage
- Fix 3.0.0 regression with spice audio
- createvol: Add explicit option for qcow2 non-sparse
- Unconditionally add USB redirdev to new VMs when using SPICE
- Unconditionally add sound devices to new VMs
- Translation string improvements (Pino Toscano)
## Release 3.0.0 (September 15, 2020)
- virt-install --cloud-init support (Athina Plaskasoviti, Cole Robinson)
- The virt-convert tool has been removed. Please use virt-v2v instead
- A handful of UI XML configuration options have been removed. The XML
editor can be used instead. For a larger discussion see this thread:
https://www.redhat.com/archives/virt-tools-list/2019-June/msg00117.html
- The 'New VM' UI now has a 'Manual Install' option which creates a VM
without any required install media
- In the 'New VM' UI, the network/pxe install option has been removed. If
you need network boot, choose 'Manual Install' and set the boot device after
initial VM creation
- 'Clone VM' UI has been reworked and simplified
- 'Migrate VM' UI now has an XML editor for the destination VM
- Global and per-vm option to disable graphical console autoconnect. This
makes it easier to use virt-manager alongside another client like virt-
viewer
- virt-manager: set guest time after VM restore (Michael Weiser)
- virt-manager: option to delete storage when removing disk device (Lily
Nie)
- virt-manager: show warnings if snapshot operation is unsafe (Michael
Weiser)
- Unattended install improvements (Fabiano Fidêncio)
- cli: new --xml XPATH=VAL option for making direct XML changes
- virt-install: new --reinstall=DOMAIN option
- virt-install: new --autoconsole text|graphical|none option
- virt-install: new --os-variant detect=on,require=on suboptions
- cli: --clock, --keywrap, --blkiotune, --cputune additions (Athina
Plaskasoviti)
- cli: add --features kvm.hint-dedicated.state= (Menno Lageman)
- cli:--iommu option (Menno Lageman)
- cli: Add --graphics websocket= support (Petr Benes)
- cli: Add --disk type=nvme source.* suboptions
- cli: Fill in all --filesystem suboptions
- Translation string improvements (Pino Toscano)
- Convert from .pod to .rst for man pages
- Switch to pytest as our test runner
- Massively improved unittest and uitest code coverage
- Now using github issues as our bug tracker
## Release 2.2.1 (July 03, 2019)
- CVE-2019-10183: Replace --unattended user-password and admin-password with
user-password-file and admin-password-file (Fabiano Fidêncio)
- Consistent --memballoon default across non-x86 (Andrea Bolognani)
- virt-install: add --numatune memnode.* (Athina Plaskasoviti)
- Drop hard dep on gtksourceview4, gtksourceview3 is fine as well
## Release 2.2.0 (June 17, 2019)
- libvirt XML viewing and editing UI for new and existing domain, pools,
volumes, networks
@ -172,7 +287,7 @@
- OVMF/AAVMF Support (Laszlo Ersek, Giuseppe Scrivano, Cole Robinson)
- Improved support for AArch64 qemu/kvm
- virt-install: Support `--disk type=network` parameters
- virt-install: Make `--disk` just work
- virt-install: Make `--disk` just work
- virt-install: Add `--disk sgio=` option (Giuseppe Scrivano)
- addhardware: default to an existing bus when adding a new disk
(Giuseppe Scrivano)
@ -293,7 +408,7 @@
- Allow renaming an offline VM
- Spice password support (Marc-André Lureau)
- Allow editting NIC `<virtualport>` settings (Gerhard Stenzel)
- Allow editing NIC `<virtualport>` settings (Gerhard Stenzel)
- Allow enabling/disabling individual CPU features
- Allow easily changing graphics type between VNC and SPICE for existing
VM
@ -457,7 +572,7 @@ now tunnel connections to the VNC server over SSH. It avoids prompting
for SSH passwords on the console. Handling of VNC connections & retries
is made more robust. There is support for changing CDROM media on the
fly (requires suitably updated libvirt). There is ability to PXE boot
install fullyvirtualized guests. Connetions to hypervisors are opened
install fullyvirtualized guests. Connections to hypervisors are opened
in the background to avoid blocking the whole UI.
## Release 0.5.0
@ -465,7 +580,7 @@ in the background to avoid blocking the whole UI.
This release introduces the ability to manage multiple remote machines,
using either SSH+public keys, or TLS+x509 certificates to connect and
authenticate. The main user interface is re-worked to show multiple
hosts in a tree view, remebering connections across restarts. It is
hosts in a tree view, remembering connections across restarts. It is
not currently possible to create new guests with a remote host connection.
This capability will be added in a future release. The guest VNC console
implementation has been replaced with the GTK-VNC widget for greatly
@ -492,7 +607,7 @@ to the hypervisor.
The release introduces online help for all windows / dialogs in the
application, to explain usage & operation of key functions. Auto-popup
of consoles was fixed for existing inactive domains. Additional control
operations are available on the right-click menu in the VM list. A
operations are available on the right-click menu in the VM list. A
handful of other minor bug fixes are also applied.
## Release 0.3.1
@ -530,8 +645,8 @@ the UI in approximately 20 languages - thanks to the Fedora i18n
team for excellent progress on this. It is now possible to control
the virt-manager UI with command line arguments as well as the DBus
API & it DBus activation is no longer used by default which fixes
interaction with GNOME keyring & AT-SPI accesibility. Numerous
UI issues were fixed / clarified, particularly in the graphical
interaction with GNOME keyring & AT-SPI accessibility. Numerous
UI issues were fixed / clarified, particularly in the graphical
console and new VM creation wizard.

View File

@ -10,7 +10,6 @@ Several command line tools are also provided:
- `virt-install`: Create new libvirt virtual machines
- `virt-clone`: Duplicate existing libvirt virtual machines
- `virt-xml`: Edit existing libvirt virtual machines/manipulate libvirt XML
- `virt-convert`: Convert VMX or OVF configs to libvirt virtual machines
For dependency info and installation instructions, see the
[INSTALL.md](INSTALL.md) file. If you just want to quickly test the
@ -22,9 +21,6 @@ code from a git checkout, you can launch any of the commands like:
## Contact
- All comments / suggestions / patches should be directed to the
[virt-tools-list](https://www.redhat.com/mailman/listinfo/virt-tools-list)
mailing list.
- For IRC we use #virt on OFTC.
- For bug reporting info, see
[virt-manager bug reporting](https://virt-manager.org/bugs).

View File

@ -1,5 +1,3 @@
#!/bin/bash
# Run something, muting output or redirecting it to the debug stream
# depending on the value of _ARC_DEBUG.
__python_argcomplete_run() {
@ -34,4 +32,4 @@ _python_argcomplete() {
compopt -o nospace
fi
}
complete -o nospace -o default -F _python_argcomplete ::SCRIPTNAME::
complete -o nospace -o default -F _python_argcomplete @SCRIPTNAME@

View File

@ -0,0 +1,8 @@
icons = files(
'icon_console.png',
'vm_new.png',
)
foreach icon : icons
install_icons += {'file': icon, 'size': '16x16', 'cat': 'actions'}
endforeach

View File

@ -0,0 +1,7 @@
icons = files(
'virt-manager.png'
)
foreach icon : icons
install_icons += {'file': icon, 'size': '16x16', 'cat': 'apps'}
endforeach

View File

@ -0,0 +1,2 @@
subdir('actions')
subdir('apps')

View File

@ -0,0 +1,9 @@
icons = files(
'icon_console.png',
'icon_details.png',
'vm_new.png',
)
foreach icon : icons
install_icons += {'file': icon, 'size': '22x22', 'cat': 'actions'}
endforeach

View File

@ -0,0 +1,7 @@
icons = files(
'virt-manager.png'
)
foreach icon : icons
install_icons += {'file': icon, 'size': '22x22', 'cat': 'apps'}
endforeach

View File

@ -0,0 +1,11 @@
icons = files(
'device_cpu.png',
'device_mem.png',
'device_pci.png',
'device_serial.png',
'device_usb.png',
)
foreach icon : icons
install_icons += {'file': icon, 'size': '22x22', 'cat': 'devices'}
endforeach

View File

@ -0,0 +1,4 @@
subdir('actions')
subdir('apps')
subdir('devices')
subdir('status')

View File

@ -0,0 +1,9 @@
icons = files(
'state_paused.png',
'state_running.png',
'state_shutoff.png',
)
foreach icon : icons
install_icons += {'file': icon, 'size': '22x22', 'cat': 'status'}
endforeach

View File

@ -0,0 +1,9 @@
icons = files(
'icon_console.png',
'vm_clone_wizard.png',
'vm_new.png',
)
foreach icon : icons
install_icons += {'file': icon, 'size': '24x24', 'cat': 'actions'}
endforeach

View File

@ -0,0 +1,7 @@
icons = files(
'virt-manager.png'
)
foreach icon : icons
install_icons += {'file': icon, 'size': '24x24', 'cat': 'apps'}
endforeach

View File

@ -0,0 +1,2 @@
subdir('actions')
subdir('apps')

View File

@ -0,0 +1,7 @@
icons = files(
'virt-manager.png'
)
foreach icon : icons
install_icons += {'file': icon, 'size': '256x256', 'cat': 'apps'}
endforeach

View File

@ -0,0 +1 @@
subdir('apps')

View File

@ -0,0 +1,8 @@
icons = files(
'icon_console.png',
'vm_new.png',
)
foreach icon : icons
install_icons += {'file': icon, 'size': '32x32', 'cat': 'actions'}
endforeach

View File

@ -0,0 +1,7 @@
icons = files(
'virt-manager.png'
)
foreach icon : icons
install_icons += {'file': icon, 'size': '32x32', 'cat': 'apps'}
endforeach

View File

@ -0,0 +1,3 @@
subdir('actions')
subdir('apps')
subdir('status')

View File

@ -0,0 +1,9 @@
icons = files(
'state_paused.png',
'state_running.png',
'state_shutoff.png',
)
foreach icon : icons
install_icons += {'file': icon, 'size': '32x32', 'cat': 'status'}
endforeach

View File

@ -0,0 +1,10 @@
icons = files(
'vm_clone_wizard.png',
'vm_delete_wizard.png',
'vm_import_wizard.png',
'vm_new_wizard.png',
)
foreach icon : icons
install_icons += {'file': icon, 'size': '48x48', 'cat': 'actions'}
endforeach

View File

@ -0,0 +1,7 @@
icons = files(
'virt-manager.png'
)
foreach icon : icons
install_icons += {'file': icon, 'size': '48x48', 'cat': 'apps'}
endforeach

View File

@ -0,0 +1,2 @@
subdir('actions')
subdir('apps')

20
data/icons/meson.build Normal file
View File

@ -0,0 +1,20 @@
install_icons = []
subdir('16x16')
subdir('22x22')
subdir('24x24')
subdir('32x32')
subdir('48x48')
subdir('256x256')
foreach icon : install_icons
if icon['cat'] == 'apps'
icon_dir = datadir / 'icons' / 'hicolor' / icon['size'] / 'apps'
else
icon_dir = pkgdir / 'icons' / 'hicolor' / icon['size'] / icon['cat']
endif
install_data(
icon['file'],
install_dir: icon_dir,
)
endforeach

25
data/meson.build Normal file
View File

@ -0,0 +1,25 @@
fs = import('fs')
desktop_file = files('virt-manager.desktop.in')
appdata_file = files('virt-manager.appdata.xml.in')
install_data(
'org.virt-manager.virt-manager.gschema.xml',
install_dir: datadir / 'glib-2.0' / 'schemas',
)
bash_completion_template = files('bash-completion.sh.in')
foreach script: ['virt-install', 'virt-clone', 'virt-xml']
name = fs.name(script)
configure_file(
input: bash_completion_template,
output: name,
configuration: {'SCRIPTNAME': name},
install: true,
install_dir: datadir / 'bash-completion' / 'completions',
)
endforeach
subdir('icons')

View File

@ -14,10 +14,10 @@
<description>When to scale the VM graphical console. -1 = global default, 0 = never, 1 = only when in full screen mode, 2 = Always</description>
</key>
<key name="console-password" type="(si)">
<default>("", -1)</default>
<summary>Username and secrets ID for graphical password</summary>
<description>Username and secrets ID for graphical password</description>
<key name="console-username" type="s">
<default>""</default>
<summary>Username for graphical password</summary>
<description>Username for graphical password</description>
</key>
<key name="resize-guest" type="i">
@ -25,6 +25,12 @@
<summary>Automatically resize guest when window size changes</summary>
<description>Automatically change guest resolution along with virt-manager window. Only works with spice with a vdagent set up. -1 = global default, 0 = off, 1 = on.</description>
</key>
<key name="autoconnect" type="i">
<default>-1</default>
<summary>Autoconnect to the default VM console when the VM window is opened</summary>
<description>Autoconnect to the default VM console when the VM window is opened. Users may want to turn this off if they prefer to use another viewer app for their VMs, and don't want virt-manager to interfere, but they still want to use virt-manager's details. -1 = global default, 0 = off, 1 = on</description>
</key>
</schema>
@ -55,12 +61,12 @@
<key name="xmleditor-enabled" type="b">
<default>false</default>
<summary>Enable XML editting UI</summary>
<description>Enable XML editting UI</description>
<summary>Enable XML editing UI</summary>
<description>Enable XML editing UI</description>
</key>
<key name="enable-libguestfs-vm-inspection" type="b">
<default>true</default>
<default>false</default>
<summary>Enable libguestfs VM inspection</summary>
<description>Enable libguestfs VM inspection for things like OS icons, installed applications, etc. This only works if python libguestfs bindings are installed.</description>
</key>
@ -199,14 +205,8 @@
<schema id="org.virt-manager.virt-manager.console"
path="/org/virt-manager/virt-manager/console/">
<key name="enable-accels" type="b">
<default>false</default>
<summary>Enable menu accelerators in console window</summary>
<description>Whether to enable menu accelerators while connected to the guest graphical console.</description>
</key>
<key name="scaling" type="i">
<default>1</default>
<default>2</default>
<summary>When to scale the VM graphical console</summary>
<description>When to scale the VM graphical console. 0 = never, 1 = only when in full screen mode, 2 = Always</description>
</key>
@ -223,18 +223,17 @@
<description>Grab keyboard sequence for the graphical console</description>
</key>
<!--This key is not intended to be exposed in the UI yet-->
<key name="grab-keyboard" type="b">
<default>true</default>
<summary>Enable grab keyboard when active and focused</summary>
<description>Enable grab keyboard when active and focused</description>
</key>
<key name="auto-redirect" type="b">
<default>true</default>
<summary>Enable SPICE Auto USB redirection in console window</summary>
<description>Whether to enable SPICE Auto USB redirection while connected to the guest console.</description>
</key>
<key name="autoconnect" type="b">
<default>true</default>
<summary>Autoconnect to the default VM console when the VM window is opened</summary>
<description>Autoconnect to the default VM console when the VM window is opened. Users may want to turn this off if they prefer to use another viewer app for their VMs, and don't want virt-manager to interfere, but they still want to use virt-manager's details.</description>
</key>
</schema>
<schema id="org.virt-manager.virt-manager.details"
@ -248,24 +247,12 @@
<schema id="org.virt-manager.virt-manager.new-vm"
path="/org/virt-manager/virt-manager/new-vm/">
<key name="add-sound" type="b">
<default>true</default>
<summary>Install sound device for new Vms</summary>
<description>Whether to install a sound device for new VMs</description>
</key>
<key name="graphics-type" type="s">
<default>'system'</default>
<summary>Install selected graphics type for new VM</summary>
<description>Install selected graphics type for new VM. vnc or spice, system for software configured default</description>
</key>
<key name="add-spice-usbredir" type="s">
<default>'system'</default>
<summary>Add spice usbredir HW for new VMs</summary>
<description>Add spice usbredir HW for new VMs. yes, no, or system for software configured default</description>
</key>
<key name="storage-format" type="s">
<default>'default'</default>
<summary>Use selected format for new VM storage</summary>
@ -275,7 +262,13 @@
<key name="cpu-default" type="s">
<default>'default'</default>
<summary>CPU setting to use for new VMs</summary>
<description>CPU setting to use for new VMs. Limited to VMs matching the host architecture. Possible values: default (virt-manager default), hv-default (qemu's default), host-model-only (just the model, not the additional features), host-model (libvirt's host-model setting).</description>
<description>CPU setting to use for new VMs. Limited to VMs matching the host architecture. Possible values: default (virt-manager default), hv-default (qemu's default), host-model-only (just the model, not the additional features), host-model (libvirt's host-model setting), host-passthrough (libvirt's host-passthrough setting).</description>
</key>
<key name="firmware" type="s">
<default>'default'</default>
<summary>Use selected firmware for new VM booting</summary>
<description>Firmware used for new VMs. Possible values are default and UEFI. The firmware used is determined by libvirt unless a specific firmware is selected from the Customize dialog.</description>
</key>
</schema>
@ -334,12 +327,6 @@
<description>Whether we require confirmation to remove a virtual device</description>
</key>
<key name="interface-power" type="b">
<default>true</default>
<summary>Confirm device interface start and stop</summary>
<description>Whether we require confirmation to start or stop a libvirt virtual interface</description>
</key>
<key name="unapplied-dev" type="b">
<default>true</default>
<summary>Confirm about unapplied device changes</summary>

View File

@ -3,35 +3,34 @@
<id>virt-manager.desktop</id>
<metadata_license>CC0-1.0</metadata_license>
<project_license>GPL-2.0+</project_license>
<_name>Virtual Machine Manager</_name>
<_summary>Graphically manage KVM, Xen, or LXC via libvirt</_summary>
<name>Virtual Machine Manager</name>
<summary>Graphically manage KVM, Xen, or LXC via libvirt</summary>
<description>
<_p>
<p>
Virtual Machine Manager provides a graphical tool for administering virtual
machines for KVM, Xen, and LXC. Start, stop, add or remove virtual devices,
connect to a graphical or serial console, and see resource usage statistics
for existing VMs on local or remote machines. Uses libvirt as the backend
management API.
</_p>
</p>
</description>
<screenshots>
<screenshot type="default">
<image>https://virt-manager.org/appdata/en_US/manager.png</image>
<_caption>Main manager window</_caption>
<caption>Main manager window</caption>
</screenshot>
<screenshot>
<image>https://virt-manager.org/appdata/en_US/details.png</image>
<_caption>Virtual machine configuration screen</_caption>
<caption>Virtual machine configuration screen</caption>
</screenshot>
<screenshot>
<image>https://virt-manager.org/appdata/en_US/console.png</image>
<_caption>Graphical console connection for a virtual machine</_caption>
<caption>Graphical console connection for a virtual machine</caption>
</screenshot>
</screenshots>
<url type="homepage">https://www.virt-manager.org/</url>
<url type="bugtracker">https://bugzilla.redhat.com/enter_bug.cgi?product=Virtualization%20Tools&amp;component=virt-manager</url>
<url type="translate">https://fedora.zanata.org/project/view/virt-manager/</url>
<update_contact>virt-tools-list@redhat.com</update_contact>
<url type="bugtracker">https://github.com/virt-manager/virt-manager/issues/new/choose</url>
<url type="translate">https://translate.fedoraproject.org/projects/virt-manager/virt-manager/</url>
<translation type="gettext">virt-manager</translation>
<keywords>
<keyword>virtualization</keyword>
@ -39,4 +38,16 @@
<keyword>qemu</keyword>
<keyword>kvm</keyword>
</keywords>
<content_rating type="oars-1.1"/>
<launchable type="desktop-id">virt-manager.desktop</launchable>
<releases>
<release version="5.0.0" date="2024-11-26"/>
<release version="4.1.0" date="2022-08-04"/>
<release version="4.0.0" date="2022-03-02"/>
<release version="3.2.0" date="2020-11-14"/>
<release version="3.1.0" date="2020-09-30"/>
<release version="3.0.0" date="2020-09-15"/>
<release version="2.2.1" date="2019-07-03"/>
<release version="2.2.0" date="2019-06-17"/>
</releases>
</component>

View File

@ -1,8 +1,9 @@
[Desktop Entry]
_Name=Virtual Machine Manager
_Comment=Manage virtual machines
Name=Virtual Machine Manager
Comment=Manage virtual machines
Icon=virt-manager
Exec=virt-manager
Type=Application
Terminal=false
Keywords=vmm;
Categories=System;

18
man/meson.build Normal file
View File

@ -0,0 +1,18 @@
rst_files = files(
'virt-install.rst',
'virt-clone.rst',
'virt-xml.rst',
'virt-manager.rst',
)
rst2man_prog = find_program(['rst2man', 'rst2man.py'], required: true)
foreach rst_file : rst_files
man_page = custom_target(
input: rst_file,
output: '@BASENAME@.1',
command: [ rst2man_prog, '--strict', '@INPUT@', '@OUTPUT@'],
install: true,
install_dir: datadir / 'man' / 'man1',
)
endforeach

View File

@ -1,228 +0,0 @@
=pod
=head1 NAME
virt-clone - clone existing virtual machine images
=head1 SYNOPSIS
B<virt-clone> [OPTION]...
=head1 DESCRIPTION
B<virt-clone> is a command line tool for cloning existing virtual machine
images using the C<libvirt> hypervisor management library. It will copy
the disk images of any existing virtual machine, and define a new guest
with an identical virtual hardware configuration. Elements which require
uniqueness will be updated to avoid a clash between old and new guests.
By default, virt-clone will show an error if the necessary information to
clone the guest is not provided. The --auto-clone option will generate
all needed input, aside from the source guest to clone.
Please note, virt-clone does not change anything _inside_ the guest OS, it only duplicates disks and does host side changes. So things like changing passwords, changing static IP address, etc are outside the scope of this tool. For these types of changes, please see B<virt-sysprep>.
=head1 GENERAL OPTIONS
Most options are not required. Minimum requirements are --original or
--original-xml (to specify the guest to clone), --name, and appropriate
storage options via -file.
=over 4
=item B<--connect> URI
Connect to a non-default hypervisor. See L<virt-install(1)> for details
=item B<-o> ORIGINAL_GUEST
=item B<--original> ORIGINAL_GUEST
Name of the original guest to be cloned. This guest must be shut off or paused
since it is not possible to safely clone active guests at this time.
=item B<--original-xml> ORIGINAL_XML
Libvirt guest xml file to use as the original guest. The guest does not need to
be defined on the libvirt connection. This takes the place of the
C<--original> parameter.
=item B<--auto-clone>
Generate a new guest name, and paths for new storage.
An example or possible generated output:
Original name : MyVM
Generated clone name : MyVM-clone
Original disk path : /home/user/foobar.img
Generated disk path : /home/user/foobar-clone.img
If generated names collide with existing VMs or storage, a number is appended,
such as foobar-clone-1.img, or MyVM-clone-3.
=item B<-n> NAME
=item B<--name> NAME
Name of the new guest virtual machine instance. This must be unique amongst
all guests known to the hypervisor connection, including those not
currently active.
=item B<-u> UUID
=item B<--uuid> UUID
UUID for the guest; if none is given a random UUID will be generated. If you
specify UUID, you should use a 32-digit hexadecimal number. UUID are intended
to be unique across the entire data center, and indeed world. Bear this in
mind if manually specifying a UUID
=item B<-f> DISKFILE
=item B<--file> DISKFILE
Path to the file, disk partition, or logical volume to use as the backing store
for the new guest's virtual disk. If the original guest has multiple disks,
this parameter must be repeated multiple times, once per disk in the original
virtual machine.
=item B<--nvram> NVRAMFILE
Optional path to the new nvram VARS file, if no path is specified and the
guest has nvram the new nvram path will be auto-generated. If the guest
doesn't have nvram this option will be ignored.
=item B<--force-copy> TARGET
Force cloning the passed disk target ('hdc', 'sda', etc.). By default,
C<virt-clone> will skip certain disks, such as those marked 'readonly' or
'shareable'.
=item B<--skip-copy> TARGET
Skip cloning the passed disk target ('hdc', 'sda', etc.). By default,
C<virt-clone> will clone certain disk images, typically read/write
devices. Use this to skip copying of a specific device, so the new
VM uses the same storage path as the original VM.
=item B<--nonsparse>
Fully allocate the new storage if the path being cloned is a sparse file.
See L<virt-install(1)> for more details on sparse vs. nonsparse.
=item B<--preserve-data>
No storage is cloned: disk images specific by --file are preserved as is,
and referenced in the new clone XML. This is useful if you want to clone
a VM XML template, but not the storage contents.
=item B<--reflink>
When --reflink is specified, perform a lightweight copy. This is much faster
if source images and destination images are all on the same btrfs filesystem.
If COW copy is not possible, then virt-clone fails.
=item B<-m> MAC
=item B<--mac> MAC
Fixed MAC address for the guest; If this parameter is omitted, or the value
C<RANDOM> is specified a suitable address will be randomly generated. Addresses
are applied sequentially to the networks as they are listed in the original
guest XML.
=item B<--print-xml>
Print the generated clone XML and exit without cloning.
=item B<--replace>
Shutdown and remove any existing guest with the passed C<--name> before
cloning the original guest.
=item B<-h>
=item B<--help>
Show the help message and exit
=item B<--version>
Show program's version number and exit
=item B<--check>
Enable or disable some validation checks. See L<virt-install(1)> for more details.
=item B<-q>
=item B<--quiet>
Suppress non-error output.
=item B<-d>
=item B<--debug>
Print debugging information to the terminal when running the install process.
The debugging information is also stored in
C<~/.cache/virt-manager/virt-clone.log> even if this parameter is omitted.
=back
=head1 EXAMPLES
Clone the guest called C<demo> on the default connection, auto generating
a new name and disk clone path.
# virt-clone \
--original demo \
--auto-clone
Clone the guest called C<demo> which has a single disk to copy
# virt-clone \
--original demo \
--name newdemo \
--file /var/lib/xen/images/newdemo.img
Clone a QEMU guest with multiple disks
# virt-clone \
--connect qemu:///system \
--original demo \
--name newdemo \
--file /var/lib/xen/images/newdemo.img \
--file /var/lib/xen/images/newdata.img
Clone a guest to a physical device which is at least as big as the
original guests disks. If the destination device is bigger, the
new guest can do a filesystem resize when it boots.
# virt-clone \
--connect qemu:///system \
--original demo \
--name newdemo \
--file /dev/HostVG/DemoVM \
--mac 52:54:00:34:11:54
=head1 BUGS
Please see L<https://virt-manager.org/bugs>
=head1 COPYRIGHT
Copyright (C) Fujitsu Limited, Copyright (C) Red Hat, Inc,
and various contributors.
This is free software. You may redistribute copies of it under the terms
of the GNU General Public License C<https://www.gnu.org/licenses/gpl.html>.
There is NO WARRANTY, to the extent permitted by law.
=head1 SEE ALSO
C<virt-sysprep(1)>, C<virsh(1)>, C<virt-install(1)>, C<virt-manager(1)>, the project website C<https://virt-manager.org>
=cut

243
man/virt-clone.rst Normal file
View File

@ -0,0 +1,243 @@
==========
virt-clone
==========
-------------------------------------
clone existing virtual machine images
-------------------------------------
:Manual section: 1
:Manual group: Virtualization Support
SYNOPSIS
========
``virt-clone`` [OPTION]...
DESCRIPTION
===========
``virt-clone`` is a command line tool for cloning existing virtual machine
images using the ``libvirt`` hypervisor management library. It will copy
the disk images of any existing virtual machine, and define a new guest
with an identical virtual hardware configuration. Elements which require
uniqueness will be updated to avoid a clash between old and new guests.
By default, virt-clone will show an error if the necessary information to
clone the guest is not provided. The --auto-clone option will generate
all needed input, aside from the source guest to clone.
Please note, virt-clone does not change anything _inside_ the guest OS, it
only duplicates disks and does host side changes. So things like changing
passwords, changing static IP address, etc are outside the scope of this
tool. For these types of changes, please see ``virt-sysprep``.
GENERAL OPTIONS
===============
Most options are not required. Minimum requirements are --original or
--original-xml (to specify the guest to clone), --name, and appropriate
storage options via -file.
``--connect`` URI
Connect to a non-default hypervisor. See virt-install(1) for details
``-o``, ``--original`` ORIGINAL_GUEST
Name of the original guest to be cloned. This guest must be shut off.
``--original-xml`` ORIGINAL_XML
Libvirt guest xml file to use as the original guest. The guest does not need to
be defined on the libvirt connection. This takes the place of the
``--original`` parameter.
``--auto-clone``
Generate a new guest name, and paths for new storage.
An example of possible generated output:
.. code-block::
Original name : MyVM
Generated clone name : MyVM-clone
Original disk path : /home/user/foobar.img
Generated disk path : /home/user/foobar-clone.img
If generated names collide with existing VMs or storage, a number is appended,
such as foobar-clone-1.img, or MyVM-clone-3.
``-n``, ``--name`` NAME
Name of the new guest virtual machine instance. This must be unique amongst
all guests known to the hypervisor connection, including those not
currently active.
``-u``, ``--uuid`` UUID
UUID for the guest; if none is given a random UUID will be generated. If you
specify UUID, you should use a 32-digit hexadecimal number. UUID are intended
to be unique across the entire data center, and indeed world. Bear this in
mind if manually specifying a UUID
``-f``, ``--file`` PATH
Path to the file, disk partition, or logical volume to use as the backing store
for the new guest's virtual disk. If the original guest has multiple disks,
this parameter must be repeated multiple times, once per disk in the original
virtual machine.
``--nvram`` NVRAMFILE
Optional path to the new nvram VARS file, if no path is specified and the
guest has nvram the new nvram path will be auto-generated. If the guest
doesn't have nvram this option will be ignored.
``--force-copy`` TARGET
Force cloning the passed disk target ('hdc', 'sda', etc.). By default,
``virt-clone`` will skip certain disks, such as those marked 'readonly' or
'shareable'.
``--skip-copy`` TARGET
Skip cloning the passed disk target ('hdc', 'sda', etc.). By default,
``virt-clone`` will clone certain disk images, typically read/write
devices. Use this to skip copying of a specific device, so the new
VM uses the same storage path as the original VM.
``--nonsparse``
Fully allocate the new storage if the path being cloned is a sparse file.
See virt-install(1) for more details on sparse vs. nonsparse.
``--preserve-data``
No storage is cloned: disk images specified by --file are preserved as is,
and referenced in the new clone XML. This is useful if you want to clone
a VM XML template, but not the storage contents.
``--reflink``
Perform a lightweight copy. This is much faster if source images and destination
images are all on the same btrfs filesystem. This only works for raw format disk
images, any non-raw images will not attempt to use refink
``-m``, ``--mac`` MAC
Fixed MAC address for the guest; If this parameter is omitted, or the value
``RANDOM`` is specified a suitable address will be randomly generated. Addresses
are applied sequentially to the networks as they are listed in the original
guest XML.
``--print-xml``
Print the generated clone XML and exit without cloning.
``--replace``
Before cloning, try a simple ``virsh destroy`` and ``virsh undefine`` on
any existing VM with the passed ``--name``. If those operations fail (like
when ``virsh undefine`` requires ``--nvram`` flag), the clone will fail
and you will need to manually remove the existing VM.
``-h``, ``--help``
Show the help message and exit
``--version``
Show program's version number and exit
``--check``
Enable or disable some validation checks. See virt-install(1) for more details.
``-q``, ``--quiet``
Suppress non-error output.
``-d``, ``--debug``
Print debugging information to the terminal when running the install process.
The debugging information is also stored in
``~/.cache/virt-manager/virt-clone.log`` even if this parameter is omitted.
EXAMPLES
========
Clone the guest called ``demo`` on the default connection, auto generating
a new name and disk clone path.
.. code-block::
# virt-clone \
--original demo \
--auto-clone
Clone the guest called ``demo`` which has a single disk to copy
.. code-block::
# virt-clone \
--original demo \
--name newdemo \
--file /var/lib/xen/images/newdemo.img
Clone a QEMU guest with multiple disks
.. code-block::
# virt-clone \
--connect qemu:///system \
--original demo \
--name newdemo \
--file /var/lib/xen/images/newdemo.img \
--file /var/lib/xen/images/newdata.img
Clone a guest to a physical device which is at least as big as the
original guests disks. If the destination device is bigger, the
new guest can do a filesystem resize when it boots.
.. code-block::
# virt-clone \
--connect qemu:///system \
--original demo \
--name newdemo \
--file /dev/HostVG/DemoVM \
--mac 52:54:00:34:11:54
BUGS
====
Please see https://virt-manager.org/bugs
COPYRIGHT
=========
Copyright (C) Fujitsu Limited, Copyright (C) Red Hat, Inc,
and various contributors.
This is free software. You may redistribute copies of it under the terms
of the GNU General Public License https://www.gnu.org/licenses/gpl.html.
There is NO WARRANTY, to the extent permitted by law.
SEE ALSO
========
``virt-sysprep(1)``, ``virsh(1)``, ``virt-install(1)``, ``virt-manager(1)``, the project website https://virt-manager.org

View File

@ -1,144 +0,0 @@
=pod
=head1 NAME
virt-convert - convert ovf/vmx to native libvirt guests
=head1 SYNOPSIS
B<virt-convert> INPUT.vmx|INPUT.ovf|INPUT-DIR|INPUT.zip [OPTIONS]
=head1 DESCRIPTION
B<virt-convert> is a command line tool for converting VMX or OVF virtual
machines to native libvirt XML. Disk format conversion can also be done
at the same time.
The simplest invocation is simply: virt-convert INPUT. INPUT might be
a .vmx or .ovf file, a directory containing a .vmx or .ovf file (and
likely 1 or more disk images), or an appliance archive like .zip, .tar.gz,
or .ova. virt-convert will try to do the right thing in each case.
By default, the virt-convert will convert all encountered disk images
to 'raw' format, sending the output to a new directory location. So the
original disk images are _not_ altered in place.
=head1 OPTIONS
=over 4
=item B<--connect> URI
Connect to a non-default hypervisor. See L<virt-install(1)> for details
=back
=head1 CONVERSION OPTIONS
=over 4
=item B<-i> INPUT-FORMAT
=item B<--input-format> INPUT-FORMAT
Input format. This should be auto-detected, but can be forced if necessary. Currently C<vmx> and C<ovf> are supported.
=item B<-D> OUTPUT-FORMAT
=item B<--disk-format> OUTPUT-FORMAT
Output disk format. The default is 'raw', so any encountered disk images will be converted to 'raw' format using L<qemu-img(1)>. Pass C<none> if no conversion should be performed: in this case the images will just be copied to the specified --destination.
=item B<--destination> DIRECTORY
The directory to send converted/copied disk images. If not specified, the hypervisor default is used, typically /var/lib/libvirt/images.
=back
=head1 MISCELLANEOUS OPTIONS
=over 4
=item B<--noautoconsole>
Don't automatically try to connect to the guest console. The default behaviour
is to launch L<virt-viewer(1)> to display the graphical console, or to run the
C<virsh> C<console> command to display the text console. Use of this parameter
will disable this behaviour.
=item B<--print-xml>
Print the generated libvirt XML, but do not perform any disk conversions or
install/start the guest. This option implies --dry-run.
=item B<--dry-run>
Proceed through the conversion process, but don't convert disks or actually
write any converted files.
=item B<-h>
=item B<--help>
Show the help message and exit
=item B<--version>
Show program's version number and exit
=item B<-q>
=item B<--quiet>
Avoid verbose output.
=item B<-d>
=item B<--debug>
Print debugging information
=back
=head1 EXAMPLES
Run a fedora18 OVA archive:
# virt-convert fedora18.ova
Run an extracted zip archive containing a centos6 .vmx and .vmdk file, converting the images to qcow2 format
# virt-convert centos6/ --disk-format qcow2
Convert the specified .vmx file. Any references disk images must be in the same directory. Don't change the disk format. Move the disk images to /tmp
# virt-convert foo.vmx --disk-format none --destination /tmp
=head1 BUGS
Please see L<https://virt-manager.org/bugs>
=head1 COPYRIGHT
Copyright (C) Red Hat, Inc, and various contributors.
This is free software. You may redistribute copies of it under the terms
of the GNU General Public License C<https://www.gnu.org/licenses/gpl.html>.
There is NO WARRANTY, to the extent permitted by law.
=head1 SEE ALSO
L<virt-install(1)>, the project website C<https://virt-manager.org>
=cut

File diff suppressed because it is too large Load Diff

2315
man/virt-install.rst Normal file

File diff suppressed because it is too large Load Diff

View File

@ -1,107 +0,0 @@
=head1 NAME
virt-manager - display the virtual machine desktop management tool
=head1 SYNOPSIS
B<virt-manager> [OPTIONS]
=head1 DESCRIPTION
B<virt-manager> is a desktop tool for managing virtual machines. It
provides the ability to control the lifecycle of existing machines
(bootup/shutdown,pause/resume,suspend/restore), provision new virtual
machines and various types of store, manage virtual networks,
access the graphical console of virtual machines, and view performance
statistics, all done locally or remotely.
=head1 OPTIONS
The following options are accepted when running C<virt-manager>:
=over 4
=item B<-h>
=item B<--help>
Display command line help summary
=item B<--version>
Show virt-manager's version number and exit
=item B<-c> URI
=item B<--connect>=URI
Specify the hypervisor connection C<URI>
=item B<--debug>
List debugging output to the console (normally this is only logged in
~/.cache/virt-manager/virt-manager.log). This function implies --no-fork.
=item B<--no-fork>
Don't fork C<virt-manager> off into the background: run it blocking the
current terminal. Useful for seeing possible errors dumped to stdout/stderr.
=item B<--show-DIALOG-WINDOW>
Display the corresponding C<DIALOG-WINDOW> when launching C<virt-manager>.
Connection autostart is skipped, and the manager window will not be shown
at startup in this case.
The following C<DIALOG-WINDOW> options are currently available:
=over 4
=item B<--show-domain-creator>
Display the wizard for creating new virtual machines
=item B<--show-domain-editor> NAME|ID|UUID
Display the dialog for editing properties of the virtual machine with
unique ID matching either the domain name, ID, or UUID
=item B<--show-domain-performance> NAME|ID|UUID
Display the dialog for monitoring performance of the virtual machine with
unique ID matching either the domain name, ID, or UUID
=item B<--show-domain-console> NAME|ID|UUID
Display the virtual console of the virtual machine with
unique ID matching either the domain name, ID, or UUID
=item B<--show-host-summary>
Display the main window summarizing performance for all virtual machines
on the host.
=back
=back
Standard GTK options like --g-fatal-warnings are also accepted.
=head1 BUGS
Please see L<https://virt-manager.org/bugs/>
=head1 COPYRIGHT
Copyright (C) Red Hat, Inc, and various contributors.
This is free software. You may redistribute copies of it under the terms of the GNU General
Public License C<https://www.gnu.org/licenses/gpl.html>. There is NO WARRANTY, to the extent
permitted by law.
=head1 SEE ALSO
C<virsh(1)>, C<virt-viewer(1)>, the project website C<https://virt-manager.org>
=cut

152
man/virt-manager.rst Normal file
View File

@ -0,0 +1,152 @@
============
virt-manager
============
---------------------------------------
Graphical tool for managing libvirt VMs
---------------------------------------
:Manual section: 1
:Manual group: Virtualization Support
SYNOPSIS
========
``virt-manager`` [OPTIONS]
DESCRIPTION
===========
``virt-manager`` is a desktop tool for managing virtual machines. It
provides the ability to control the lifecycle of existing machines
(bootup/shutdown,pause/resume,suspend/restore), provision new virtual
machines and various types of store, manage virtual networks,
access the graphical console of virtual machines, and view performance
statistics, all done locally or remotely.
OPTIONS
=======
Standard GTK options like ``--g-fatal-warnings`` are accepted.
The following options are accepted when running ``virt-manager``
``-h``, ``--help``
Display command line help summary
``--version``
Show virt-manager's version number and exit
``-c``, ``--connect``
Specify the hypervisor connection **URI**
``--debug``
List debugging output to the console (normally this is only logged in
~/.cache/virt-manager/virt-manager.log). This function implies --no-fork.
``--no-fork``
Don't fork ``virt-manager`` off into the background.
See ``VIRT-MANAGER, SSH, AND FORKING`` section for more info.
``--fork``
Force forking ``virt-manager`` off into the background.
This is the default behavior.
See ``VIRT-MANAGER, SSH, AND FORKING`` section for more info.
DIALOG WINDOW OPTIONS
=====================
For these options, only the requested window will be shown, the manager
window will not be run in this case. Connection autostart will also
be disabled. All these options require specifying a manual ``--connect``
URI.
``--show-domain-creator``
Display the wizard for creating new virtual machines
``--show-domain-editor`` NAME|ID|UUID
Display the dialog for editing properties of the virtual machine with
unique ID matching either the domain name, ID, or UUID
``--show-domain-performance`` NAME|ID|UUID
Display the dialog for monitoring performance of the virtual machine with
unique ID matching either the domain name, ID, or UUID
``--show-domain-console`` NAME|ID|UUID
Display the virtual console of the virtual machine with
unique ID matching either the domain name, ID, or UUID
``--show-host-summary``
Display the host/connection details window.
SYSTEM TRAY OPTION
==================
Connection autostart will not be disabled and thus don't require specifying a
manual ``--connect`` URI. But it supports ``--connect`` URI as well:
``--show-systray``
Launch virt-manager only in system tray
VIRT-MANAGER, SSH, AND FORKING
==============================
Historically, on startup virt-manager would detach from the running
terminal and fork into the background. This was to force any usage of
ssh to call ssh-askpass when it needed a password, rather than silently
asking on a terminal the user probably isn't watching.
openssh 8.4p1 released in Sep 2020 added the SSH_ASKPASS_REQUIRE
environment variable that saves us from having to do the fork dance.
https://man.openbsd.org/ssh.1#SSH_ASKPASS_REQUIRE
virt-manager now sets SSH_ASKPASS_REQUIRE=force.
However to get this to work with libvirt ssh connections, you'll need
libvirt 10.8.0 released in October 1st 2024.
virt-manager no longer forks by defaults.
You can get the old forking behavior with the ``--fork`` option,
or by setting the ``VIRT_MANAGER_DEFAULT_FORK=yes`` environment variable.
However if you find you need forking for a usecase other than temporarily
working around libvirt version issues, please let the virt-manager developers
know by filing a bug report.
BUGS
====
Please see https://virt-manager.org/bugs/
COPYRIGHT
=========
Copyright (C) Red Hat, Inc, and various contributors.
This is free software. You may redistribute copies of it under the terms of the GNU General
Public License https://www.gnu.org/licenses/gpl.html. There is NO WARRANTY, to the extent
permitted by law.
SEE ALSO
========
``virsh(1)``, ``virt-viewer(1)``, the project website https://virt-manager.org

View File

@ -1,433 +0,0 @@
=pod
=head1 NAME
virt-xml - Edit libvirt XML using command line options.
=head1 SYNOPSIS
B<virt-xml> DOMAIN XML-ACTION XML-OPTION [OUTPUT-OPTION] [MISC-OPTIONS] ...
=head1 DESCRIPTION
B<virt-xml> is a command line tool for editing libvirt XML using explicit command line options. See the EXAMPLES section at the end of this document to jump right in.
Each B<virt-xml> invocation requires 3 things: name of an existing domain to alter (or XML passed on stdin), an action to on the XML, and an XML change to make. actions are one of:
--add-device: Append a new device definition to the XML
--remove-device: Remove an existing device definition
--edit: Edit an existing XML block
--build-xml: Just build the requested XML block and print it. No domain or input are required here, but it's recommended to provide them, so virt-xml can fill in optimal defaults.
An XML change is one instance of any of the XML options provided by virt-xml, for example --disk or --boot.
B<virt-xml> only allows one action and XML pair per invocation. If you need to make multiple edits, invoke the command multiple times.
=head1 OPTIONS
=over 4
=item B<-c> URI
=item B<--connect>=URI
Connect to a non-default hypervisor. See L<virt-install(1)> for details
=item B<domain>
domain is the name, UUID, or ID of the existing VM. This can be omitted if
using --build-xml, or if XML is passed on stdin.
When a domain is specified, the default output action is --define, even if the VM is running. To update the running VM configuration, add the --update option (but not all options/devices support updating the running VM configuration).
If XML is passed on stdin, the default output is --print-xml.
=back
=head1 XML ACTIONS
=over 4
=item B<--edit> [EDIT-OPTIONS]
Edit the specified XML block. EDIT-OPTIONS tell B<virt-xml> which block to edit. The type of XML that we are editing is decided by XML option that is passed to B<virt-xml>. So if --disk is passed, EDIT-OPTIONS select which <disk> block to edit.
Certain XML options only ever map to a single XML block, like --cpu, --security, --boot, --clock, and a few others. In those cases, B<virt-xml> will not complain if a corresponding XML block does not already exist, it will create it for you.
Most XML options support a special value 'clearxml=yes'. When combined with --edit, it will completely blank out the XML block being edited before applying the requested changes. This allows completely rebuilding an XML block. See EXAMPLES for some usage.
EDIT-OPTIONS examples:
=over 4
=item B<--edit>
--edit without any options implies 'edit the first block'. So '--edit --disk DISK-OPTIONS' means 'edit the first <disk>'.
For the single XML block options mentioned above, plain '--edit' without any options is what you always want to use.
=item B<--edit> #
Select the specified XML block number. So '--edit 2 --disk DISK-OPTS' means 'edit the second <disk>'. This option only really applies for device XML.
=item B<--edit> all
Modify every XML block of the XML option type. So '--edit all --disk DISK-OPTS' means 'edit ever <disk> block'. This option only really applies for device XML.
=item B<--edit> DEVICE-OPTIONS
Modify every XML block that matches the passed device options. The device options are in the same format as would be passed to the XML option.
So '--edit path=/tmp/foo --disk DISK-OPTS' means 'edit every <disk> with path /tmp/foo'. This option only really applies for device XML.
=back
=item B<--add-device>
Append the specified XML options to the XML <devices> list. Example: '--add-device --disk DISK-OPTIONS' will create a new <disk> block and add it to the XML.
This option will error if specified with a non-device XML option (see --edit section for a partial list).
=item B<--remove-device>
Remove the specified device from the XML. The device to remove is chosen by the XML option, which takes arguments in the same format as --edit. Examples
=over 4
=item B<--remove-device> --disk 2
Remove the second disk device
=item B<--remove-device> --network all
Remove all network devices
=item B<--remove-device> --sound pcspk
Remove all sound devices with model='pcspk'
=back
This option will error if specified with a non-device XML option (see --edit section for a partial list).
=item B<--build-xml>
Just build the specified XML, and print it to stdout. No input domain or input XML is required. Example: '--build-xml --disk DISK-OPTIONS' will just print the new <disk> device.
However if the generated XML is targeted for a specific domain, it's recommended to pass it to virt-xml, so the tool can set optimal defaults.
This option will error if specified with an XML option that does not map cleanly to a specific XML block, like --vcpus or --memory.
=back
=head1 OUTPUT OPTIONS
These options decide what action to take after altering the XML. In the common case these do not need to be specified, as 'XML actions' will imply a default output action, described in detail above. These are only needed if you want to modify the default output.
=over 4
=item B<--update>
If the specified domain is running, attempt to alter the running VM configuration. If combined with --edit, this is an update operation. If combined with --add-device, this is a device hotplug. If combined with --remove-device, this is a device hotunplug.
Keep in mind, most XML properties and devices do not support live update operations, so don't expect it to succeed in all cases.
By default this also implies B<--define>.
=item B<--define>
Define the requested XML change. This is typically the default if no output option is specified, but if a --print option is specified, --define is required to force the change.
=item B<--no-define>
Explicitly do not define the XML. For example if you only want to alter the runtime state of a VM, combine this with B<--update>.
=item B<--start>
Start the VM after performing the requeseted changes. If combined with --no-define, this will create transient VM boot with the requested changes.
=item B<--print-diff>
Print the generated XML change in unified diff format. If only this output option is specified, all other output options are disabled and no persistent change is made.
=item B<--print-xml>
Print the generated XML in its entirety. If only this output option is specified, all other output options are disabled and no persistent change is made.
=item B<--confirm>
Before defining or updating the domain, show the generated XML diff and interactively request confirmation.
=back
=head1 GUEST OS OPTIONS
=over 4
=item B<--os-variant> OS_VARIANT
Optimize the guest configuration for a specific operating system (ex.
'fedora29', 'rhel7', 'win10'). While not required, specifying this
options is HIGHLY RECOMMENDED, as it can greatly increase performance
by specifying virtio among other guest tweaks.
If the guest has been installed using virt-manager version 2.0.0 or newer,
providing this information should not be necessary, as the OS variant will
have been stored in the guest configuration during installation and virt-xml
will retrieve it from there automatically.
Use the command "osinfo-query os" to get the list of the accepted OS
variants.
=back
=head1 XML OPTIONS
=over 4
=item B<--disk>
=item B<--network>
=item B<--graphics>
=item B<--metadata>
=item B<--memory>
=item B<--vcpus>
=item B<--cpu>
=item B<--iothreads>
=item B<--seclabel>
=item B<--cputune>
=item B<--numatune>
=item B<--memtune>
=item B<--blkiotune>
=item B<--memorybacking>
=item B<--features>
=item B<--clock>
=item B<--pm>
=item B<--events>
=item B<--resources>
=item B<--sysinfo>
=item B<--qemu-commandline>
=item B<--launchSecurity>
=item B<--boot>
=item B<--idmap>
=item B<--controller>
=item B<--input>
=item B<--serial>
=item B<--parallel>
=item B<--channel>
=item B<--console>
=item B<--hostdev>
=item B<--filesystem>
=item B<--sound>
=item B<--watchdog>
=item B<--video>
=item B<--smartcard>
=item B<--redirdev>
=item B<--memballoon>
=item B<--tpm>
=item B<--rng>
=item B<--panic>
=item B<--memdev>
These options alter the XML for a single class of XML elements. More complete documentation is found in L<virt-install(1)>.
Generally these options map pretty straightforwardly to the libvirt XML, documented at L<https://libvirt.org/formatdomain.html>
Option strings are in the format of: --option opt=val,opt2=val2,... example: --disk path=/tmp/foo,shareable=on. Properties can be used with '--option opt=,', so to clear a disks cache setting you could use '--disk cache=,'
For any option, use --option=? to see a list of all available sub options, example: --disk=? or --boot=?
--help output also lists a few general examples. See the EXAMPLES section below for some common examples.
=back
=head1 MISCELLANEOUS OPTIONS
=over 4
=item B<-h>
=item B<--help>
Show the help message and exit
=item B<--version>
Show program's version number and exit
=item B<-q>
=item B<--quiet>
Avoid verbose output.
=item B<-d>
=item B<--debug>
Print debugging information
=back
=head1 EXAMPLES
See a list of all suboptions that --disk and --network take
# virt-xml --disk=? --network=?
Change the <description> of domain 'EXAMPLE':
# virt-xml EXAMPLE --edit --metadata description="my new description"
# Enable the boot device menu for domain 'EXAMPLE':
# virt-xml EXAMPLE --edit --boot menu=on
Clear the previous <cpu> definition of domain 'winxp', change it to 'host-model', but interactively confirm the diff before saving:
# virt-xml winxp --edit --cpu host-model,clearxml=yes --confirm
Change the second sound card to model=ich6 on 'fedora19', but only output the diff:
# virt-xml fedora19 --edit 2 --sound model=ich6 --print-diff
Update the every graphics device password to 'foo' of the running VM 'rhel6':
# virt-xml rhel6 --edit all --graphics password=foo --update
Remove the disk path from disk device hdc:
# virt-xml rhel6 --edit target=hdc --disk path=
Change all disk devices of type 'disk' to use cache=none, using XML from stdin, printing the new XML to stdout.
# cat <xmlfile> | virt-xml --edit device=disk --disk cache=none
Change disk 'hda' IO to native and use startup policy as 'optional'.
# virt-xml fedora20 --edit target=hda \
--disk io=native,startup_policy=optional
Change all host devices to use driver_name=vfio for VM 'fedora20' on the remote connection
# virt-xml --connect qemu+ssh://remotehost/system \
fedora20 --edit all --hostdev driver_name=vfio
Hotplug host USB device 001.003 to running domain 'fedora19':
# virt-xml fedora19 --update --add-device --hostdev 001.003
Add a spicevmc channel to the domain 'winxp', that will be available after the next VM shutdown.
# virt-xml winxp --add-device --channel spicevmc
Create a 10G qcow2 disk image and attach it to 'fedora18' for the next VM startup:
# virt-xml fedora18 --add-device \
--disk /var/lib/libvirt/images/newimage.qcow2,format=qcow2,size=10
Same as above, but ensure the disk is attached to the most appropriate bus
for the guest OS by providing information about it on the command line:
# virt-xml fedora18 --os-variant fedora18 --add-device \
--disk /var/lib/libvirt/images/newimage.qcow2,format=qcow2,size=10
Hotunplug the disk vdb from the running domain 'rhel7':
# virt-xml rhel7 --update --remove-device --disk target=vdb
Remove all graphics devices from the VM 'rhel7' after the next shutdown:
# virt-xml rhel7 --remove-device --graphics all
Generate XML for a virtio console device and print it to stdout:
# virt-xml --build-xml --console pty,target_type=virtio
Add qemu command line passthrough:
# virt-xml f25 --edit --confirm --qemu-commandline="-device FOO"
Use boot device 'network' for a single transient boot:
# virt-xml myvm --no-define --start --edit --boot network
=head1 CAVEATS
Virtualization hosts supported by libvirt may not permit all changes that might seem possible. Some edits made to a VM's definition may be ignored. For instance, QEMU does not allow the removal of certain devices once they've been defined.
=head1 BUGS
Please see L<https://virt-manager.org/bugs>
=head1 COPYRIGHT
Copyright (C) Red Hat, Inc, and various contributors.
This is free software. You may redistribute copies of it under the terms
of the GNU General Public License C<https://www.gnu.org/licenses/gpl.html>.
There is NO WARRANTY, to the extent permitted by law.
=head1 SEE ALSO
L<virt-install(1)>, the project website C<https://virt-manager.org>
=cut

503
man/virt-xml.rst Normal file
View File

@ -0,0 +1,503 @@
========
virt-xml
========
--------------------------------------------
Edit libvirt XML using command line options.
--------------------------------------------
:Manual section: 1
:Manual group: Virtualization Support
SYNOPSIS
========
``virt-xml`` DOMAIN XML-ACTION XML-OPTION [OUTPUT-OPTION] [MISC-OPTIONS] ...
DESCRIPTION
===========
``virt-xml`` is a command line tool for editing libvirt XML using explicit command line options. See the EXAMPLES section at the end of this document to jump right in.
Each ``virt-xml`` invocation requires 3 things: name of an existing domain to alter (or XML passed on stdin), an action to on the XML, and an XML change to make. actions are one of:
* ``--add-device``: Append a new device definition to the XML
* ``--remove-device``: Remove an existing device definition
* ``--edit``: Edit an existing XML block
* ``--build-xml``: Just build the requested XML block and print it. No domain or input are required here, but it's recommended to provide them, so virt-xml can fill in optimal defaults.
An XML change is one instance of any of the XML options provided by virt-xml, for example --disk or --boot.
``virt-xml`` only allows one action and XML pair per invocation. If you need to make multiple edits, invoke the command multiple times.
OPTIONS
=======
``-c`` ``--connect`` URI
Connect to a non-default hypervisor. See virt-install(1) for details
``domain``
domain is the name, UUID, or ID of the existing VM. This can be omitted if
using --build-xml, or if XML is passed on stdin.
When a domain is specified, the default output action is --define, even if the
VM is running. To update the running VM configuration, add the --update option
(but not all options/devices support updating the running VM configuration).
If XML is passed on stdin, the default output is --print-xml.
XML ACTIONS
===========
``--edit`` [EDIT-OPTIONS]
Edit the specified XML block. EDIT-OPTIONS tell ``virt-xml`` which block
to edit. The type of XML that we are editing is decided by XML option that
is passed to ``virt-xml`` . So if --disk is passed, EDIT-OPTIONS select
which <disk> block to edit.
Certain XML options only ever map to a single XML block, like --cpu,
--security, --boot, --clock, and a few others. In those cases,
``virt-xml`` will not complain if a corresponding XML block does not
already exist, it will create it for you.
Most XML options support a special value 'clearxml=yes'. When combined
with --edit, it will completely blank out the XML block being edited
before applying the requested changes. This allows completely rebuilding
an XML block. See EXAMPLES for some usage.
EDIT-OPTIONS examples:
* ``--edit``
--edit without any options implies 'edit the first block'. So
'--edit --disk DISK-OPTIONS' means 'edit the first <disk>'.
For the single XML block options mentioned above, plain
'--edit' without any options is what you always want to use.
* ``--edit`` #
Select the specified XML block number. So '--edit 2 --disk DISK-OPTS'
means 'edit the second <disk>'. This option only really applies for
device XML.
* ``--edit`` all
Modify every XML block of the XML option type. So
'--edit all --disk DISK-OPTS' means 'edit ever <disk> block'.
This option only really applies for device XML.
* ``--edit`` DEVICE-OPTIONS
Modify every XML block that matches the passed device options.
The device options are in the same format as would be passed to
the XML option.
So `--edit path=/tmp/foo --disk DISK-OPTS` means 'edit every <disk> with
path /tmp/foo'. This option only really applies for device XML.
``--add-device``
Append the specified XML options to the XML <devices> list. Example:
'--add-device --disk DISK-OPTIONS' will create a new <disk> block and
add it to the XML.
This option will error if specified with a non-device XML option
(see --edit section for a partial list).
``--remove-device``
Remove the specified device from the XML. The device to remove is chosen
by the XML option, which takes arguments in the same format as --edit.
Examples:
* ``--remove-device --disk 2``
Remove the second disk device
* ``--remove-device --network all``
Remove all network devices
* ``--remove-device --sound pcspk``
Remove all sound devices with model='pcspk'
This option will error if specified with a non-device XML option
(see --edit isection for a partial list).
``--build-xml``
Just build the specified XML, and print it to stdout. No input domain or
input XML is required. Example: '--build-xml --disk DISK-OPTIONS' will
just print the new <disk> device.
However if the generated XML is targeted for a specific domain, it's
recommended to pass it to virt-xml, so the tool can set optimal defaults.
This option will error if specified with an XML option that does not map
cleanly to a specific XML block, like --vcpus or --memory.
OUTPUT OPTIONS
==============
These options decide what action to take after altering the XML. In the common case these do not need to be specified, as 'XML actions' will imply a default output action, described in detail above. These are only needed if you want to modify the default output.
``--update``
If the specified domain is running, attempt to alter the running VM configuration. If combined with --edit, this is an update operation. If combined with --add-device, this is a device hotplug. If combined with --remove-device, this is a device hotunplug.
Keep in mind, most XML properties and devices do not support live update operations, so don't expect it to succeed in all cases.
By default this also implies ``--define``.
``--define``
Define the requested XML change. This is typically the default if no output option is specified, but if a --print option is specified, --define is required to force the change.
``--no-define``
Explicitly do not define the XML. For example if you only want to alter the runtime state of a VM, combine this with ``--update``.
``--start``
Start the VM after performing the requested changes. If combined with --no-define, this will create transient VM boot with the requested changes.
``--print-diff``
Print the generated XML change in unified diff format. If only this output option is specified, all other output options are disabled and no persistent change is made.
``--print-xml``
Print the generated XML in its entirety. If only this output option is specified, all other output options are disabled and no persistent change is made.
``--confirm``
Before defining or updating the domain, show the generated XML diff and interactively request confirmation.
GUEST OS OPTIONS
================
``--osinfo``, ``--os-variant`` OS_VARIANT
Optimize the guest configuration for a specific operating system (ex.
'fedora29', 'rhel7', 'win10'). While not required, specifying this
options is HIGHLY RECOMMENDED, as it can greatly increase performance
by specifying virtio among other guest tweaks.
If the guest has been installed using virt-manager version 2.0.0 or newer,
providing this information should not be necessary, as the OS variant will
have been stored in the guest configuration during installation and virt-xml
will retrieve it from there automatically.
Use the command ``virt-xml --osinfo list`` to get the list of the
accepted OS variants. See ``osinfo-query os`` for even more output.
See virt-install(1) documentation for more details about ``--osinfo/--os-variant``
CONVERSION OPTIONS
==================
``--convert-to-q35``
^^^^^^^^^^^^^^^^^^^^
**Syntax:** ``--convert-to-q35`` [OPTIONS]
Convert an existing VM config from PC/i440FX to Q35 machine type.
This largely consists of:
* Convert device topology from PCI to PCIe
* Convert any IDE storage to SATA
You may need to make config changes inside the VM to handle this as well.
For example, Windows 10 may not find the boot device after IDE to SATA conversion.
But booting into safe mode once may fix it.
Sub options are:
``num_pcie_root_ports=NUM``
Control the number of default ``pcie-root-port`` controller devices
we add to the VM by default.
``--convert-to-vnc``
^^^^^^^^^^^^^^^^^^^^
**Syntax:** ``--convert-to-vnc`` [OPTIONS]
Convert an existing VM to exclusively use a single VNC graphics device.
It will attempt to remove all references to any non-VNC graphics config, like
Spice. For example:
* ``qxl`` devices will be replaced
* all ``spicevmc`` and ``spiceport`` devices will be removed
* spice GL will be converted to ``egl-headless``
Sub options are:
``qemu-vdagent=on|off``
Add a ``qemu-vdagent`` device if one is not already configured.
This replaces some functionality of the spice vdagent.
This defaults to ``off`` but that could change in the future.
XML OPTIONS
===========
* ``--disk``
* ``--network``
* ``--graphics``
* ``--metadata``
* ``--memory``
* ``--vcpus``
* ``--cpu``
* ``--iothreads``
* ``--seclabel``
* ``--keywrap``
* ``--cputune``
* ``--numatune``
* ``--memtune``
* ``--blkiotune``
* ``--memorybacking``
* ``--features``
* ``--clock``
* ``--pm``
* ``--events``
* ``--resources``
* ``--sysinfo``
* ``--xml``
* ``--qemu-commandline``
* ``--launchSecurity``
* ``--boot``
* ``--idmap``
* ``--controller``
* ``--input``
* ``--serial``
* ``--parallel``
* ``--channel``
* ``--console``
* ``--hostdev``
* ``--filesystem``
* ``--sound``
* ``--audio``
* ``--watchdog``
* ``--video``
* ``--smartcard``
* ``--redirdev``
* ``--memballoon``
* ``--tpm``
* ``--rng``
* ``--panic``
* ``--shmem``
* ``--memdev``
These options alter the XML for a single class of XML elements. More complete documentation is found in virt-install(1).
Generally these options map pretty straightforwardly to the libvirt XML, documented at https://libvirt.org/formatdomain.html
Option strings are in the format of: --option opt=val,opt2=val2,... example: --disk path=/tmp/foo,shareable=on. Properties can be used with '--option opt=,', so to clear a disks cache setting you could use '--disk cache=,'
For any option, use --option=? to see a list of all available sub options, example: --disk=? or --boot=?
--help output also lists a few general examples. See the EXAMPLES section below for some common examples.
virt-xml specifically has some operations that don't really apply to virt-install
Examples:
``--boot refresh-machine-type=yes``
Refresh the XML ``<os><type machine=X></os>`` value to the latest one
that qemu provides. For example, if your VM has a machine type value
``pc-q35-4.0``, this will reset the value to ``q35``, and works
similarly with other versioned machine types. Occasionally this is
necessary to get enable qemu bug fixes, or when qemu deprecates and
removes old machine type values.
MISCELLANEOUS OPTIONS
=====================
``-h``, ``--help``
Show the help message and exit
``--version``
Show program's version number and exit
``-q``, ``--quiet``
Avoid verbose output.
``-d``, ``--debug``
Print debugging information
EXAMPLES
========
See a list of all suboptions that --disk and --network take
.. code-block::
# virt-xml --disk=? --network=?
Change the <description> of domain 'EXAMPLE':
.. code-block::
# virt-xml EXAMPLE --edit --metadata description="my new description"
# Enable the boot device menu for domain 'EXAMPLE':
.. code-block::
# virt-xml EXAMPLE --edit --boot menu=on
Clear the previous <cpu> definition of domain 'winxp', change it to 'host-model', but interactively confirm the diff before saving:
.. code-block::
# virt-xml winxp --edit --cpu host-model,clearxml=yes --confirm
Change the second sound card to model=ich6 on 'fedora19', but only output the diff:
.. code-block::
# virt-xml fedora19 --edit 2 --sound model=ich6 --print-diff
Update the every graphics device password to 'foo' of the running VM 'rhel6':
.. code-block::
# virt-xml rhel6 --edit all --graphics password=foo --update
Remove the disk path from disk device hdc:
.. code-block::
# virt-xml rhel6 --edit target=hdc --disk path=
Change all disk devices of type 'disk' to use cache=none, using XML from stdin, printing the new XML to stdout.
.. code-block::
# cat <xmlfile> | virt-xml --edit device=disk --disk cache=none
Change disk 'hda' IO to native and use startup policy as 'optional'.
.. code-block::
# virt-xml fedora20 --edit target=hda \
--disk io=native,startup_policy=optional
Change all host devices to use driver_name=vfio for VM 'fedora20' on the remote connection
.. code-block::
# virt-xml --connect qemu+ssh://remotehost/system \
fedora20 --edit all --hostdev driver_name=vfio
Hotplug host USB device 001.003 to running domain 'fedora19':
.. code-block::
# virt-xml fedora19 --update --add-device --hostdev 001.003
Add a spicevmc channel to the domain 'winxp', that will be available after the next VM shutdown.
.. code-block::
# virt-xml winxp --add-device --channel spicevmc
Create a 10G qcow2 disk image and attach it to 'fedora18' for the next VM startup:
.. code-block::
# virt-xml fedora18 --add-device \
--disk /var/lib/libvirt/images/newimage.qcow2,format=qcow2,size=10
Same as above, but ensure the disk is attached to the most appropriate bus
for the guest OS by providing information about it on the command line:
.. code-block::
# virt-xml fedora18 --osinfo fedora18 --add-device \
--disk /var/lib/libvirt/images/newimage.qcow2,format=qcow2,size=10
Hotunplug the disk vdb from the running domain 'rhel7':
.. code-block::
# virt-xml rhel7 --update --remove-device --disk target=vdb
Remove all graphics devices from the VM 'rhel7' after the next shutdown:
.. code-block::
# virt-xml rhel7 --remove-device --graphics all
Generate XML for a virtio console device and print it to stdout:
.. code-block::
# virt-xml --build-xml --console pty,target_type=virtio
Add qemu command line passthrough:
.. code-block::
# virt-xml f25 --edit --confirm --qemu-commandline="-device FOO"
Use boot device 'network' for a single transient boot:
.. code-block::
# virt-xml myvm --no-define --start --edit --boot network
CAVEATS
=======
Virtualization hosts supported by libvirt may not permit all changes that might seem possible. Some edits made to a VM's definition may be ignored. For instance, QEMU does not allow the removal of certain devices once they've been defined.
BUGS
====
Please see https://virt-manager.org/bugs
COPYRIGHT
=========
Copyright (C) Red Hat, Inc, and various contributors.
This is free software. You may redistribute copies of it under the terms
of the GNU General Public License https://www.gnu.org/licenses/gpl.html.
There is NO WARRANTY, to the extent permitted by law.
SEE ALSO
========
virt-install(1), the project website https://virt-manager.org

73
meson.build Normal file
View File

@ -0,0 +1,73 @@
project('virt-manager',
version: '5.0.0',
meson_version: '>=0.63.0',
)
python = import('python')
python3 = python.find_installation('python3')
prefix = get_option('prefix')
datadir = prefix / get_option('datadir')
bindir = prefix / get_option('bindir')
pkgdir = datadir / 'virt-manager'
# figure out if we are building from git
git = run_command('test', '-e', '.git', check: false).returncode() == 0
subdir('scripts')
subdir('man')
subdir('data')
subdir('ui')
subdir('virtinst')
subdir('virtManager')
subdir('po')
bin_data = [
{'pkgname': 'virtinst', 'filename': 'virtinstall', 'toolname': 'virt-install'},
{'pkgname': 'virtinst', 'filename': 'virtclone', 'toolname': 'virt-clone'},
{'pkgname': 'virtinst', 'filename': 'virtxml', 'toolname': 'virt-xml'},
{'pkgname': 'virtManager', 'filename': 'virtmanager', 'toolname': 'virt-manager'},
]
foreach bin : bin_data
custom_target(
command: [make_bin_wrapper_prog, pkgdir, bin['pkgname'], bin['filename']],
capture: true,
output: bin['toolname'],
install: true,
install_dir: bindir,
install_mode: 'rwxr-xr-x',
)
endforeach
gnome = import('gnome')
gnome.post_install(
glib_compile_schemas: get_option('compile-schemas'),
gtk_update_icon_cache: get_option('update-icon-cache'),
)
if git
spec_conf = configuration_data({
'VERSION': meson.project_version(),
})
spec_file = configure_file(
input: 'virt-manager.spec.in',
output: '@BASENAME@',
configuration: spec_conf,
)
meson.add_dist_script(meson_dist_prog.full_path(), spec_file)
endif
if get_option('tests').auto()
use_tests = git
elif get_option('tests').enabled()
use_tests = true
else
use_tests = false
endif
if use_tests
subdir('tests')
endif

7
meson_options.txt Normal file
View File

@ -0,0 +1,7 @@
option('update-icon-cache', type: 'boolean', value: true, description: 'whether to run gtk-update-icon-cache')
option('compile-schemas', type: 'boolean', value: true, description: 'whether to compile gsettings schemas')
option('default-graphics', type: 'combo', choices: ['spice', 'vnc'], value: 'spice', description: 'default graphics type')
option('default-hvs', type: 'array', choices: ['qemu', 'xen', 'lxc', 'bhyve', 'vz'], description: 'list of hypervisors shown in "Open Connection" wizard')
option('tests', type: 'feature', value: 'auto', description: 'whether to run tests')

53
po/LINGUAS Normal file
View File

@ -0,0 +1,53 @@
ar
as
bg
bn_IN
bs
ca
cs
da
de
en_GB
es
fa
fi
fr
fur
gl
gu
hi
hr
hu
id
ie
is
it
ja
ka
kab
kn
ko
ml
mr
ms
nb
nl
or
pa
pl
pt
pt_BR
ro
ru
si
sk
sr
sr@latin
sv
ta
te
tr
uk
vi
zh_CN
zh_TW

174
po/POTFILES Normal file
View File

@ -0,0 +1,174 @@
data/virt-manager.appdata.xml.in
data/virt-manager.desktop.in
ui/about.ui
ui/addhardware.ui
ui/addstorage.ui
ui/asyncjob.ui
ui/clone.ui
ui/connectauth.ui
ui/console.ui
ui/createconn.ui
ui/createnet.ui
ui/createpool.ui
ui/createvm.ui
ui/createvol.ui
ui/delete.ui
ui/details.ui
ui/fsdetails.ui
ui/gfxdetails.ui
ui/hostnets.ui
ui/hoststorage.ui
ui/host.ui
ui/manager.ui
ui/migrate.ui
ui/netlist.ui
ui/oslist.ui
ui/preferences.ui
ui/snapshotsnew.ui
ui/snapshots.ui
ui/storagebrowse.ui
ui/tpmdetails.ui
ui/vmwindow.ui
ui/vsockdetails.ui
ui/xmleditor.ui
virtinst/buildconfig.py
virtinst/capabilities.py
virtinst/cli.py
virtinst/cloner.py
virtinst/connection.py
virtinst/devices/audio.py
virtinst/devices/char.py
virtinst/devices/controller.py
virtinst/devices/device.py
virtinst/devices/disk.py
virtinst/devices/filesystem.py
virtinst/devices/graphics.py
virtinst/devices/hostdev.py
virtinst/devices/__init__.py
virtinst/devices/input.py
virtinst/devices/interface.py
virtinst/devices/iommu.py
virtinst/devices/memballoon.py
virtinst/devices/memory.py
virtinst/devices/panic.py
virtinst/devices/redirdev.py
virtinst/devices/rng.py
virtinst/devices/shmem.py
virtinst/devices/smartcard.py
virtinst/devices/sound.py
virtinst/devices/tpm.py
virtinst/devices/video.py
virtinst/devices/vsock.py
virtinst/devices/watchdog.py
virtinst/diskbackend.py
virtinst/domain/blkiotune.py
virtinst/domain/clock.py
virtinst/domain/cpu.py
virtinst/domain/cputune.py
virtinst/domain/features.py
virtinst/domain/idmap.py
virtinst/domain/__init__.py
virtinst/domain/keywrap.py
virtinst/domain/launch_security.py
virtinst/domain/memorybacking.py
virtinst/domain/memtune.py
virtinst/domain/metadata.py
virtinst/domain/numatune.py
virtinst/domain/os.py
virtinst/domain/pm.py
virtinst/domain/resource.py
virtinst/domain/seclabel.py
virtinst/domain/sysinfo.py
virtinst/domain/vcpus.py
virtinst/domain/xmlnsqemu.py
virtinst/domcapabilities.py
virtinst/generatename.py
virtinst/guest.py
virtinst/__init__.py
virtinst/install/cloudinit.py
virtinst/install/__init__.py
virtinst/install/installerinject.py
virtinst/install/installer.py
virtinst/install/installertreemedia.py
virtinst/install/unattended.py
virtinst/install/urldetect.py
virtinst/install/urlfetcher.py
virtinst/install/volumeupload.py
virtinst/logger.py
virtinst/network.py
virtinst/nodedev.py
virtinst/osdict.py
virtinst/pollhelpers.py
virtinst/_progresspriv.py
virtinst/progress.py
virtinst/snapshot.py
virtinst/storage.py
virtinst/support.py
virtinst/uri.py
virtinst/virtclone.py
virtinst/virtinstall.py
virtinst/virtxml.py
virtinst/xmlapi.py
virtinst/xmlbuilder.py
virtinst/xmlutil.py
virtManager/about.py
virtManager/addhardware.py
virtManager/asyncjob.py
virtManager/baseclass.py
virtManager/clone.py
virtManager/config.py
virtManager/connection.py
virtManager/connmanager.py
virtManager/createconn.py
virtManager/createnet.py
virtManager/createpool.py
virtManager/createvm.py
virtManager/createvol.py
virtManager/delete.py
virtManager/details/console.py
virtManager/details/details.py
virtManager/details/__init__.py
virtManager/details/serialcon.py
virtManager/details/snapshots.py
virtManager/details/sshtunnels.py
virtManager/details/viewers.py
virtManager/device/addstorage.py
virtManager/device/fsdetails.py
virtManager/device/gfxdetails.py
virtManager/device/__init__.py
virtManager/device/mediacombo.py
virtManager/device/netlist.py
virtManager/device/tpmdetails.py
virtManager/device/vsockdetails.py
virtManager/engine.py
virtManager/error.py
virtManager/hostnets.py
virtManager/host.py
virtManager/hoststorage.py
virtManager/__init__.py
virtManager/lib/connectauth.py
virtManager/lib/graphwidgets.py
virtManager/lib/__init__.py
virtManager/lib/inspection.py
virtManager/lib/keyring.py
virtManager/lib/libvirtenummap.py
virtManager/lib/module_trace.py
virtManager/lib/statsmanager.py
virtManager/lib/testmock.py
virtManager/lib/uiutil.py
virtManager/manager.py
virtManager/migrate.py
virtManager/object/domain.py
virtManager/object/__init__.py
virtManager/object/libvirtobject.py
virtManager/object/network.py
virtManager/object/nodedev.py
virtManager/object/storagepool.py
virtManager/oslist.py
virtManager/preferences.py
virtManager/storagebrowse.py
virtManager/systray.py
virtManager/virtmanager.py
virtManager/vmmenu.py
virtManager/vmwindow.py
virtManager/xmleditor.py

6656
po/ar.po Normal file

File diff suppressed because it is too large Load Diff

13499
po/as.po

File diff suppressed because it is too large Load Diff

10753
po/bg.po

File diff suppressed because it is too large Load Diff

13553
po/bn_IN.po

File diff suppressed because it is too large Load Diff

10728
po/bs.po

File diff suppressed because it is too large Load Diff

12073
po/ca.po

File diff suppressed because it is too large Load Diff

10375
po/cs.po

File diff suppressed because it is too large Load Diff

10864
po/da.po

File diff suppressed because it is too large Load Diff

12267
po/de.po

File diff suppressed because it is too large Load Diff

10680
po/en_GB.po

File diff suppressed because it is too large Load Diff

12463
po/es.po

File diff suppressed because it is too large Load Diff

6643
po/fa.po Normal file

File diff suppressed because it is too large Load Diff

10166
po/fi.po

File diff suppressed because it is too large Load Diff

12340
po/fr.po

File diff suppressed because it is too large Load Diff

7449
po/fur.po Normal file

File diff suppressed because it is too large Load Diff

6648
po/gl.po Normal file

File diff suppressed because it is too large Load Diff

9754
po/gu.po

File diff suppressed because it is too large Load Diff

9508
po/hi.po

File diff suppressed because it is too large Load Diff

11626
po/hr.po

File diff suppressed because it is too large Load Diff

9392
po/hu.po

File diff suppressed because it is too large Load Diff

7287
po/id.po Normal file

File diff suppressed because it is too large Load Diff

6675
po/ie.po Normal file

File diff suppressed because it is too large Load Diff

10710
po/is.po

File diff suppressed because it is too large Load Diff

10551
po/it.po

File diff suppressed because it is too large Load Diff

12183
po/ja.po

File diff suppressed because it is too large Load Diff

7180
po/ka.po Normal file

File diff suppressed because it is too large Load Diff

6652
po/kab.po Normal file

File diff suppressed because it is too large Load Diff

13547
po/kn.po

File diff suppressed because it is too large Load Diff

12079
po/ko.po

File diff suppressed because it is too large Load Diff

33
po/meson.build Normal file
View File

@ -0,0 +1,33 @@
i18n = import('i18n')
i18n.merge_file(
input: desktop_file,
output: '@BASENAME@',
type: 'desktop',
po_dir: meson.current_source_dir(),
install: true,
install_dir: datadir / 'applications',
)
i18n.merge_file(
input: appdata_file,
output: '@BASENAME@',
type: 'xml',
po_dir: meson.current_source_dir(),
install: true,
install_dir: datadir / 'metainfo',
)
i18n.gettext(
meson.project_name(),
args: [
'--from-code=UTF-8',
'--keyword=_',
'--add-comments=translators',
'--directory=@0@'.format(meson.project_source_root()),
'--files-from=@0@'.format(meson.current_source_dir() / 'POTFILES'),
'--msgid-bugs-address=https://github.com/virt-manager/virt-manager/issues',
'--package-version=@0@'.format(meson.project_version()),
'--sort-by-file',
],
)

9696
po/ml.po

File diff suppressed because it is too large Load Diff

13503
po/mr.po

File diff suppressed because it is too large Load Diff

10698
po/ms.po

File diff suppressed because it is too large Load Diff

10736
po/nb.po

File diff suppressed because it is too large Load Diff

9742
po/nl.po

File diff suppressed because it is too large Load Diff

9542
po/or.po

File diff suppressed because it is too large Load Diff

9597
po/pa.po

File diff suppressed because it is too large Load Diff

Some files were not shown because too many files have changed in this diff Show More