Clean up package installation

Remove duplicate items from pkg-map and uninstall build-time
dependencies after building the image.

Uninstall cloud-init, tuned and teamd in post-install since they
may get pulled by other elements.

Uninstall GObject components and mozjs which seem to be included.

Remove non-existing cronie.

Change-Id: I656c7524d8f543056194207fab371c6e313f9548
This commit is contained in:
Dmitry Tantsur 2020-11-24 16:59:12 +01:00
parent d1d3a7e555
commit 07367ece76
2 changed files with 30 additions and 25 deletions

View File

@ -7,8 +7,9 @@ iptables:
lshw: lshw:
ipmitool: ipmitool:
qemu-utils: qemu-utils:
# NOTE(dtantsur): gcc is not build-only because dkms requires it
gcc: gcc:
python-dev: python:
parted: parted:
hdparm: hdparm:
util-linux: util-linux:
@ -22,22 +23,34 @@ efibootmgr:
efivar: efivar:
chrony: chrony:
e2fsprogs: e2fsprogs:
libffi-dev: libffi-dev:
build-only: true build-only: true
libssl-dev: libssl-dev:
build-only: true build-only: true
python-dev:
build-only: true
# The base minimum element uninstalls firmware, but it's needed for bare metal. # The base minimum element uninstalls firmware, but it's needed for bare metal.
linux-firmware: linux-firmware:
phase: post-install.d phase: post-install.d
when: IPA_DISTRO_FAMILY = rh when: IPA_DISTRO_FAMILY = rh
# Packages that should not normally be present on IPA images
cloud-init:
phase: post-install.d
uninstall: true
teamd:
phase: post-install.d
uninstall: true
when: IPA_DISTRO_FAMILY = rh
tuned:
phase: post-install.d
uninstall: true
when: IPA_DISTRO_FAMILY = rh
# Unnecessary packages to remove. We run all removals in pre-install phase, to # Unnecessary packages to remove. We run all removals in pre-install phase, to
# avoid breaking installs that happen in install phase. # avoid breaking installs that happen in install phase.
cloud-init:
phase: pre-install.d
uninstall: true
git: git:
phase: pre-install.d phase: pre-install.d
uninstall: true uninstall: true
@ -49,11 +62,11 @@ rsync:
uninstall: true uninstall: true
# Distro-specific uninstalls # Distro-specific uninstalls
cronie: kernel-debug-devel:
phase: pre-install.d phase: pre-install.d
uninstall: true uninstall: true
when: IPA_DISTRO_FAMILY = rh when: IPA_DISTRO_FAMILY = rh
kernel-debug-devel: mozjs60:
phase: pre-install.d phase: pre-install.d
uninstall: true uninstall: true
when: IPA_DISTRO_FAMILY = rh when: IPA_DISTRO_FAMILY = rh
@ -61,7 +74,11 @@ plymouth:
phase: pre-install.d phase: pre-install.d
uninstall: true uninstall: true
when: IPA_DISTRO_FAMILY = rh when: IPA_DISTRO_FAMILY = rh
teamd: python3-cairo:
phase: pre-install.d
uninstall: true
when: IPA_DISTRO_FAMILY = rh
python3-gobject-base:
phase: pre-install.d phase: pre-install.d
uninstall: true uninstall: true
when: IPA_DISTRO_FAMILY = rh when: IPA_DISTRO_FAMILY = rh

View File

@ -3,25 +3,20 @@
"rhel": { "rhel": {
"8": { "8": {
"tgt": "target-restore", "tgt": "target-restore",
"curl": "curl", "python": "python3",
"ironic-python-agent": "openstack-ironic-python-agent",
"libffi-dev": "libffi-devel",
"qemu-utils": "qemu-img",
"python-dev": "python3-devel" "python-dev": "python3-devel"
} }
}, },
"centos": { "centos": {
"8": { "8": {
"tgt": "target-restore", "tgt": "target-restore",
"curl": "curl", "python": "python3",
"ironic-python-agent": "openstack-ironic-python-agent",
"libffi-dev": "libffi-devel",
"qemu-utils": "qemu-img",
"python-dev": "python3-devel" "python-dev": "python3-devel"
} }
}, },
"ubuntu": { "ubuntu": {
"bionic": { "bionic": {
"python": "python3",
"python-dev": "python3-dev" "python-dev": "python3-dev"
} }
} }
@ -29,24 +24,17 @@
"family": { "family": {
"redhat": { "redhat": {
"tgt": "scsi-target-utils", "tgt": "scsi-target-utils",
"curl": "curl",
"ironic-python-agent": "openstack-ironic-python-agent",
"libffi-dev": "libffi-devel", "libffi-dev": "libffi-devel",
"libssl-dev": "openssl-devel", "libssl-dev": "openssl-devel",
"qemu-utils": "qemu-img", "qemu-utils": "qemu-img",
"python-dev": "python-devel" "python-dev": "python-devel"
}, },
"debian": { "debian": {
"tgt": "tgt", "python": "python3",
"curl": "curl",
"python-dev": "python3-dev" "python-dev": "python3-dev"
} }
}, },
"default": { "default": {
"tgt": "tgt", "ironic-python-agent": "openstack-ironic-python-agent"
"curl": "curl",
"ironic-python-agent": "openstack-ironic-python-agent",
"qemu-utils": "qemu-utils",
"python-dev": "python-dev"
} }
} }