diff --git a/crates/system-reinstall-bootc/Cargo.toml b/crates/system-reinstall-bootc/Cargo.toml index 921698e54..eef813543 100644 --- a/crates/system-reinstall-bootc/Cargo.toml +++ b/crates/system-reinstall-bootc/Cargo.toml @@ -32,6 +32,9 @@ tempfile = { workspace = true } tracing = { workspace = true } uzers = { workspace = true } +# Workspace dependencies (additional) +indicatif = { workspace = true } + # Crate-specific dependencies crossterm = "0.29.0" dialoguer = "0.12.0" diff --git a/crates/system-reinstall-bootc/src/main.rs b/crates/system-reinstall-bootc/src/main.rs index 3edf8cd49..28171d93d 100644 --- a/crates/system-reinstall-bootc/src/main.rs +++ b/crates/system-reinstall-bootc/src/main.rs @@ -85,6 +85,9 @@ fn run() -> Result<()> { prompt::temporary_developer_protection_prompt()?; + println!("Starting bootc installation. This may take several minutes..."); + println!(); + reinstall_podman_command .run_inherited_with_cmd_context() .context("running reinstall command")?; diff --git a/crates/system-reinstall-bootc/src/podman.rs b/crates/system-reinstall-bootc/src/podman.rs index 60dfefb52..52062dbe2 100644 --- a/crates/system-reinstall-bootc/src/podman.rs +++ b/crates/system-reinstall-bootc/src/podman.rs @@ -4,6 +4,7 @@ use super::ROOT_KEY_MOUNT_POINT; use anyhow::{Context, Result, ensure}; use bootc_utils::CommandRunExt; use fn_error_context::context; +use std::time::Duration; use std::process::Command; use which::which; @@ -80,7 +81,17 @@ pub(crate) fn reinstall_command(opts: &ReinstallOpts, ssh_key_file: &str) -> Res // bootc system for the first time. // This only happens if the bootc version in the image >= 1.1.8 (this is when the cleanup // feature was introduced) - if bootc_has_clean(&opts.image)? { + let spinner = indicatif::ProgressBar::new_spinner(); + spinner.set_style( + indicatif::ProgressStyle::default_spinner() + .template("{spinner} {msg}") + .unwrap(), + ); + spinner.set_message("Checking image capabilities..."); + spinner.enable_steady_tick(Duration::from_millis(150)); + let has_clean = bootc_has_clean(&opts.image)?; + spinner.finish_and_clear(); + if has_clean { bootc_command_and_args.push("--cleanup".to_string()); } @@ -172,4 +183,4 @@ pub(crate) fn ensure_podman_installed() -> Result<()> { ); Ok(()) -} +} \ No newline at end of file diff --git a/crates/tests-integration/Cargo.toml b/crates/tests-integration/Cargo.toml index 6306f508e..49a2c7f89 100644 --- a/crates/tests-integration/Cargo.toml +++ b/crates/tests-integration/Cargo.toml @@ -30,13 +30,13 @@ bootc-kernel-cmdline = { path = "../kernel_cmdline", version = "0.0.0" } # This is a git dependency — not published to crates.io. # When updating, also check the bcvk-qemu Cargo.toml for its own # dependency versions (cap-std-ext, etc.) to avoid conflicts. -bcvk-qemu = { git = "https://github.com/bootc-dev/bcvk", rev = "5c42e91250ab87502b7beeb2c7ea94a54ee8f5d9" } +bcvk-qemu = { git = "https://github.com/bootc-dev/bcvk", rev = "3b4dc84453d7ebac9e544d15931f0a9cd3d26215" } data-encoding = "2.9" indicatif = { workspace = true } libtest-mimic = "0.8.0" oci-spec = "0.9.0" rand = "0.10" -rexpect = "0.7" +rexpect = "0.6" scopeguard = "1.2.0" tar = "0.4" tokio = { workspace = true, features = ["rt", "macros"] }