mirror of
https://github.com/Start9Labs/start-os.git
synced 2026-04-01 04:53:40 +00:00
addHealthCheck instead of additionalHealthChecks for Daemons (#2962)
* addHealthCheck on Daemons * fix bug that prevents domains without protocols from being deleted * fixes from testing * version bump * add sdk version to UI * fix useEntrypoint * fix dependency health check error display * minor fixes * beta.29 * fixes from testing * beta.30 * set /etc/os-release (#2918) * remove check-monitor from kiosk (#2059) * add units for progress (#2693) * use new progress type * alpha.7 * fix up pwa stuff * fix wormhole-squashfs and prune boot (#2964) * don't exit on expected errors * use bash --------- Co-authored-by: Matt Hill <mattnine@protonmail.com>
This commit is contained in:
@@ -26,7 +26,9 @@ use crate::disk::mount::filesystem::MountType;
|
||||
use crate::disk::mount::guard::{GenericMountGuard, MountGuard, TmpMountGuard};
|
||||
use crate::notifications::{notify, NotificationLevel};
|
||||
use crate::prelude::*;
|
||||
use crate::progress::{FullProgressTracker, PhaseProgressTrackerHandle, PhasedProgressBar};
|
||||
use crate::progress::{
|
||||
FullProgressTracker, PhaseProgressTrackerHandle, PhasedProgressBar, ProgressUnits,
|
||||
};
|
||||
use crate::registry::asset::RegistryAsset;
|
||||
use crate::registry::context::{RegistryContext, RegistryUrlParams};
|
||||
use crate::registry::os::index::OsVersionInfo;
|
||||
@@ -195,9 +197,9 @@ pub async fn cli_update_system(
|
||||
}
|
||||
if let Some(mut prev) = prev {
|
||||
for phase in &mut prev.phases {
|
||||
phase.progress.complete();
|
||||
phase.progress.set_complete();
|
||||
}
|
||||
prev.overall.complete();
|
||||
prev.overall.set_complete();
|
||||
progress.update(&prev);
|
||||
}
|
||||
} else {
|
||||
@@ -265,6 +267,7 @@ async fn maybe_do_update(
|
||||
let prune_phase = progress.add_phase("Pruning Old OS Images".into(), Some(2));
|
||||
let mut download_phase = progress.add_phase("Downloading File".into(), Some(100));
|
||||
download_phase.set_total(asset.commitment.size);
|
||||
download_phase.set_units(Some(ProgressUnits::Bytes));
|
||||
let reverify_phase = progress.add_phase("Reverifying File".into(), Some(10));
|
||||
let sync_boot_phase = progress.add_phase("Syncing Boot Files".into(), Some(1));
|
||||
let finalize_phase = progress.add_phase("Finalizing Update".into(), Some(1));
|
||||
@@ -399,6 +402,9 @@ async fn do_update(
|
||||
.arg(asset.commitment.size.to_string())
|
||||
.invoke(ErrorKind::Filesystem)
|
||||
.await?;
|
||||
Command::new("/usr/lib/startos/scripts/prune-boot")
|
||||
.invoke(ErrorKind::Filesystem)
|
||||
.await?;
|
||||
prune_phase.complete();
|
||||
|
||||
download_phase.start();
|
||||
|
||||
Reference in New Issue
Block a user