From 4d2ebc754ed883b64cd4d119c11c510f44e73d0d Mon Sep 17 00:00:00 2001 From: RJ Trujillo Date: Sun, 7 Apr 2024 19:10:42 -0600 Subject: [PATCH] chore(cleanup): Remove NVIDIA configuration from non-NVIDIA images Removes NVIDIA dracut and modprobe configuration from non-NVIDIA images Signed-off-by: RJ Trujillo --- build_files/base/cleanup.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/build_files/base/cleanup.sh b/build_files/base/cleanup.sh index caedd6b99da..16f293df2bc 100644 --- a/build_files/base/cleanup.sh +++ b/build_files/base/cleanup.sh @@ -2,6 +2,11 @@ set -ouex pipefail +if [[ "${IMAGE_FLAVOR}" =~ "nvidia" ]]; then + rm /usr/etc/dracut.conf.d/nvidia.conf + rm /usr/lib/modprobe.d/nvidia.conf +fi + rm -f /etc/yum.repos.d/tailscale.repo rm -f /etc/yum.repos.d/charm.repo rm -f /etc/yum.repos.d/ublue-os-staging-fedora-"${FEDORA_MAJOR_VERSION}".repo @@ -11,4 +16,4 @@ echo "Hidden=true" >> /usr/share/applications/nvtop.desktop if [ "$BASE_IMAGE_NAME" = "silverblue" ]; then echo "Hidden=true" >> /usr/share/applications/gnome-system-monitor.desktop fi -rm -f /etc/yum.repos.d/_copr_che-nerd-fonts-"${FEDORA_MAJOR_VERSION}".repo \ No newline at end of file +rm -f /etc/yum.repos.d/_copr_che-nerd-fonts-"${FEDORA_MAJOR_VERSION}".repo