diff --git a/.gitignore b/.gitignore index fc0ad6b..23a5fe6 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,3 @@ -SOURCES/coreos-installer-0.24.0-vendor.tar.gz -SOURCES/coreos-installer-0.24.0.crate +SOURCES/coreos-installer-0.25.0-vendor.tar.gz +SOURCES/coreos-installer-0.25.0.crate SOURCES/coreos-installer-dracut-7181733.tar.gz diff --git a/.rust-coreos-installer.metadata b/.rust-coreos-installer.metadata index 0dcae9c..e3401ca 100644 --- a/.rust-coreos-installer.metadata +++ b/.rust-coreos-installer.metadata @@ -1,3 +1,3 @@ -307f1eb756f210a77b4b2a01b8faa60ea002fc8e SOURCES/coreos-installer-0.24.0-vendor.tar.gz -5510e9d6acbc963085347e8ba60250b186712da1 SOURCES/coreos-installer-0.24.0.crate +5e2042011322bd9601db698ac5e5a24160e65b7b SOURCES/coreos-installer-0.25.0-vendor.tar.gz +f5df6eef51d19c5e2c890541a2abac6588f40f86 SOURCES/coreos-installer-0.25.0.crate 81f96c32efa9e32730e1f3bda5a820d33229f006 SOURCES/coreos-installer-dracut-7181733.tar.gz diff --git a/SOURCES/0001-install-check-if-firstboot-args-are-defined-and-add-.patch b/SOURCES/0001-install-check-if-firstboot-args-are-defined-and-add-.patch new file mode 100644 index 0000000..407c255 --- /dev/null +++ b/SOURCES/0001-install-check-if-firstboot-args-are-defined-and-add-.patch @@ -0,0 +1,39 @@ +From 580c6d817853ba59491a94e00dd1513f397dbbe1 Mon Sep 17 00:00:00 2001 +From: yasminvalim +Date: Mon, 13 Oct 2025 10:44:55 -0300 +Subject: [PATCH 1/2] install: check if firstboot args are defined and add them + manually if necessary + +--- + src/cmdline/install.rs | 8 +++++++- + 1 file changed, 7 insertions(+), 1 deletion(-) + +diff --git a/src/cmdline/install.rs b/src/cmdline/install.rs +index 885ca73..206d602 100644 +--- a/src/cmdline/install.rs ++++ b/src/cmdline/install.rs +@@ -272,7 +272,7 @@ impl InstallConfig { + return Ok(self); + } + +- let args = self ++ let mut args = self + .config_file + .iter() + .map(|path| { +@@ -295,6 +295,12 @@ impl InstallConfig { + ) + .collect::>(); + ++ // If firstboot-args is defined, add it manually ++ if let Some(firstboot_args) = &self.firstboot_args { ++ args.push("--firstboot-args".to_string()); ++ args.push(firstboot_args.clone()); ++ } ++ + println!("Running with arguments: {}", args.join(" ")); + Self::from_args(&args) + } +-- +2.52.0 + diff --git a/SOURCES/0002-install-add-unit-tests.patch b/SOURCES/0002-install-add-unit-tests.patch new file mode 100644 index 0000000..5ebcd47 --- /dev/null +++ b/SOURCES/0002-install-add-unit-tests.patch @@ -0,0 +1,48 @@ +From b3dd98122d91ae4c025a11fd7be9c75f49cf6a26 Mon Sep 17 00:00:00 2001 +From: yasminvalim +Date: Mon, 13 Oct 2025 11:42:48 -0300 +Subject: [PATCH 2/2] install: add unit tests + +(cherry picked from commit 26094bf552f5ddf3fec974c1f7e7b468bbe4b9e6) +--- + src/cmdline/install.rs | 26 ++++++++++++++++++++++++++ + 1 file changed, 26 insertions(+) + +diff --git a/src/cmdline/install.rs b/src/cmdline/install.rs +index 206d602..915db59 100644 +--- a/src/cmdline/install.rs ++++ b/src/cmdline/install.rs +@@ -584,4 +584,30 @@ dest-device: u + .expand_config_files() + .unwrap_err(); + } ++ ++ /// Test that firstboot-args is manually added to args list when defined ++ #[test] ++ fn test_firstboot_args_manually_added() { ++ let mut f = NamedTempFile::new().unwrap(); ++ f.as_file_mut().write_all(b"dest-device: /dev/sda").unwrap(); ++ ++ let config = InstallConfig::from_args(&[ ++ "--config-file", ++ f.path().to_str().unwrap(), ++ "--firstboot-args", ++ "ip=dhcp", ++ ]) ++ .unwrap(); ++ ++ // Verify firstboot-args is defined ++ assert!(config.firstboot_args.is_some()); ++ assert_eq!(config.firstboot_args.as_ref().unwrap(), "ip=dhcp"); ++ ++ // Test expand_config_files to verify manual addition ++ let expanded = config.expand_config_files().unwrap(); ++ ++ // Should still have firstboot-args ++ assert!(expanded.firstboot_args.is_some()); ++ assert_eq!(expanded.firstboot_args.unwrap(), "ip=dhcp"); ++ } + } +-- +2.52.0 + diff --git a/SPECS/rust-coreos-installer.spec b/SPECS/rust-coreos-installer.spec index 2d591f8..bf66585 100644 --- a/SPECS/rust-coreos-installer.spec +++ b/SPECS/rust-coreos-installer.spec @@ -11,8 +11,8 @@ %global crate coreos-installer Name: rust-%{crate} -Version: 0.24.0 -Release: 1%{?dist} +Version: 0.25.0 +Release: 2%{?dist} Summary: Installer for Fedora CoreOS and RHEL CoreOS # Upstream license specification: Apache-2.0 @@ -23,6 +23,10 @@ Source0: https://crates.io/api/v1/crates/%{crate}/%{version}/download#/%{ Source1: https://github.com/coreos/%{crate}/releases/download/v%{version}/%{crate}-%{version}-vendor.tar.gz Source2: https://github.com/coreos/coreos-installer-dracut/archive/%{dracutcommit}/coreos-installer-dracut-%{dracutshortcommit}.tar.gz +# https://github.com/coreos/coreos-installer/pull/1699 +Patch0: 0001-install-check-if-firstboot-args-are-defined-and-add-.patch +Patch1: 0002-install-add-unit-tests.patch + ExclusiveArch: %{rust_arches} %if 0%{?rhel} && !0%{?eln} BuildRequires: rust-toolset @@ -173,6 +177,20 @@ from the initramfs. %endif %changelog +* Tue Dec 23 2025 Yasmin Valim - 0.25.0-2 +- Backport https://github.com/coreos/coreos-installer/pull/1699 + +* Mon Oct 13 2025 Yasmin Valim - 0.25.0-1 +- new version + +* Wed Jul 23 2025 Joel Capitao - 0.24.0-3 +- Use the full path for the 'root=' kernel arg when rootfs on mpath + Backport https://github.com/coreos/coreos-installer/pull/1677 + +* Fri Jul 18 2025 Aashish Radhakrishnan - 0.24.0-2 +- Restore single-decimal precision to stream output + Backport https://github.com/coreos/coreos-installer/pull/1654 + * Wed Apr 16 2025 Joel Capitao - 0.24.0-1 - Update to latest upstream