#1008 container-toolbox: Restore and update the tests
Merged 6 months ago by humaton. Opened 7 months ago by rishi.

file modified
+49 -30
@@ -161,6 +161,55 @@ 

  # Final pruning

  rm -rfv /var/cache/* /var/log/* /tmp/*

  

+ # Check if specified files exist

+ declare -a files=(

+  # bash

+  "/usr/share/man/man1/bash.1*"

+  "/usr/share/man/man1/cd.1*"

+  "/usr/share/man/man1/export.1*"

+  # coreutils-common

+  "/usr/share/man/man1/cat.1*"

+  "/usr/share/man/man1/cp.1*"

+  "/usr/share/man/man1/ls.1*"

+  # gnupg2

+  "/usr/share/man/man1/gpg2.1*"

+  "/usr/share/man/man7/gnupg2.7*"

+  # psmisc

+  "/usr/share/man/fr/man1/pstree.1*"

+  "/usr/share/man/ko/man1/pstree.1*"

+  "/usr/share/man/man1/pstree.1*"

+  # rpm

+  "/usr/share/man/man8/rpm.8*"

+  "/usr/share/man/man8/rpm2cpio.8*"

+  # shadow-utils

+  "/usr/share/man/fr/man8/useradd.8*"

+  "/usr/share/man/ja/man8/useradd.8*"

+  "/usr/share/man/man8/useradd.8*"

+  # util-linux

+  "/usr/share/man/man1/cal.1.*"

+  "/usr/share/man/man1/getopt.1*"

+  "/usr/share/man/man1/hexdump.1*"

+  # util-linux-core

+  "/usr/share/man/man1/kill.1*"

+  "/usr/share/man/man8/mount.8*"

+  # xz

+  "/usr/share/man/fr/man1/xz.1*"

+  "/usr/share/man/ko/man1/xz.1*"

+  "/usr/share/man/man1/xz.1*"

+ )

+ 

+ ret_val=0

+ for file in "${files[@]}"; do

+  if ! compgen -G "$file" >/dev/null; then

+    echo "$file: No such file or directory" >&2

+    ret_val=1

+    break

+  fi

+ done

+ 

+ if [ "$ret_val" -ne 0 ]; then

+  false

+ fi

  %end

  

  # Perform any necessary post-installation configurations specific to Fedora Toolbox (nochroot environment)
@@ -169,36 +218,6 @@ 

  %post --nochroot --erroronfail --log=/mnt/sysimage/root/anaconda-post-nochroot.log

  set -eux

  

- # Check if specified files exist

- #declare -a files=(

- #  "/usr/share/man/man1/bash.1*"

- #  "/usr/share/man/man1/cd.1*"

- #  "/usr/share/man/man1/export.1*"

- #  "/usr/share/man/man1/cat.1*"

- #  "/usr/share/man/man1/cp.1*"

- #  "/usr/share/man/man1/ls.1*"

- #  "/usr/share/man/man1/gpg2.1*"

- #  "/usr/share/man/man7/gnupg2.7*"

- #  "/usr/share/man/fr/man8/rpm.8*"

- #  "/usr/share/man/ja/man8/rpm.8*"

- #  "/usr/share/man/man8/rpm.8*"

- #  "/usr/share/man/man1/kill.1*"

- #  "/usr/share/man/man8/mount.8*"

- #)

- 

- #ret_val=0

- #for file in "${files[@]}"; do

- #  if ! compgen -G "$file" >/dev/null; then

- #    echo "$file: No such file or directory" >&2

- #    ret_val=1

- #    break

- #  fi

- #done

- 

- #if [ "$ret_val" -ne 0 ]; then

- #  false

- #fi

- 

  # Clean up dnf cache

  dnf clean all

  

This is NOT meant for Fedora 39. It's purely aimed at Fedora 40.

rebased onto 7725ee8

7 months ago

Pull-Request has been merged by humaton

6 months ago
Metadata