From efe75eb994e31283d37f6196450dda8b6214214e Mon Sep 17 00:00:00 2001 From: Saverio Miroddi Date: Tue, 5 May 2020 23:04:53 +0200 Subject: [PATCH] New workflow for custom OS installation scripts In case of custom OS installations, the pools are now prepared before. There are two reasons for this: 1. there is no need to run them after, since we're not subject to Ubiquity's mess-ups; 2. custom installation scripts have the flexibility to install directly to a pool, as they're not subject to Ubiquity's limitations. --- install-zfs.sh | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/install-zfs.sh b/install-zfs.sh index 549eb2b..522935c 100755 --- a/install-zfs.sh +++ b/install-zfs.sh @@ -1356,15 +1356,19 @@ setup_partitions if [[ "${ZFS_OS_INSTALLATION_SCRIPT:-}" == "" ]]; then # Includes the O/S extra configuration, if necessary (network, root pwd, etc.) distro_dependent_invoke "install_operating_system" + + create_pools + create_swap_volume + sync_os_temp_installation_dir_to_rpool + remove_temp_partition_and_expand_rpool else + create_pools + create_swap_volume + remove_temp_partition_and_expand_rpool + custom_install_operating_system fi -create_pools -create_swap_volume -sync_os_temp_installation_dir_to_rpool -remove_temp_partition_and_expand_rpool - prepare_jail distro_dependent_invoke "install_jail_zfs_packages" distro_dependent_invoke "install_and_configure_bootloader"