2011-05-05 22:24:58 +00:00
|
|
|
## lorax template file: cleanup for the ramdisk (runtime image)
|
2021-05-03 18:26:37 +00:00
|
|
|
<%page args="libdir, branding, root"/>
|
2011-05-05 22:24:58 +00:00
|
|
|
|
2012-06-13 22:04:17 +00:00
|
|
|
## remove the sources
|
|
|
|
remove usr/share/i18n
|
2011-05-05 22:24:58 +00:00
|
|
|
|
|
|
|
## not required packages installed as dependencies
|
2017-07-28 17:52:16 +00:00
|
|
|
## perl is needed on s390x
|
2019-01-02 09:16:17 +00:00
|
|
|
## perl needed for powerpc-utils
|
2017-07-28 17:52:16 +00:00
|
|
|
## perl is needed by /usr/bin/rxe_cfg from libibverbs
|
|
|
|
|
2011-08-09 21:33:27 +00:00
|
|
|
## no sound support, thanks
|
2020-09-10 22:50:02 +00:00
|
|
|
removepkg flac-libs libsndfile pulseaudio* sound-theme-freedesktop
|
2011-08-09 21:33:27 +00:00
|
|
|
## we don't create new initramfs/bootloader conf inside anaconda
|
|
|
|
## (that happens inside the target system after we install dracut/grubby)
|
2012-02-16 19:58:13 +00:00
|
|
|
removepkg dracut-network grubby anaconda-dracut
|
2012-02-08 00:18:39 +00:00
|
|
|
## In order to execute the /usr move on upgrades we need convertfs from dracut
|
2012-06-17 19:16:05 +00:00
|
|
|
## We also need dracut-shutdown.service and dracut-initramfs-restore to reboot
|
|
|
|
removefrom dracut --allbut /usr/lib/dracut/modules.d/30convertfs/convertfs.sh \
|
2012-09-06 22:29:45 +00:00
|
|
|
/usr/lib/dracut/modules.d/99base/dracut-lib.sh \
|
2020-02-21 18:55:10 +00:00
|
|
|
/usr/lib/systemd/* /usr/lib/dracut/modules.d/98dracut-systemd/*.service \
|
2013-07-30 12:47:16 +00:00
|
|
|
/usr/lib/dracut/dracut-initramfs-restore
|
2011-08-09 21:33:27 +00:00
|
|
|
## we don't run SELinux (not in enforcing, anyway)
|
2020-09-10 22:50:02 +00:00
|
|
|
removepkg selinux-policy libselinux-utils
|
2015-07-17 00:03:03 +00:00
|
|
|
|
|
|
|
## selinux checks for the /etc/selinux/config file's existance
|
|
|
|
## The removepkg above removes it, create an empty one. See rhbz#1243168
|
|
|
|
append etc/selinux/config ""
|
|
|
|
|
2013-04-26 15:56:20 +00:00
|
|
|
removepkg fedora-release-rawhide
|
2015-08-20 18:17:08 +00:00
|
|
|
|
|
|
|
## keep enough of shadow-utils to create accounts
|
|
|
|
removefrom shadow-utils --allbut /usr/bin/chage /usr/sbin/chpasswd \
|
|
|
|
/usr/sbin/groupadd /usr/sbin/useradd
|
|
|
|
|
2011-08-31 23:32:37 +00:00
|
|
|
## no services to turn on/off (keep the /etc/init.d link though)
|
2020-02-21 18:55:10 +00:00
|
|
|
removefrom initscripts /usr/sbin/* /usr/share/locale/* /usr/share/doc/* /usr/share/man/*
|
|
|
|
|
2011-08-09 21:33:27 +00:00
|
|
|
## no storage device monitoring
|
|
|
|
removepkg device-mapper-event dmraid-events sgpio
|
2011-08-29 18:41:09 +00:00
|
|
|
## logrotate isn't useful in anaconda
|
|
|
|
removepkg logrotate
|
|
|
|
remove /etc/logrotate.d
|
2012-07-02 15:08:39 +00:00
|
|
|
## anaconda needs this to do media check
|
|
|
|
removefrom isomd5sum --allbut /usr/bin/checkisomd5
|
2011-08-09 21:33:27 +00:00
|
|
|
|
2015-07-20 13:01:01 +00:00
|
|
|
## systemd-nspawn isn't very useful and doesn't link anyway without iptables,
|
|
|
|
## and there's no need for a bunch of zsh files without zsh
|
2020-09-10 22:50:02 +00:00
|
|
|
removefrom systemd /usr/share/zsh/site-functions/*
|
2015-07-20 13:01:01 +00:00
|
|
|
|
2011-08-09 21:33:27 +00:00
|
|
|
## various other things we remove to save space
|
2020-09-10 22:50:02 +00:00
|
|
|
removepkg diffutils file
|
|
|
|
removepkg jasper-libs
|
|
|
|
removepkg libasyncns
|
2021-05-03 17:07:14 +00:00
|
|
|
removepkg libtiff
|
|
|
|
removepkg lvm2-libs
|
2020-09-10 22:50:02 +00:00
|
|
|
removepkg mobile-broadband-provider-info
|
|
|
|
removepkg pkgconf pkgconf-m4 pkgconf-pkg-config ppp pth
|
2012-06-04 08:10:43 +00:00
|
|
|
removepkg rmt rpcbind squashfs-tools system-config-firewall-base
|
2020-09-10 22:50:02 +00:00
|
|
|
removepkg tigervnc-license xml-common xorg-x11-font-utils
|
|
|
|
removepkg xorg-x11-server-common
|
2020-09-28 19:19:05 +00:00
|
|
|
removepkg ncurses
|
2011-05-05 22:24:58 +00:00
|
|
|
|
|
|
|
## other removals
|
2017-08-14 20:20:27 +00:00
|
|
|
remove /home /media /opt /srv /tmp/*
|
2011-06-23 21:45:12 +00:00
|
|
|
remove /usr/etc /usr/games /usr/local /usr/tmp
|
2014-10-07 15:41:20 +00:00
|
|
|
remove /usr/share/doc /usr/share/info /usr/share/man /usr/share/gnome
|
2011-06-22 18:20:02 +00:00
|
|
|
remove /usr/share/mime/application /usr/share/mime/audio /usr/share/mime/image
|
|
|
|
remove /usr/share/mime/inode /usr/share/mime/message /usr/share/mime/model
|
|
|
|
remove /usr/share/mime/multipart /usr/share/mime/packages /usr/share/mime/text
|
|
|
|
remove /usr/share/mime/video /usr/share/mime/x-content /usr/share/mime/x-epoc
|
2011-06-23 21:45:12 +00:00
|
|
|
remove /var/db /var/games /var/tmp /var/yp /var/nis /var/opt /var/local
|
|
|
|
remove /var/mail /var/spool /var/preserve /var/report
|
2016-03-15 21:13:43 +00:00
|
|
|
remove /var/lib/rpm/* /var/lib/yum /var/lib/dnf
|
2016-03-15 21:13:56 +00:00
|
|
|
## clean up the files created by various '> /dev/null's
|
|
|
|
remove /dev/*
|
2011-05-05 22:24:58 +00:00
|
|
|
|
|
|
|
## icons cache
|
2011-05-13 17:06:03 +00:00
|
|
|
remove /usr/share/icons/*/icon-theme.cache
|
2011-05-05 22:24:58 +00:00
|
|
|
|
2011-06-23 21:31:53 +00:00
|
|
|
## clean up kernel modules
|
2015-06-25 22:01:27 +00:00
|
|
|
removekmod sound drivers/media drivers/hwmon \
|
2015-03-04 19:33:40 +00:00
|
|
|
net/atm net/bluetooth net/sched net/sctp \
|
|
|
|
net/rds net/l2tp net/decnet net/netfilter net/ipv4 net/ipv6 \
|
2016-06-21 17:11:28 +00:00
|
|
|
drivers/watchdog drivers/rtc drivers/input/joystick \
|
2015-03-17 21:12:16 +00:00
|
|
|
drivers/bluetooth drivers/edac drivers/staging \
|
2015-03-04 19:33:40 +00:00
|
|
|
drivers/usb/serial drivers/usb/host drivers/usb/misc \
|
|
|
|
fs/ocfs2 fs/ceph fs/nfsd fs/ubifs fs/nilfs2 \
|
|
|
|
arch/x86/kvm
|
2014-08-12 18:28:26 +00:00
|
|
|
## Need to keep virtio_console.ko and ipmi stuff in drivers/char
|
2015-01-05 20:38:06 +00:00
|
|
|
## Also keep virtio-rng so that the installer can get sufficient randomness for
|
2020-09-10 22:50:02 +00:00
|
|
|
## LUKS setup. As of 2020-09 this is not built as a module, but keep it in here
|
|
|
|
## in case that changes again
|
2015-03-04 19:33:40 +00:00
|
|
|
removekmod drivers/char --allbut virtio_console hw_random \
|
2017-04-11 13:47:57 +00:00
|
|
|
virtio-rng ipmi hmcdrv
|
2015-03-17 21:12:16 +00:00
|
|
|
removekmod drivers/hid --allbut hid-logitech-dj hid-logitech-hidpp
|
2020-09-10 22:50:02 +00:00
|
|
|
|
|
|
|
## As of 2020-09 most of this are built-in too, but again, keep them listed
|
2016-07-18 21:37:35 +00:00
|
|
|
removekmod drivers/video --allbut hyperv_fb syscopyarea sysfillrect sysimgblt fb_sys_fops
|
2015-03-04 19:33:40 +00:00
|
|
|
remove lib/modules/*/{build,source,*.map}
|
2011-08-09 21:39:07 +00:00
|
|
|
## NOTE: depmod gets re-run after cleanup finishes
|
2011-06-23 21:31:53 +00:00
|
|
|
|
2011-10-26 18:46:46 +00:00
|
|
|
## remove unused themes, theme engines, icons, etc.
|
|
|
|
removefrom gtk2 /usr/${libdir}/gtk-2.0/*/{engines,printbackends}/*
|
|
|
|
removefrom gtk2 /usr/share/themes/*
|
2012-01-18 18:16:15 +00:00
|
|
|
removefrom gtk3 /usr/${libdir}/gtk-3.0/*/printbackends/*
|
|
|
|
removefrom gtk3 /usr/share/themes/*
|
2011-10-26 18:46:46 +00:00
|
|
|
|
2012-04-20 23:12:26 +00:00
|
|
|
## filesystem tools
|
|
|
|
removefrom e2fsprogs /usr/share/locale/*
|
2014-07-11 16:47:01 +00:00
|
|
|
removefrom xfsprogs /usr/share/locale/* /usr/share/doc/* /usr/share/man/*
|
|
|
|
removefrom xfsdump --allbut /usr/sbin/*
|
2011-10-26 18:46:46 +00:00
|
|
|
|
2011-05-05 22:24:58 +00:00
|
|
|
## other package specific removals
|
2020-09-10 22:50:02 +00:00
|
|
|
removefrom gsettings-desktop-schemas /usr/share/locale/*
|
|
|
|
removefrom NetworkManager-libnm /usr/share/locale/*/NetworkManager.mo
|
2012-08-20 08:22:47 +00:00
|
|
|
removefrom nm-connection-editor /usr/share/applications/*
|
2011-05-13 17:06:03 +00:00
|
|
|
removefrom atk /usr/share/locale/*
|
2020-09-10 22:50:02 +00:00
|
|
|
removefrom audit /etc/* /sbin/auditctl /sbin/aureport
|
2011-06-22 18:20:02 +00:00
|
|
|
removefrom audit /sbin/ausearch /sbin/autrace /usr/bin/*
|
|
|
|
removefrom audit-libs /etc/* /${libdir}/libauparse*
|
2012-02-07 22:41:17 +00:00
|
|
|
removefrom bash /etc/* /usr/bin/bashbug* /usr/share/*
|
2020-03-11 15:42:01 +00:00
|
|
|
removefrom bind-utils /usr/bin/host /usr/bin/nsupdate
|
2011-05-13 17:06:03 +00:00
|
|
|
removefrom bitmap-fangsongti-fonts /usr/share/fonts/*
|
|
|
|
removefrom ca-certificates /etc/pki/java/*
|
2020-09-10 22:50:02 +00:00
|
|
|
removefrom ca-certificates /etc/pki/tls/certs/ca-bundle.trust.crt
|
2015-07-20 13:01:01 +00:00
|
|
|
removefrom cairo /usr/${libdir}/libcairo-script* /usr/bin/cairo-sphinx
|
2020-09-10 22:50:02 +00:00
|
|
|
removefrom coreutils /usr/bin/link /usr/bin/nice /usr/bin/stty /usr/bin/unlink
|
|
|
|
removefrom coreutils /usr/bin/[ /usr/bin/base64 /usr/bin/chcon
|
2020-03-11 15:42:01 +00:00
|
|
|
removefrom coreutils /usr/bin/cksum /usr/bin/csplit
|
2013-03-20 11:44:16 +00:00
|
|
|
removefrom coreutils /usr/bin/dir /usr/bin/dircolors
|
2012-06-04 21:40:50 +00:00
|
|
|
removefrom coreutils /usr/bin/expand /usr/bin/factor
|
2012-07-09 10:35:30 +00:00
|
|
|
removefrom coreutils /usr/bin/fold /usr/bin/groups /usr/bin/hostid
|
2011-06-22 18:20:02 +00:00
|
|
|
removefrom coreutils /usr/bin/install /usr/bin/join /usr/bin/logname
|
|
|
|
removefrom coreutils /usr/bin/mkfifo /usr/bin/nl /usr/bin/nohup /usr/bin/nproc
|
2015-11-06 19:22:56 +00:00
|
|
|
removefrom coreutils /usr/bin/pathchk
|
2011-06-22 18:20:02 +00:00
|
|
|
removefrom coreutils /usr/bin/pinky /usr/bin/pr /usr/bin/printenv
|
2014-07-10 09:41:41 +00:00
|
|
|
removefrom coreutils /usr/bin/printf /usr/bin/ptx /usr/bin/runcon
|
2012-05-31 14:38:29 +00:00
|
|
|
removefrom coreutils /usr/bin/sha224sum /usr/bin/sha384sum
|
2011-06-22 18:20:02 +00:00
|
|
|
removefrom coreutils /usr/bin/sha512sum /usr/bin/shuf /usr/bin/stat
|
|
|
|
removefrom coreutils /usr/bin/stdbuf /usr/bin/sum /usr/bin/test
|
|
|
|
removefrom coreutils /usr/bin/timeout /usr/bin/truncate /usr/bin/tsort
|
|
|
|
removefrom coreutils /usr/bin/unexpand /usr/bin/users /usr/bin/vdir
|
2020-09-10 22:50:02 +00:00
|
|
|
removefrom coreutils /usr/bin/who /usr/bin/whoami /usr/bin/yes
|
|
|
|
removefrom coreutils-common /etc/* /usr/share/*
|
2011-05-13 17:06:03 +00:00
|
|
|
removefrom cpio /usr/share/*
|
|
|
|
removefrom cracklib /usr/sbin/*
|
2011-06-22 18:20:02 +00:00
|
|
|
removefrom cracklib-dicts /usr/${libdir}/* /usr/sbin/*
|
2020-09-10 22:50:02 +00:00
|
|
|
removefrom cryptsetup /usr/share/*
|
|
|
|
removefrom cryptsetup-libs /usr/share/locale/*
|
2011-05-13 17:06:03 +00:00
|
|
|
removefrom cyrus-sasl-lib /usr/sbin/*
|
|
|
|
removefrom dbus-x11 /etc/X11/*
|
2011-10-26 17:53:06 +00:00
|
|
|
removefrom dejavu-sans-fonts --allbut *.conf */DejaVuSans{,-Bold}.ttf
|
|
|
|
removefrom dejavu-sans-mono-fonts --allbut *.conf */DejaVuSansMono.ttf
|
2020-09-10 22:50:02 +00:00
|
|
|
removefrom dnf /usr/share/locale/*
|
2011-05-13 17:06:03 +00:00
|
|
|
removefrom dump /etc/*
|
|
|
|
removefrom elfutils-libelf /usr/share/locale/*
|
|
|
|
removefrom expat /usr/bin/*
|
2020-09-10 22:50:02 +00:00
|
|
|
removefrom fcoe-utils /usr/libexec/fcoe/dcbcheck.sh
|
2011-06-22 18:20:02 +00:00
|
|
|
removefrom fcoe-utils /usr/libexec/fcoe/fcc.sh /usr/libexec/fcoe/fcoe-setup.sh
|
|
|
|
removefrom fcoe-utils /usr/libexec/fcoe/fcoedump.sh /usr/sbin/fcnsq
|
|
|
|
removefrom fcoe-utils /usr/sbin/fcoeadm /usr/sbin/fcping /usr/sbin/fcrls
|
2011-05-13 17:06:03 +00:00
|
|
|
removefrom file-libs /usr/share/*
|
2020-09-10 22:50:02 +00:00
|
|
|
removefrom findutils /usr/share/*
|
2011-05-13 17:06:03 +00:00
|
|
|
removefrom fontconfig /usr/bin/*
|
2020-09-10 22:50:02 +00:00
|
|
|
removefrom gawk /usr/libexec/* /usr/share/*
|
|
|
|
removefrom gdb /usr/share/* /usr/include/*
|
|
|
|
removefrom gdb-headless /usr/share/* /etc/gdbinit*
|
2012-04-12 00:20:44 +00:00
|
|
|
removefrom gdisk /usr/share/*
|
2011-05-13 17:06:03 +00:00
|
|
|
removefrom gdk-pixbuf2 /usr/share/locale*
|
2020-09-10 22:50:02 +00:00
|
|
|
removefrom glib2 /usr/bin/* /usr/share/locale/*
|
|
|
|
removefrom glibc /etc/gai.conf /etc/rpc
|
|
|
|
removefrom glibc /${libdir}/libBrokenLocale*
|
2011-06-22 18:20:02 +00:00
|
|
|
removefrom glibc /${libdir}/libSegFault* /${libdir}/libanl*
|
2020-09-10 22:50:02 +00:00
|
|
|
removefrom glibc /${libdir}/libnss_compat*
|
2014-08-19 16:19:45 +00:00
|
|
|
# python-pyudev uses ctypes.util.find_library, which uses /sbin/ldconfig
|
2011-06-22 18:20:02 +00:00
|
|
|
removefrom glibc /usr/libexec/* /usr/sbin/*
|
2020-09-10 22:50:02 +00:00
|
|
|
removefrom glibc-common /usr/bin/catchsegv /usr/bin/gencat
|
2014-07-10 09:41:41 +00:00
|
|
|
removefrom glibc-common /usr/bin/getent
|
2020-09-10 22:50:02 +00:00
|
|
|
removefrom glibc-common /usr/bin/locale /usr/bin/sprof
|
2017-07-06 18:52:41 +00:00
|
|
|
# NB: we keep /usr/bin/localedef so anaconda can inspect payload locale info
|
|
|
|
removefrom glibc-common /usr/bin/tzselect
|
2020-09-10 22:50:02 +00:00
|
|
|
removefrom glibc-common /usr/sbin/*
|
2011-05-13 17:06:03 +00:00
|
|
|
removefrom gnutls /usr/share/locale/*
|
2018-09-18 05:27:45 +00:00
|
|
|
removefrom google-noto-sans-cjk-ttc-fonts /usr/share/fonts/google-noto-cjk/NotoSansCJK-{Black,Bold,*Light,Medium,Thin}.ttc
|
2011-06-22 18:20:02 +00:00
|
|
|
removefrom grep /etc/* /usr/share/locale/*
|
2011-05-13 17:06:03 +00:00
|
|
|
removefrom gtk2 /usr/bin/update-gtk-immodules
|
2012-12-20 11:32:27 +00:00
|
|
|
removefrom gtk3 /usr/${libdir}/gtk-3.0/*
|
2012-02-07 22:41:17 +00:00
|
|
|
removefrom gzip /usr/bin/{gzexe,zcmp,zdiff,zegrep,zfgrep,zforce,zgrep,zless,zmore,znew}
|
2020-09-10 22:50:02 +00:00
|
|
|
removefrom hwdata /usr/share/hwdata/oui.txt /usr/share/hwdata/pnp.ids
|
2012-05-11 17:42:36 +00:00
|
|
|
removefrom iproute --allbut /usr/sbin/{ip,routef,routel,rtpr}
|
2012-07-12 07:37:30 +00:00
|
|
|
removefrom kbd --allbut */bin/{dumpkeys,kbd_mode,loadkeys,setfont,unicode_*,chvt}
|
2020-09-10 22:50:02 +00:00
|
|
|
removefrom kmod /usr/sbin/weak-modules
|
2011-05-13 17:06:03 +00:00
|
|
|
removefrom less /etc/*
|
|
|
|
removefrom libX11-common /usr/share/X11/XErrorDB
|
|
|
|
removefrom libcanberra /usr/${libdir}/libcanberra-*
|
2014-06-24 23:14:10 +00:00
|
|
|
removefrom libcanberra-gtk3 /usr/bin/*
|
2011-05-13 17:06:03 +00:00
|
|
|
removefrom libcap /usr/sbin/*
|
|
|
|
removefrom libconfig /usr/${libdir}/libconfig++*
|
2011-06-22 18:20:02 +00:00
|
|
|
removefrom libgpg-error /usr/bin/* /usr/share/locale/*
|
2020-09-10 22:50:02 +00:00
|
|
|
removefrom libibverbs /usr/${libdir}/libmlx4*
|
|
|
|
removefrom libidn2 /usr/share/locale/*
|
2011-05-13 17:06:03 +00:00
|
|
|
removefrom libnotify /usr/bin/*
|
|
|
|
removefrom libsemanage /etc/selinux/*
|
|
|
|
removefrom libstdc++ /usr/share/*
|
|
|
|
removefrom libvorbis /usr/${libdir}/libvorbisenc.*
|
|
|
|
removefrom libxml2 /usr/bin/*
|
2020-09-05 01:14:36 +00:00
|
|
|
removefrom linux-firmware /usr/lib/firmware/dvb*
|
|
|
|
removefrom linux-firmware /usr/lib/firmware/*_12mhz*
|
|
|
|
removefrom linux-firmware /usr/lib/firmware/v4l*
|
|
|
|
removefrom linux-firmware /usr/lib/firmware/brcm/BCM-*
|
|
|
|
removefrom linux-firmware /usr/lib/firmware/ttusb-budget/dspbootcode.bin
|
|
|
|
removefrom linux-firmware /usr/lib/firmware/emi26/*
|
|
|
|
removefrom linux-firmware /usr/lib/firmware/emi62/*
|
|
|
|
removefrom linux-firmware /usr/lib/firmware/cpia2/*
|
|
|
|
removefrom linux-firmware /usr/lib/firmware/dabusb/*
|
|
|
|
removefrom linux-firmware /usr/lib/firmware/vicam/*
|
|
|
|
removefrom linux-firmware /usr/lib/firmware/dsp56k/*
|
|
|
|
removefrom linux-firmware /usr/lib/firmware/sun/*
|
|
|
|
removefrom linux-firmware /usr/lib/firmware/av7110/*
|
|
|
|
removefrom linux-firmware /usr/lib/firmware/usbdux/*
|
|
|
|
removefrom linux-firmware /usr/lib/firmware/f2255usb.bin
|
|
|
|
removefrom linux-firmware /usr/lib/firmware/lgs8g75.fw
|
|
|
|
removefrom linux-firmware /usr/lib/firmware/TDA7706*
|
|
|
|
removefrom linux-firmware /usr/lib/firmware/tlg2300_firmware.bin
|
|
|
|
removefrom linux-firmware /usr/lib/firmware/s5p-mfc*
|
|
|
|
removefrom linux-firmware /usr/lib/firmware/go7007/*
|
|
|
|
removefrom linux-firmware /usr/lib/firmware/intel/IntcSST2.bin
|
|
|
|
removefrom linux-firmware /usr/lib/firmware/intel/fw_sst*
|
|
|
|
removefrom linux-firmware /usr/lib/firmware/intel/dsp*
|
|
|
|
removefrom linux-firmware /usr/lib/firmware/as102*
|
|
|
|
removefrom linux-firmware /usr/lib/firmware/qcom/venus*/*
|
|
|
|
removefrom linux-firmware /usr/lib/firmware/meson/vdec/*
|
2020-09-11 19:19:58 +00:00
|
|
|
removefrom linux-firmware /usr/lib/firmware/mellanox/mlxsw_spectrum*
|
2020-09-11 19:34:59 +00:00
|
|
|
%if basearch != "aarch64":
|
|
|
|
removefrom linux-firmware /usr/lib/firmware/dpaa2/*
|
|
|
|
%endif
|
2015-08-11 09:11:52 +00:00
|
|
|
removefrom lldpad /etc/*
|
2020-10-30 19:19:41 +00:00
|
|
|
removefrom mdadm /etc/* /usr/lib/systemd/system/mdmonitor*
|
2020-09-04 23:02:54 +00:00
|
|
|
removefrom mesa-dri-drivers /usr/${libdir}/dri/*_video.so
|
2020-09-10 22:50:02 +00:00
|
|
|
removefrom mt-st /usr/sbin/*
|
2011-05-13 17:06:03 +00:00
|
|
|
removefrom mtools /etc/*
|
2017-06-19 08:55:53 +00:00
|
|
|
removefrom ncurses-libs /usr/${libdir}/libform*
|
2019-01-02 09:16:17 +00:00
|
|
|
## libmenu.so is needed by lp_diag binary from ppc64-diag which is a PowerPC specific package
|
2020-09-14 20:56:36 +00:00
|
|
|
%if basearch != "ppc64le":
|
2017-06-19 08:55:53 +00:00
|
|
|
removefrom ncurses-libs /usr/${libdir}/libmenu*
|
|
|
|
%endif
|
2011-06-22 18:20:02 +00:00
|
|
|
removefrom ncurses-libs /usr/${libdir}/libpanel.* /usr/${libdir}/libtic*
|
2012-05-23 21:53:37 +00:00
|
|
|
removefrom net-tools */bin/netstat */sbin/ether-wake */sbin/ipmaddr
|
|
|
|
removefrom net-tools */sbin/iptunnel */sbin/mii-diag */sbin/mii-tool
|
|
|
|
removefrom net-tools */sbin/nameif */sbin/plipconfig */sbin/slattach
|
|
|
|
removefrom net-tools /usr/share/locale/*
|
2011-08-29 18:41:09 +00:00
|
|
|
removefrom nfs-utils /etc/nfsmount.conf
|
2020-09-10 22:50:02 +00:00
|
|
|
removefrom nfs-utils /usr/lib/systemd/system/*
|
|
|
|
removefrom nfs-utils /sbin/rpc.statd /usr/sbin/exportfs
|
2011-06-22 18:20:02 +00:00
|
|
|
removefrom nfs-utils /usr/sbin/mountstats /usr/sbin/nfsiostat
|
|
|
|
removefrom nfs-utils /usr/sbin/nfsstat /usr/sbin/rpc.gssd /usr/sbin/rpc.idmapd
|
|
|
|
removefrom nfs-utils /usr/sbin/rpc.mountd /usr/sbin/rpc.nfsd
|
2020-09-10 22:50:02 +00:00
|
|
|
removefrom nfs-utils /usr/sbin/rpcdebug
|
2011-06-22 18:20:02 +00:00
|
|
|
removefrom nfs-utils /usr/sbin/showmount /usr/sbin/sm-notify
|
|
|
|
removefrom nfs-utils /usr/sbin/start-statd /var/lib/nfs/etab
|
2020-09-10 22:50:02 +00:00
|
|
|
removefrom nfs-utils /var/lib/nfs/rmtab /var/lib/nfs/statd/state
|
2011-05-13 17:06:03 +00:00
|
|
|
removefrom nss-softokn /usr/${libdir}/nss/*
|
2020-11-30 10:35:59 +00:00
|
|
|
removefrom openldap /etc/openldap/*
|
2016-09-22 10:59:23 +00:00
|
|
|
removefrom openssh /usr/libexec/*
|
|
|
|
removefrom openssh-clients /etc/ssh/* /usr/bin/ssh-*
|
2013-03-12 17:53:37 +00:00
|
|
|
removefrom openssh-clients /usr/libexec/*
|
2016-09-22 10:59:23 +00:00
|
|
|
removefrom openssh-server /etc/ssh/* /usr/libexec/openssh/sftp-server
|
2020-09-10 22:50:02 +00:00
|
|
|
removefrom openssl /usr/bin/*
|
2012-02-07 22:41:17 +00:00
|
|
|
removefrom pam /usr/sbin/* /usr/share/locale/*
|
2011-06-22 18:20:02 +00:00
|
|
|
removefrom policycoreutils /etc/* /usr/bin/* /usr/share/locale/*
|
2011-05-13 17:06:03 +00:00
|
|
|
removefrom polkit /usr/bin/*
|
|
|
|
removefrom popt /usr/share/locale/*
|
2020-09-10 22:50:02 +00:00
|
|
|
removefrom procps-ng /usr/bin/free /usr/bin/pgrep /usr/bin/pkill
|
|
|
|
removefrom procps-ng /usr/bin/pmap /usr/bin/pwdx /usr/bin/skill /usr/bin/slabtop
|
|
|
|
removefrom procps-ng /usr/bin/snice /usr/bin/tload /usr/bin/uptime
|
|
|
|
removefrom procps-ng /usr/bin/vmstat /usr/bin/w /usr/bin/watch
|
2012-02-07 22:41:17 +00:00
|
|
|
removefrom psmisc /usr/share/locale/*
|
2020-09-10 22:50:02 +00:00
|
|
|
removefrom python3-kickstart /usr/lib/python*/site-packages/pykickstart/locale/*
|
2017-01-13 18:38:45 +00:00
|
|
|
removefrom readline /usr/${libdir}/libhistory*
|
2020-09-10 22:50:02 +00:00
|
|
|
removefrom libreport /usr/share/locale/*
|
|
|
|
removefrom libreport-cli /usr/bin/*
|
|
|
|
removefrom rdma-core /etc/rdma/mlx4.conf
|
2014-07-12 00:09:47 +00:00
|
|
|
removefrom rpm /usr/bin/* /usr/share/locale/*
|
2011-05-13 17:06:03 +00:00
|
|
|
removefrom rsync /etc/*
|
|
|
|
removefrom sed /usr/share/locale/*
|
2011-06-22 18:20:02 +00:00
|
|
|
removefrom smartmontools /etc/* /usr/sbin/smartd
|
2011-05-13 17:06:03 +00:00
|
|
|
removefrom smartmontools /usr/sbin/update-smart-drivedb
|
|
|
|
removefrom smartmontools /usr/share/smartmontools/*
|
|
|
|
removefrom tar /usr/share/locale/*
|
|
|
|
removefrom usbutils /usr/bin/*
|
2011-08-31 23:32:37 +00:00
|
|
|
removefrom util-linux --allbut \
|
2020-02-20 18:00:53 +00:00
|
|
|
/usr/bin/{dmesg,eject,getopt,kill,login,lsblk,more,mount,umount,mountpoint,findmnt} \
|
2011-08-31 23:32:37 +00:00
|
|
|
/etc/mtab /etc/pam.d/login /etc/pam.d/remote \
|
2019-09-20 13:23:35 +00:00
|
|
|
/usr/sbin/{agetty,blkid,blockdev,clock,fdisk,fsck,fstrim,hwclock,losetup,zramctl} \
|
2017-10-06 09:24:42 +00:00
|
|
|
/usr/sbin/{mkswap,swaplabel,nologin,sfdisk,swapoff,swapon,wipefs,partx,fsfreeze} \
|
2019-07-09 14:58:45 +00:00
|
|
|
/usr/bin/{logger,hexdump,flock,chmem,lsmem,lscpu}
|
2011-05-13 17:06:03 +00:00
|
|
|
removefrom volume_key-libs /usr/share/locale/*
|
2011-06-22 18:20:02 +00:00
|
|
|
removefrom wget /etc/* /usr/share/locale/*
|
2011-05-13 17:06:03 +00:00
|
|
|
removefrom xorg-x11-drv-intel /usr/${libdir}/libI*
|
|
|
|
removefrom xorg-x11-drv-openchrome /usr/${libdir}/libchrome*
|
|
|
|
removefrom xorg-x11-drv-wacom /usr/bin/*
|
2011-08-31 23:32:37 +00:00
|
|
|
removefrom xorg-x11-fonts-misc --allbut /usr/share/X11/fonts/misc/{6x13,encodings,fonts,*cursor}*
|
2020-02-21 18:55:10 +00:00
|
|
|
removefrom xorg-x11-server-utils --allbut /usr/bin/xrandr /usr/bin/xrdb
|
2021-05-03 18:26:37 +00:00
|
|
|
|
|
|
|
%if branding.release:
|
|
|
|
removefrom ${branding.logos} /usr/share/plymouth/*
|
|
|
|
removefrom ${branding.logos} /etc/*
|
|
|
|
removefrom ${branding.logos} /usr/share/icons/{Bluecurve,oxygen}/*
|
|
|
|
removefrom ${branding.logos} /usr/share/{firstboot,kde4,pixmaps}/*
|
|
|
|
%endif
|
2011-05-05 22:24:58 +00:00
|
|
|
|
2020-06-01 20:49:22 +00:00
|
|
|
## cleanup /boot/ leaving vmlinuz, and .*hmac files
|
|
|
|
runcmd chroot ${root} find /boot \! -name "vmlinuz*" \
|
|
|
|
-and \! -name ".vmlinuz*" \
|
2017-08-14 20:20:27 +00:00
|
|
|
-and \! -name boot -delete
|
|
|
|
|
2012-06-19 22:14:06 +00:00
|
|
|
## remove any broken links in /etc or /usr
|
2011-08-09 21:33:27 +00:00
|
|
|
## (broken systemd service links lead to confusing noise at boot)
|
2011-08-05 21:25:57 +00:00
|
|
|
## NOTE: not checking /var because we want to keep /var/run
|
2012-01-06 00:38:45 +00:00
|
|
|
## NOTE: Excluding /etc/mtab which links to /proc/self/mounts for systemd
|
2012-06-19 22:14:06 +00:00
|
|
|
runcmd chroot ${root} find -L /etc /usr -xdev -type l -and \! -name "mtab" \
|
|
|
|
-printf "removing broken symbolic link %p -> %l\n" -delete
|
2016-03-15 21:10:55 +00:00
|
|
|
|
2020-09-14 16:08:38 +00:00
|
|
|
## Remove compiled python files, they are recreated as needed anyway
|
|
|
|
runcmd find ${root} -name "*.pyo" -type f -delete
|
|
|
|
runcmd find ${root} -name "*.pyc" -type f -delete
|
|
|
|
|
2016-03-15 21:10:55 +00:00
|
|
|
## Clean up some of the mess pulled in by webkitgtk via yelp
|
|
|
|
## libwebkit2gtk links to a handful of libraries in gstreamer and
|
|
|
|
## gstreamer-plugins-base. Remove the rest of them.
|
|
|
|
removefrom gstreamer1 --allbut /usr/${libdir}/libgstbase-1.0.* \
|
|
|
|
/usr/${libdir}/libgstreamer-1.0.*
|
|
|
|
removefrom gstreamer1-plugins-base --allbut \
|
2020-02-21 18:55:10 +00:00
|
|
|
/usr/${libdir}/libgst{allocators,app,audio,fft,gl,pbutils,tag,video}-1.0.*
|
2016-03-15 21:10:55 +00:00
|
|
|
|
|
|
|
## We have enough geoip libraries, thanks
|
|
|
|
removepkg geoclue2
|
|
|
|
|
|
|
|
## And remove the packages that those extra libraries pulled in
|
|
|
|
removepkg cdparanoia-libs opus libtheora libvisual flac-libs gsm avahi-glib avahi-libs \
|
|
|
|
ModemManager-glib
|
|
|
|
|
2021-05-19 16:42:24 +00:00
|
|
|
## gnome-kiosk dependencies require libvorbis and libvorbisfile, but enc/dec are no longer needed
|
2016-03-15 21:10:55 +00:00
|
|
|
removefrom libvorbis --allbut /usr/${libdir}/libvorbisfile.* /usr/${libdir}/libvorbis.*
|
2018-10-06 16:34:40 +00:00
|
|
|
|
2019-07-09 17:55:43 +00:00
|
|
|
## Remove build-id links, they are used with debuginfo
|
|
|
|
remove /usr/lib/.build-id
|
|
|
|
|
2018-10-06 16:34:40 +00:00
|
|
|
## make the image more reproducible
|
|
|
|
|
|
|
|
## make machine-id empty but present to avoid systemd populating /etc with
|
|
|
|
## preset settings
|
|
|
|
remove /etc/machine-id
|
|
|
|
append /etc/machine-id ""
|
|
|
|
## journalctl message catalog, non-deterministic
|
|
|
|
remove /var/lib/systemd/catalog/database
|
|
|
|
## non-reproducible caches
|
|
|
|
remove /var/cache/ldconfig/aux-cache
|
|
|
|
remove /etc/pki/ca-trust/extracted/java/cacerts
|
|
|
|
|
|
|
|
## sort groups
|
|
|
|
runcmd chroot ${root} /bin/sh -c "LC_ALL=C sort /etc/group > /etc/group- && mv /etc/group- /etc/group"
|
|
|
|
runcmd chroot ${root} /bin/sh -c "LC_ALL=C sort /etc/gshadow > /etc/gshadow- && mv /etc/gshadow- /etc/gschadow"
|