diff --git a/README.md b/README.md index 7dc6976..54e188a 100644 --- a/README.md +++ b/README.md @@ -8,7 +8,7 @@ edited by hand if desired. An example configuration is provided with the reposit 1. Download a copy or clone this repo 1. Run `./configure` and save your configuration -1. When using encryption, export your desired key with `export GENTOO_INSTALL_ENCRYPTION_KEY="mypassword"` +1. When using encryption, export your desired key with `export GENTOO_INSTALL_ENCRYPTION_KEY='mypassword'` 1. Run installation using `./install` Every option is explained in detail in `gentoo.conf.example` and in the help menu popups in the configurator. diff --git a/TODO b/TODO index 25d3a87..65cde05 100644 --- a/TODO +++ b/TODO @@ -1,5 +1 @@ -- zfs support - - start systemd services - - create pool - - enable zstd - zfs selector dracut diff --git a/scripts/main.sh b/scripts/main.sh index d8dba2a..a5b0d45 100644 --- a/scripts/main.sh +++ b/scripts/main.sh @@ -123,6 +123,8 @@ function generate_initramfs() { && modules+=("crypt crypt-gpg") [[ $USED_BTRFS == "true" ]] \ && modules+=("btrfs") + [[ $USED_ZFS == "true" ]] \ + && modules+=("zfs") local kver kver="$(readlink /usr/src/linux)" \ @@ -144,7 +146,14 @@ function generate_initramfs() { } function get_cmdline() { - echo -n "rd.vconsole.keymap=$KEYMAP_INITRAMFS ${DISK_DRACUT_CMDLINE[*]} root=UUID=$(get_blkid_uuid_for_id "$DISK_ID_ROOT")" + local root_line + if [[ $USED_ZFS == "true" ]]; then + root_line="root=zfs:AUTO" + else + root_line="root=UUID=$(get_blkid_uuid_for_id "$DISK_ID_ROOT")" + fi + + echo -n "rd.vconsole.keymap=$KEYMAP_INITRAMFS ${DISK_DRACUT_CMDLINE[*]} $root_line" } function install_kernel_efi() {