mirror of
https://pagure.io/fedora-kickstarts.git
synced 2024-12-22 13:45:39 +00:00
Remove not needed files from the container base image.
This brings some of the fedora-minimal optimization to the fedora base image. We remove the timezones info, default fonts and some logs. Signed-off-by: Clement Verna <cverna@tutanota.com>
This commit is contained in:
parent
1c39c0adb0
commit
e8fd539b8c
@ -15,6 +15,7 @@ sssd-client
|
|||||||
sudo
|
sudo
|
||||||
-glibc-langpack-en
|
-glibc-langpack-en
|
||||||
-cracklib-dicts
|
-cracklib-dicts
|
||||||
|
-dejavu-sans-fonts
|
||||||
%end
|
%end
|
||||||
|
|
||||||
%post --erroronfail --log=/root/anaconda-post.log
|
%post --erroronfail --log=/root/anaconda-post.log
|
||||||
@ -46,6 +47,18 @@ umount /run
|
|||||||
systemd-tmpfiles --prefix=/run/ --prefix=/var/run/ --create --boot || true
|
systemd-tmpfiles --prefix=/run/ --prefix=/var/run/ --create --boot || true
|
||||||
rm /run/nologin # https://pagure.io/atomic-wg/issue/316
|
rm /run/nologin # https://pagure.io/atomic-wg/issue/316
|
||||||
|
|
||||||
|
# Remove some dnf info
|
||||||
|
rm -rfv /var/lib/dnf
|
||||||
|
|
||||||
|
# if you want to change the timezone, bind-mount it from the host or reinstall tzdata
|
||||||
|
# Work around waiting for a tzdata-minimal package see https://bugzilla.redhat.com/show_bug.cgi?id=1733452
|
||||||
|
rm -fv /etc/localtime
|
||||||
|
mv /usr/share/zoneinfo/UTC /etc/localtime
|
||||||
|
rm -rfv /usr/share/zoneinfo
|
||||||
|
|
||||||
|
# Final pruning
|
||||||
|
rm -rfv /var/cache/* /var/log/* /tmp/*
|
||||||
|
|
||||||
%end
|
%end
|
||||||
|
|
||||||
%post --nochroot --erroronfail --log=/mnt/sysimage/root/anaconda-post-nochroot.log
|
%post --nochroot --erroronfail --log=/mnt/sysimage/root/anaconda-post-nochroot.log
|
||||||
|
Loading…
Reference in New Issue
Block a user