diff --git a/src/bootupd.rs b/src/bootupd.rs index c9ffae4e..ece96a94 100644 --- a/src/bootupd.rs +++ b/src/bootupd.rs @@ -24,7 +24,7 @@ mod util; /// Stored in /boot to describe our state; think of it like /// a tiny rpm/dpkg database. -pub(crate) const STATEFILE_PATH: &str = "boot/rpmostree-bootupd-state.json"; +pub(crate) const STATEFILE_PATH: &str = "boot/bootupd-state.json"; /// Where rpm-ostree rewrites data that goes in /boot pub(crate) const OSTREE_BOOT_DATA: &str = "usr/lib/ostree-boot"; diff --git a/src/model.rs b/src/model.rs index 0630de88..97d2f303 100644 --- a/src/model.rs +++ b/src/model.rs @@ -108,7 +108,6 @@ pub(crate) struct SavedPendingUpdate { pub(crate) timestamp: NaiveDateTime, } -/// Will be serialized into /boot/rpmostree-bootupd-state.json #[derive(Serialize, Deserialize, Debug, Clone)] #[serde(rename_all = "kebab-case")] pub(crate) struct SavedComponent { @@ -119,23 +118,23 @@ pub(crate) struct SavedComponent { pub(crate) pending: Option, } -/// Will be serialized into /boot/rpmostree-bootupd-state.json +/// Will be serialized into /boot/bootupd-state.json #[derive(Serialize, Deserialize, Debug)] #[serde(rename_all = "kebab-case")] pub(crate) struct SavedState { pub(crate) components: BTreeMap, } -/// Should be stored in /usr/lib/rpm-ostree/bootupdate-edge.json -#[derive(Serialize, Deserialize, Debug)] -#[serde(rename_all = "kebab-case")] -pub(crate) struct UpgradeEdge { - /// Set to true if we should upgrade from an unknown state - #[serde(default)] - pub(crate) from_unknown: bool, - /// Upgrade from content past this timestamp - pub(crate) from_timestamp: Option, -} +// Should be stored in /usr/lib/bootupd/edges.json +//#[derive(Serialize, Deserialize, Debug)] +// #[serde(rename_all = "kebab-case")] +// pub(crate) struct UpgradeEdge { +// /// Set to true if we should upgrade from an unknown state +// #[serde(default)] +// pub(crate) from_unknown: bool, +// /// Upgrade from content past this timestamp +// pub(crate) from_timestamp: Option, +// } impl InstalledContent { pub(crate) fn from_file_tree(ft: FileTree) -> InstalledContent { diff --git a/tests/unpriv-blackbox.sh b/tests/unpriv-blackbox.sh index b90a7f4a..689a3739 100755 --- a/tests/unpriv-blackbox.sh +++ b/tests/unpriv-blackbox.sh @@ -113,7 +113,7 @@ assert_file_has_content_literal out.txt 'Update: At latest version' ok 'adoption status' # Re-initialize and adopt with extra state -rm -v root/boot/rpmostree-bootupd-state.json +rm -v root/boot/bootupd-state.json initefiroot "${bootefi}" initefiroot "${ostefi}"