[grubcfg] Add configuration for default kernel_params

This commit is contained in:
dalto 2022-01-27 15:53:34 -06:00
parent 95122fdcf5
commit f65feedcce
3 changed files with 6 additions and 1 deletions

View file

@ -31,6 +31,10 @@ prefer_grub_d: false
# some way (e.g. uses shell-command substitution).
keepDistributor: false
# The default kernel params that should always be applied
# This is an array of strings
kernel_params: [ "quiet" ]
# Default entries to write to /etc/default/grub if it does not exist yet or if
# we are overwriting it.
#

View file

@ -9,6 +9,7 @@ properties:
overwrite: { type: boolean, default: false }
keepDistributor: { type: boolean, default: false }
prefer_grub_d: { type: boolean, default: false }
kernel_params: { type: array }
defaults:
type: object
additionalProperties: true # Other fields are acceptable

View file

@ -172,7 +172,7 @@ def modify_grub_default(partitions, root_mount_point, distributor):
if partition["fs"] == "zfs" and partition["mountPoint"] == "/":
zfs_root_path = get_zfs_root()
kernel_params = ["quiet"]
kernel_params = libcalamares.job.configuration.get("kernel_params", [])
# Currently, grub doesn't detect this properly so it must be set manually
if zfs_root_path: