Skip to content

Commit c31f58d

Browse files
committed
test: Fix OSCI gating failure
Signed-off-by: Xiaofeng Wang <[email protected]>
1 parent 52f49b5 commit c31f58d

File tree

3 files changed

+19
-4
lines changed

3 files changed

+19
-4
lines changed

hack/Containerfile.packit

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,6 @@ FROM quay.io/centos-bootc/centos-bootc:stream10
55

66
WORKDIR /bootc-test
77

8-
# Some rhts-*, rstrnt-* and tmt-* commands are in /usr/local/bin
9-
COPY bin /usr/local/bin
108
# Save testing farm run files
119
COPY ARTIFACTS /var/ARTIFACTS
1210
# Copy bootc repo
@@ -19,8 +17,20 @@ set -xeuo pipefail
1917
if [[ $ID == "rhel" ]]; then
2018
cp rhel.repo /etc/yum.repos.d/
2119
fi
20+
# OSCI uses /var/lib/tmt/scripts to save tmt-* commands
21+
# Fedora CI and Packit use /usr/local/bin
22+
if [[ -d scripts ]]; then
23+
mkdir -p /var/lib/tmt
24+
cp -r scripts /var/lib/tmt/
25+
ls -al /var/lib/tmt/scripts
26+
else
27+
cp -r bin /usr/local
28+
ls -al /usr/local/bin
29+
fi
2230
cp test-artifacts.repo /etc/yum.repos.d/
2331
dnf -y update bootc
32+
# Required by tmt avc checking after test
33+
dnf -y install audit
2434
./provision-derived.sh
2535

2636
# For test-22-logically-bound-install

hack/packit-reboot.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,9 @@
77
tasks:
88
- name: Reboot system to image mode
99
reboot:
10+
reboot_timeout: 1200
11+
connect_timeout: 30
12+
pre_reboot_delay: 15
1013

1114
- name: Wait for connection to become reachable/usable
1215
wait_for_connection:

hack/provision-packit.sh

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,13 +24,15 @@ source /etc/os-release
2424
# Some rhts-*, rstrnt-* and tmt-* commands are in /usr/local/bin
2525
if [[ -d /var/lib/tmt/scripts ]]; then
2626
cp -r /var/lib/tmt/scripts "$BOOTC_TEMPDIR"
27+
ls -al "${BOOTC_TEMPDIR}/scripts"
2728
else
2829
cp -r /usr/local/bin "$BOOTC_TEMPDIR"
30+
ls -al "${BOOTC_TEMPDIR}/bin"
2931
fi
3032

3133
# Get base image URL
3234
TEST_OS="${ID}-${VERSION_ID}"
33-
BASE=$(cat os-image-map.json | jq --arg v "$TEST_OS" '.[$v]')
35+
BASE=$(cat os-image-map.json | jq -r --arg v "$TEST_OS" '.[$v]')
3436

3537
if [[ "$ID" == "rhel" ]]; then
3638
# OSCI gating only
@@ -78,7 +80,7 @@ ls -al /var/share/test-artifacts
7880
cp /etc/yum.repos.d/test-artifacts.repo "$BOOTC_TEMPDIR"
7981

8082
# Let's check things in hack folder
81-
ls -al "$BOOTC_TEMPDIR" "${BOOTC_TEMPDIR}/bin"
83+
ls -al "$BOOTC_TEMPDIR"
8284

8385
# Do not use just because it's only available on Fedora, not on CS and RHEL
8486
podman build --jobs=4 --from "$BASE" -v "$BOOTC_TEMPDIR":/bootc-test:z -t localhost/bootc-integration -f "${BOOTC_TEMPDIR}/Containerfile.packit" "$BOOTC_TEMPDIR"

0 commit comments

Comments
 (0)