From: Daan De Meyer Date: Sun, 29 Jan 2023 14:29:40 +0000 (+0100) Subject: centos: Install epel-release in both build and final images X-Git-Tag: v15~347 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f36983f552a197faf9e36361cc68a297e68bee73;p=thirdparty%2Fmkosi.git centos: Install epel-release in both build and final images This allows mkosi.prepare scripts to install extra dependencies from epel as well. --- diff --git a/mkosi/distributions/centos.py b/mkosi/distributions/centos.py index b3eb5b638..5bf5053da 100644 --- a/mkosi/distributions/centos.py +++ b/mkosi/distributions/centos.py @@ -69,12 +69,13 @@ class CentosInstaller(DistributionInstaller): if state.do_run_build_script: packages.update(state.config.build_packages) - if not state.do_run_build_script and "epel" in state.config.repositories: + if "epel" in state.config.repositories: add_packages(state.config, packages, "epel-release") - if state.config.netdev: - add_packages(state.config, packages, "systemd-networkd", conditional="systemd") - if state.config.distribution != Distribution.centos and release >= 9: - add_packages(state.config, packages, "systemd-boot", conditional="systemd") + if not state.do_run_build_script: + if state.config.netdev: + add_packages(state.config, packages, "systemd-networkd", conditional="systemd") + if state.config.distribution != Distribution.centos and release >= 9: + add_packages(state.config, packages, "systemd-boot", conditional="systemd") # Make sure we only install the minimal language files by default on CentOS Stream 8 which still # defaults to all langpacks.