diff --git a/hack/os-image-map.json b/hack/os-image-map.json index 661558b1b..80ab247c4 100644 --- a/hack/os-image-map.json +++ b/hack/os-image-map.json @@ -1,5 +1,7 @@ { "base": { + "rhel-10.2": "images.paas.redhat.com/bootc/rhel-bootc:latest-10.2", + "rhel-9.8": "images.paas.redhat.com/bootc/rhel-bootc:latest-9.8", "centos-9": "quay.io/centos-bootc/centos-bootc:stream9", "centos-10": "quay.io/centos-bootc/centos-bootc:stream10", "fedora-42": "quay.io/fedora/fedora-bootc:42", diff --git a/tmt/tests/booted/test-soft-reboot-selinux-policy.nu b/tmt/tests/booted/test-soft-reboot-selinux-policy.nu index ca06efeae..d5a057e76 100644 --- a/tmt/tests/booted/test-soft-reboot-selinux-policy.nu +++ b/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