From 09aa447e441bde12e05fb86b377ab8123c905303 Mon Sep 17 00:00:00 2001
From: Alex Iribarren <Alex.Iribarren@cern.ch>
Date: Tue, 19 Jan 2021 18:51:56 +0100
Subject: [PATCH 1/3] Clean up some things that weren't working anyway

---
 c8-base-docker.ks | 15 ++++-----------
 1 file changed, 4 insertions(+), 11 deletions(-)

diff --git a/c8-base-docker.ks b/c8-base-docker.ks
index 5f4d951..248adb7 100644
--- a/c8-base-docker.ks
+++ b/c8-base-docker.ks
@@ -47,16 +47,8 @@ yum
 %end
 
 %post --log=/root/ks-post.log
-# randomize root password and lock root account
-dd if=/dev/urandom count=50 | md5sum | passwd --stdin root
-passwd -l root
-
-# create necessary devices
-/sbin/MAKEDEV /dev/console
-
 rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial
-rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-cern
-rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-8
+rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-centostesting
 rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-kojiv2
 
 # some packages get installed even though we ask for them not to be,
@@ -66,6 +58,9 @@ TOREMOVE="kernel kernel-core kernel-modules bind-export-libs dhcp-libs dhcp-clie
 
 for remove in $TOREMOVE; do echo -n "removing $remove: "; rpm -e --nodeps $remove; done
 
+LANG="en_US"
+echo "%_install_langs $LANG" > /etc/rpm/macros.image-language-conf
+
 rm -rf /etc/firewalld
 rm -rf /boot
 rm -f /etc/udev/hwdb.bin
@@ -75,8 +70,6 @@ rm -rf /var/lib/dnf/history.*
 
 #delete a few systemd things
 rm -rf /etc/machine-id
-rm -rf /usr/lib/systemd/system/multi-user.target.wants/getty.target
-rm -rf /usr/lib/systemd/system/multi-user.target.wants/systemd-logind.service
 
 # Add tsflags to keep yum from installing docs
 
-- 
GitLab


From 3efc4c911d96af097d20af11d2b19ba1887ec784 Mon Sep 17 00:00:00 2001
From: Alex Iribarren <Alex.Iribarren@cern.ch>
Date: Tue, 19 Jan 2021 18:52:55 +0100
Subject: [PATCH 2/3] Remove some packages that weren't installed anyway. Also
 stop removing iptables-libs, systemd breaks without it

---
 c8-base-docker.ks | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/c8-base-docker.ks b/c8-base-docker.ks
index 248adb7..aaf7135 100644
--- a/c8-base-docker.ks
+++ b/c8-base-docker.ks
@@ -54,7 +54,7 @@ rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-kojiv2
 # some packages get installed even though we ask for them not to be,
 # and they don't have any external dependencies that should make
 # anaconda install them
-TOREMOVE="kernel kernel-core kernel-modules bind-export-libs dhcp-libs dhcp-client dhcp-common dhcp-libs dracut-network e2fsprogs e2fsprogs-libs iptables-ebtables iptables-libs ethtool file firewalld freetype gettext gettext-libs grub2-tools-minimal grub2-tools-extra grub2-pc grub2-common grub2-pc-modules grub2-tools grubby iproute kexec-tools libcroco libgomp libmnl lzo os-prober python3-decorator python3-slip python3-slip-dbus snappy which linux-firmware"
+TOREMOVE="bind-export-libs dhcp-libs dhcp-client dhcp-common dracut-network ethtool file freetype gettext gettext-libs grub2-tools-minimal grub2-tools-extra grub2-common grub2-tools grubby iproute kexec-tools libcroco libgomp libmnl lzo os-prober snappy which"
 
 for remove in $TOREMOVE; do echo -n "removing $remove: "; rpm -e --nodeps $remove; done
 
-- 
GitLab


From 9acc500a6ed9ab118545dbc1fdbfdb09833facf4 Mon Sep 17 00:00:00 2001
From: Alex Iribarren <Alex.Iribarren@cern.ch>
Date: Fri, 22 Jan 2021 18:48:07 +0100
Subject: [PATCH 3/3] Clean up excludes

---
 upstreamcentostests.sh | 12 +++---------
 1 file changed, 3 insertions(+), 9 deletions(-)

