#1001 Only base containers should have tzdata
Merged 7 months ago by ngompa. Opened 7 months ago by codonell.
codonell/fedora-kickstarts main  into  main

Only base containers should have tzdata
Carlos O'Donell • 7 months ago  
@@ -6,7 +6,7 @@ 

  

  %packages --excludedocs --instLangs=en --nocore --excludeWeakdeps

  microdnf

- 

+ -tzdata

  %end

  

  %post --erroronfail --log=/root/anaconda-post.log
@@ -33,11 +33,6 @@ 

  # we lose presets by removing /usr/lib/systemd but we do not care

  rm -rfv /usr/lib/systemd

  

- # if you want to change the timezone, bind-mount it from the host or reinstall tzdata

- 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/*

  

@@ -35,6 +35,7 @@ 

  bash

  coreutils

  glibc-minimal-langpack

+ tzdata

  rpm

  util-linux-core

  -kernel

The base container should always install tzdata to ensure that it is
available for applications built on top of the base container.

The minimal container should never have tzdata installed, and the
application should install it as part of the application dependencies.

Starting with Fedora 39 we have the capability to remove tzdata from
the minimal images without resorting to deleting files:
https://fedoraproject.org/wiki/Changes/AllowRemovalOfTzdata

Pull-Request has been merged by ngompa

7 months ago