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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
There's valid cases where a VM can be defined with a conflicting MAC
address. Prior to ebd6091cc8 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>
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>
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>
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>
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>
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>
'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>