From 4cf6bd349d05d7d2eb0fbf5ee18a5698e38ddef4 Mon Sep 17 00:00:00 2001 From: Joseph Marrero Corchado Date: Fri, 5 Dec 2025 15:07:12 -0500 Subject: [PATCH] Release 1.11.0 Resolves: #RHEL-134017 Resolves: #RHEL-130799 Resolves: #RHEL-131317 Signed-off-by: Xiaofeng Wang --- .gitignore | 2 + 0000-test-soft-reboot-selinux-policy.patch | 36 +++++++++ Containerfile.packit | 53 ------------ bootc.spec | 77 +++++++++++++----- os-image-map.json | 18 +++++ plans/all.fmf | 57 +++++++------ provision-packit.sh | 93 ---------------------- sources | 4 +- 8 files changed, 146 insertions(+), 194 deletions(-) create mode 100644 0000-test-soft-reboot-selinux-policy.patch delete mode 100644 Containerfile.packit create mode 100644 os-image-map.json delete mode 100755 provision-packit.sh diff --git a/.gitignore b/.gitignore index 943ecf6..2344bea 100644 --- a/.gitignore +++ b/.gitignore @@ -46,3 +46,5 @@ /bootc-1.8.0.tar.zstd /bootc-1.10.0.tar.zstd /bootc-1.10.0-vendor.tar.zstd +/bootc-1.11.0.tar.zstd +/bootc-1.11.0-vendor.tar.zstd diff --git a/0000-test-soft-reboot-selinux-policy.patch b/0000-test-soft-reboot-selinux-policy.patch new file mode 100644 index 0000000..9017511 --- /dev/null +++ b/0000-test-soft-reboot-selinux-policy.patch @@ -0,0 +1,36 @@ +diff --git i/tmt/tests/booted/test-soft-reboot-selinux-policy.nu w/tmt/tests/booted/test-soft-reboot-selinux-policy.nu +index ca06efea..d5a057e7 100644 +--- i/tmt/tests/booted/test-soft-reboot-selinux-policy.nu ++++ w/tmt/tests/booted/test-soft-reboot-selinux-policy.nu +@@ -32,11 +32,30 @@ def initial_build [] { + + bootc image copy-to-storage + ++ # copy-to-storage does not copy repo file ++ # but OSCI gating test needs repo to install package ++ let os = open /usr/lib/os-release ++ | lines ++ | filter {|l| $l != "" and not ($l | str starts-with "#") } ++ | parse "{key}={value}" ++ | reduce {|it, acc| ++ $acc | upsert $it.key ($it.value | str trim -c '"') ++ } ++ mut repo_copy = "" ++ ++ if $os.ID == "rhel" { ++ cp /etc/yum.repos.d/rhel.repo . ++ $repo_copy = "COPY rhel.repo /etc/yum.repos.d/" ++ } ++ + # Create a derived container that installs a custom SELinux policy module + # Installing a policy module will change the compiled policy checksum + # Following Colin's suggestion and the composefs-rs example + # We create a minimal policy module and install it +- "FROM localhost/bootc ++ $" ++FROM localhost/bootc ++($repo_copy) ++ + # Install tools needed to build and install SELinux policy modules + RUN dnf install -y selinux-policy-devel checkpolicy policycoreutils + diff --git a/Containerfile.packit b/Containerfile.packit deleted file mode 100644 index 0b5c40c..0000000 --- a/Containerfile.packit +++ /dev/null @@ -1,53 +0,0 @@ -# Build image for system-reinstall-bootc test - -# Use centos-bootc:stream10 as default -FROM quay.io/centos-bootc/centos-bootc:stream10 - -WORKDIR /bootc-test - -# Save testing farm run files -COPY ARTIFACTS /var/ARTIFACTS -# Copy bootc repo -COPY test-artifacts /var/share/test-artifacts - -ARG GATING -RUN <= 9 || 0%{?fedora} > 41 %bcond_without ostree_ext %else @@ -21,7 +22,7 @@ %endif Name: bootc -Version: 1.10.0 +Version: 1.11.0 Release: %{autorelease} Summary: Bootable container system @@ -38,6 +39,9 @@ URL: https://github.com/bootc-dev/bootc Source0: %{url}/releases/download/v%{version}/bootc-%{version}.tar.zstd Source1: %{url}/releases/download/v%{version}/bootc-%{version}-vendor.tar.zstd +# Patch for test-soft-reboot-selinux-policy +Patch0: 0000-test-soft-reboot-selinux-policy.patch + # https://fedoraproject.org/wiki/Changes/EncourageI686LeafRemoval ExcludeArch: %{ix86} @@ -84,52 +88,73 @@ Recommends: podman %description -n system-reinstall-bootc This package provides a utility to simplify reinstalling the current system to a given bootc image. +%if %{with tests} +%package tests +Summary: Integration tests for bootc +Requires: %{name} = %{version}-%{release} + +%description tests +This package contains the integration test suite for bootc. +%endif + %global system_reinstall_bootc_install_podman_path %{_prefix}/lib/system-reinstall-bootc/install-podman +%if 0%{?container_build} +# Source is already at /src, no subdirectory +%global _buildsubdir . +%endif + %prep +%if ! 0%{?container_build} %autosetup -p1 -a1 # Default -v vendor config doesn't support non-crates.io deps (i.e. git) cp .cargo/vendor-config.toml . %cargo_prep -N cat vendor-config.toml >> .cargo/config.toml rm vendor-config.toml +%else +# Container build: source already at _builddir (/src), nothing to extract +# RPM's %mkbuilddir creates a subdirectory; symlink it back to the source +cd .. +rm -rf %{name}-%{version}-build +ln -s . %{name}-%{version}-build +cd %{name}-%{version}-build +%endif %build -# Build the main bootc binary -%if %new_cargo_macros - %cargo_build %{?with_rhsm:-f rhsm} -%else - %cargo_build %{?with_rhsm:--features rhsm} -%endif - -# Build the system reinstallation CLI binary -%global cargo_args -p system-reinstall-bootc export SYSTEM_REINSTALL_BOOTC_INSTALL_PODMAN_PATH=%{system_reinstall_bootc_install_podman_path} -%if %new_cargo_macros - # In cargo-rpm-macros, the cargo_build macro does flag processing, - # so we need to pass '--' to signify that cargo_args is not part - # of the macro args - %cargo_build -- %cargo_args -%else - # Older macros from rust-toolset do *not* do flag processing, so - # '--' would be passed through to cargo directly, which is not - # what we want. - %cargo_build %cargo_args -%endif - +# Build this first to avoid feature skew make manpages +# Build all binaries +%if 0%{?container_build} +# Container build: use cargo directly with cached dependencies to avoid RPM macro overhead +cargo build -j%{_smp_build_ncpus} --release %{?with_rhsm:--features rhsm} --bins +%else +# Non-container build: use RPM macros for proper dependency tracking +%if %new_cargo_macros + %cargo_build %{?with_rhsm:-f rhsm} -- --bins +%else + %cargo_build %{?with_rhsm:--features rhsm} -- --bins +%endif +%endif + +%if ! 0%{?container_build} %cargo_vendor_manifest # https://pagure.io/fedora-rust/rust-packaging/issue/33 sed -i -e '/https:\/\//d' cargo-vendor.txt %cargo_license_summary %{cargo_license} > LICENSE.dependencies +%endif %install %make_install INSTALL="install -p -c" %if %{with ostree_ext} make install-ostree-hooks DESTDIR=%{?buildroot} %endif +%if %{with tests} +install -D -m 0755 target/release/tests-integration %{buildroot}%{_bindir}/bootc-integration-tests +%endif mkdir -p %{buildroot}/%{dirname:%{system_reinstall_bootc_install_podman_path}} cat >%{?buildroot}/%{system_reinstall_bootc_install_podman_path} </dev/null <