From e3b1f5f546225c8b564235b157fe09aa9488eed1 Mon Sep 17 00:00:00 2001 From: rorka900 Date: Tue, 7 Apr 2026 17:16:28 +0300 Subject: feat(recipe): add maintainer field and group install steps --- src/rootfs.rs | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) (limited to 'src/rootfs.rs') diff --git a/src/rootfs.rs b/src/rootfs.rs index 3f06045..9af2e57 100644 --- a/src/rootfs.rs +++ b/src/rootfs.rs @@ -641,6 +641,33 @@ pub fn build_rootfs( let result = run_all_install_steps(&group.packages, &installing, target_dir); + if result.is_ok() && !group.install_steps.trim().is_empty() { + println!("{} Running group install_steps in chroot...", ">>>".cyan()); + let shell_result = find_working_shell(target_dir) + .ok_or_else(|| "No working shell found for group install_steps".to_string()); + match shell_result { + Ok((shell, subcmd)) => { + if let Err(e) = run_install_steps_in_chroot( + &group.name, + &group.install_steps, + target_dir, + shell, + subcmd, + ) { + println!("{} Unmounting virtual filesystems...", ">>>".cyan()); + umount_virtual_fs(target_dir); + return Err(e); + } + println!("{} Group install_steps done.", ">>>".green()); + } + Err(e) => { + println!("{} Unmounting virtual filesystems...", ">>>".cyan()); + umount_virtual_fs(target_dir); + return Err(e); + } + } + } + println!("{} Unmounting virtual filesystems...", ">>>".cyan()); umount_virtual_fs(target_dir); -- cgit v1.2.3