This allows for installing locale packages. This can be achieved
by adding a entry of the format packagename-${LOCALE} in the
packages configuration module.
This is done to support both Pythonic and Qt style method names, i.e.
both "isNextEnabled" and "is_next_enabled" is ok in a Python module.
Also better documentation in PythonQtViewStep, and stub for
setConfigurationMap.
Finally, proper handling of PythonQtViewStep Python-facing basewidget:
with this change, a call to PQVS::widget() only triggers a widget
relayout if it's necessary, and leaves it alone otherwise.
This means that when we edit a partition, we don't consider
its current mountpoint invalid because it is already in-use.
We need to do this for both "edit existing partition" and
"edit a partition that we are still creating".
We get the mountpoints already used by other partitions, and
disable the Ok button in the "Create new partition" dialog if
the user selects/writes a mountpoint which is already used.
We are going to do the same in the Edit partition dialog
after testing.
Package groups are divided into critical and non-critical
depending on whether we want all Calamares to fail if installing
a package in the group fails, or we are okay with just logging a
warning.
The distinction is configured in the YAML file listing the package
groups. By default, all groups are critical, to keep supporting
the previous behaviour.
On 32-bit UEFI (note that the bitness of the firmware is what matters
here, not the bitness of the distribution), instead of copying
grubx64.efi to bootx64.efi, copy grubia32.efi to bootia32.efi.
Patch by TeHMoroS from SparkyLinux.
CAL-403 #close
Use QNetworkAccessManager instead of raw QtDBus queries to
NetworkManager in RequirementsChecker::checkHasInternet(). This is much
simpler (i.e., less error-prone) and should be more portable (to, e.g.,
ConnMan).
- [partition] remove sgdisk dependency
- [displaymanager] use configparser and add better autologin handling
- [displaymanager] set a preferred Xsession for autologin
- [netinstall] Support selecting visible groups by default
- [packages] Add option of updating packages db before perfoming package operations
- [packages] Allow try_install and try_remove entries in packages module
- [unpackfs] Do not fail if rsync returns exit code 23
Unfortunately, rsync returns exit code 23 (Partial transfer due to
error) if it cannot write extended attributes (with -X) because the
target file system does not support it, e.g., the FAT EFI system
partition. We need -X because distributions using file system
capabilities and/or SELinux require the extended attributes. But
distributions using SELinux may also have SELinux labels set on files
under /boot/efi, and rsync complains about those. The only clean way
would be to split the rsync into one with -X and --exclude /boot/efi and
a separate one without -X for /boot/efi, but only if /boot/efi is
actually an EFI system partition. For now, this hack will have to do.
See also:
https://bugzilla.redhat.com/show_bug.cgi?id=868755#c50
for the same issue in Anaconda, which uses a similar workaround.
In other words, support:
hidden: false
selected: true
groups.
This was supposed to work according to README.md, but not actually
implemented. Now it should be working.
Since sddm.conf follows the INI format we can use configparser
with a few added options to properly parse the config and write
it out instead of manually parsing each line which is slow and
prone to error.
For eg. The old code would fail to parse a conf which had no
commented out User key but where the user had configured autologin
in Calamares.
Address an old FIXME in
PartitionCoreModule::scanForEfiSystemPartitions(): Check the FlagEsp on
the Partition object (that KPMcore has been supporting since 2.1.0)
instead of running sgdisk.
The manual partitioning setup was already requiring the user to check
the ESP flag for the EFI System Partition. Now the autopartitioning also
sets it directly (a one-line change). The sgdisk call in the bootloader
module is thus no longer necessary (it was only a workaround because
kpmcore < 2.1.0 did not support FlagEsp), so remove that snippet.
This fixes configurations such as NVME disks where splitting boot_device
into boot_device[-1:] and boot_device[:-1] is not the correct split
(because the partition gets a 2-letter suffix) (reported by demmm on
IRC).
These job plugins work similarly to view modules, with the following
differences:
* These jobs need to link only libcalamares, not libcalamaresui. For
this reason, PluginFactory was moved from libcalamaresui to
libcalamares. (It depends only on QtCore.)
* Instead of deriving from ViewModule, derive from CppJob (which is a
subclass of Job).
* Like process and Python jobs, a job plugin is a single job, whereas a
ViewModule can generate a whole list of jobs.
The CppJob and CppJobModule classes are new. In Module::fromDescriptor,
the combination type=job, intf=qtplugin is now supported and mapped to
CppJobModule.
* add rd.luks.uuid to GRUB_CMDLINE (fixes unbootable system with dracut --nohostonly, and doesn't affect any other initramfs generators)
* typo
* only write rd.luks.uuid line if dracut is present, and leave other initramfs generators alone :D
* add missing = operator
If we use .replace("'", "'\\''") for escaping, we also need to use
single quotes, not double quotes.
This was broken by the port from '%' to format, which also randomly
changed quoting characters for no good reason. Changing the outer ones
does not matter, but \" or ' within a string is not the same thing!
Added an initramfscfg module to handle pre-configuration for the Debian
update-initramfs, such as installing hooks (needed for luks/FDE support
on Debian-based distros).
Closes#254. (Cherry-picked from the pull request.)
* add rd.luks.uuid to GRUB_CMDLINE (fixes unbootable system with dracut --nohostonly, and doesn't affect any other initramfs generators)
* typo
* only write rd.luks.uuid line if dracut is present, and leave other initramfs generators alone :D
* add missing = operator
Add a dracutlukscfg module to write a
/etc/dracut.conf.d/calamares-luks.conf file for LUKS full disk
encryption support with Dracut.
You should run:
* partition
* luksbootkeyfile
* dracutlukscfg
* dracut
in that order (not necessarily in immediate sequence). The
luksopenswaphook module is not used with Dracut.
If we use .replace("'", "'\\''") for escaping, we also need to use
single quotes, not double quotes.
This was broken by the port from '%' to format, which also randomly
changed quoting characters for no good reason. Changing the outer ones
does not matter, but \" or ' within a string is not the same thing!
fstab.conf: Add a new "crypttabOptions" option that defaults to "luks".
Document that for Debian and Debian-based distributions, the
setting should be changed to "luks,keyscript=/bin/cat".
main.py: Append the options from the above setting to the end of every
line in crypttab.
At least the "luks" option should always be there, because there may be
different encryption types. The Debian initramfs-tools also require the
Debian-specific keyscript option and will otherwise ignore the keyfile
entirely (see pull request #254).
At least the Debian update-initramfs needs the entry to be there (see
pull request #254). Dracut will probably need it too. And logically, it
should be there.
Added an initramfscfg module to handle pre-configuration for the Debian
update-initramfs, such as installing hooks (needed for luks/FDE support
on Debian-based distros).
Closes#254. (Cherry-picked from the pull request.)
fstab.conf: Add a new "crypttabOptions" option that defaults to "luks".
Document that for Debian and Debian-based distributions, the
setting should be changed to "luks,keyscript=/bin/cat".
main.py: Append the options from the above setting to the end of every
line in crypttab.
At least the "luks" option should always be there, because there may be
different encryption types. The Debian initramfs-tools also require the
Debian-specific keyscript option and will otherwise ignore the keyfile
entirely (see pull request #254).
At least the Debian update-initramfs needs the entry to be there (see
pull request #254). Dracut will probably need it too. And logically, it
should be there.
locale -a returns the locales using ".utf8" names rather than ".UTF-8".
The case-insensitive match does not help because it is "utf8" rather
than "UTF-8". So we need to match both with and without the dash.
Pass the full name directly to useradd instead, using the "-c" (comment)
parameter, which is "currently used as the field for the user's full
name" according to the documentation.
The chfn utility is no longer installed by default on current Fedora
releases due to its dependency on libuser. (They split out chfn and chsh
from util-linux into an optional subpackage.) It could be added as a
dependency of Calamares, but since it is needed inside the chroot, it
has to be on the base live image, not the overlay. Thus, to allow
testing Calamares with a simple "dnf install calamares" again, the
dependency needs to go away. And it is unnecessary anyway.
These job plugins work similarly to view modules, with the following
differences:
* These jobs need to link only libcalamares, not libcalamaresui. For
this reason, PluginFactory was moved from libcalamaresui to
libcalamares. (It depends only on QtCore.)
* Instead of deriving from ViewModule, derive from CppJob (which is a
subclass of Job).
* Like process and Python jobs, a job plugin is a single job, whereas a
ViewModule can generate a whole list of jobs.
The CppJob and CppJobModule classes are new. In Module::fromDescriptor,
the combination type=job, intf=qtplugin is now supported and mapped to
CppJobModule.
locale -a returns the locales using ".utf8" names rather than ".UTF-8".
The case-insensitive match does not help because it is "utf8" rather
than "UTF-8". So we need to match both with and without the dash.
- 'chrootcfg' is used for our new netinstall approach
- it provides the needed function to install packages in a chroot
- we might need to optimize its progressbar visualization ...
Pass the full name directly to useradd instead, using the "-c" (comment)
parameter, which is "currently used as the field for the user's full
name" according to the documentation.
The chfn utility is no longer installed by default on current Fedora
releases due to its dependency on libuser. (They split out chfn and chsh
from util-linux into an optional subpackage.) It could be added as a
dependency of Calamares, but since it is needed inside the chroot, it
has to be on the base live image, not the overlay. Thus, to allow
testing Calamares with a simple "dnf install calamares" again, the
dependency needs to go away. And it is unnecessary anyway.