diff --git a/upstreamcentostests.sh b/upstreamcentostests.sh
index 9df6ea0..dbf4942 100755
--- a/upstreamcentostests.sh
+++ b/upstreamcentostests.sh
@@ -27,19 +27,17 @@ cat > ./skipped-tests.list  <<DELIM
 #  - reason why it's actually skipped (url to upstream BZ, or bug report)
 # Separated by |
 8|tests/0_common/00_centos_repos.sh|We want to keep CERN repos enabled
-8|tests/0_common/05_stop_yumupdatesd.sh|No systemd therefore cannot be tested
 8|tests/0_common/20_upgrade_all.sh|Avoid too much noise on CI logs
 8|tests/0_common/30_dns_works.sh|Cannot test, we specifically remove libunistring package
 8|tests/p_arpwatch/10_arpwatch_test.sh|arpwatch always ends up in coredump in c8 but install is needed for posterior tests
 8|tests/p_audit/*|auditd not yet container ready
 8|tests/p_autofs/*|No NFS on containers
-8|tests/p_bind/0-install_bind.sh|No systemd therefore cannot be tested
 8|tests/p_bind/*|dig cannot find servers in c8 containers
 8|tests/p_bridge-utils/*|Not possible in a container
 8|tests/p_coreutils/*|Specificially removed on KS file for lightweight container, installed coreutils-single instead
 8|tests/p_cron/*|No systemd therefore cannot be tested
 8|tests/p_diffutils/10-cmp-tests|https://bugzilla.redhat.com/show_bug.cgi?id=1732960
-8|tests/p_dovecot/*|No rsyslog nor systemd installed so impossible to test
+8|tests/p_dovecot/*|Won't work because can't log in locally
 8|tests/p_exim/0-install_exim.sh|No systemd therefore cannot be tested
 8|tests/p_freeradius/*|No systemd therefore cannot be tested
 8|tests/p_gzip/30-gzexe-test|https://apps.centos.org/kanboard/project/23/task/833
@@ -54,7 +52,6 @@ cat > ./skipped-tests.list  <<DELIM
 8|tests/p_lsof/10-test_lsof.sh|No systemd therefore cannot be tested
 8|tests/p_mailman/*|No systemd therefore cannot be tested
 8|tests/p_mod_python/mod_python_test.sh
-8|tests/p_mod_wsgi/*|No systemd therefore cannot be tested
 8|tests/p_mysql/*|No systemd therefore cannot be tested
 8|tests/p_net-snmp/*|No systemd therefore cannot be tested
 8|tests/p_network/*|Cannot create VLAN in containers
@@ -65,13 +62,10 @@ cat > ./skipped-tests.list  <<DELIM
 8|tests/p_php/20-php-mysql-test.sh|No systemd therefore cannot be tested
 8|tests/p_php/25-php-mysql55-test.sh|No systemd therefore cannot be tested
 8|tests/p_php_*/*_mariadb.sh|No systemd therefore cannot be tested
-8|tests/p_postfix/40_postfix_sasl.sh|No systemd therefore cannot be tested
-8|tests/p_postfix/50_postfix_tls.sh|No systemd therefore cannot be tested
 8|tests/p_postfix/*|No systemd therefore cannot be tested
-8|tests/p_postgresql/1-config-postgresql.sh|No systemd therefore cannot be tested
 8|tests/p_postgresql/*|No systemd therefore cannot be tested
-8|tests/p_python/20-python-mysql-test.sh|No systemd therefore cannot be tested
-8|tests/p_python/25-python-mysql55-test.sh|No systemd therefore cannot be tested
+8|tests/p_python/20-python-mysql-test.sh|Can't connect to localhost
+8|tests/p_python/25-python-mysql55-test.sh|Can't connect to localhost
 8|tests/p_python3-mod_wsgi/10-test_python3-mod_wsgi.sh|No systemd therefore cannot be tested, added after https://gitlab.cern.ch/linuxsupport/testing/centos_functional_tests/-/commit/ff5c8768d1213a886c451ed9363a77a363c68d23
 8|tests/p_rsync/0-install-rsync.sh|No systemd therefore cannot be tested
 8|tests/p_rsync/10-rsync-test.sh|No systemd therefore cannot be tested
-- 
GitLab