From 818b75af41b99b7573d3d9da132c7b866a2ac2a1 Mon Sep 17 00:00:00 2001 From: Ian Wienand Date: Tue, 1 Aug 2017 09:47:50 +1000 Subject: [PATCH] Move selinux packages to redhat-common Change I008f8bbc9c8414ce948c601e3907e27764e15a52 has shown that we build redhat images without the "semange" tool available, which comes from the policycoreutils-python package (see also I3f9e2c322d042a5dddba33451c0fc21a4d32a88a). I403e7806ae10d5dd96d0727832f4da20e34b94c7 added some of the selinux libraries to yum-minimal for ansible support, but not to others. Given both these changes, it seems that selinux[-targeted], libselinux[-python] and policycoreutils[-python] can reasonably considered part of all base images. Move the selinux related packages into redhat-common. This also adds it explicitly to install_test_deps.sh. It was actually being dragged in by the docker install, but is a required component for building (should be in bindep, but not there with that yet). Change-Id: Idd4ae71ee6deee84604823b6b5dc4a845f316e01 Related-Bug: #1707788 --- .../elements/redhat-common/package-installs.yaml | 7 +++++++ .../elements/yum-minimal/package-installs.yaml | 3 --- tests/install_test_deps.sh | 3 ++- 3 files changed, 9 insertions(+), 4 deletions(-) diff --git a/diskimage_builder/elements/redhat-common/package-installs.yaml b/diskimage_builder/elements/redhat-common/package-installs.yaml index 81e19aa9d..1a8f25d1a 100644 --- a/diskimage_builder/elements/redhat-common/package-installs.yaml +++ b/diskimage_builder/elements/redhat-common/package-installs.yaml @@ -6,3 +6,10 @@ traceroute: which: gettext: phase: pre-install.d + +# selinux-targeted policy and related tools +selinux-policy: +selinux-policy-targeted: +libselinux-python: +policycoreutils: +policycoreutils-python: diff --git a/diskimage_builder/elements/yum-minimal/package-installs.yaml b/diskimage_builder/elements/yum-minimal/package-installs.yaml index 55d483d66..87bfbdeac 100644 --- a/diskimage_builder/elements/yum-minimal/package-installs.yaml +++ b/diskimage_builder/elements/yum-minimal/package-installs.yaml @@ -6,7 +6,4 @@ kernel: initscripts: man-pages: lsb_release: -selinux-policy: -selinux-policy-targeted: -libselinux-python: redhat-rpm-config: \ No newline at end of file diff --git a/tests/install_test_deps.sh b/tests/install_test_deps.sh index cbb429dd7..c0876a331 100755 --- a/tests/install_test_deps.sh +++ b/tests/install_test_deps.sh @@ -23,7 +23,8 @@ sudo apt-get install -y --force-yes \ docker \ kpartx \ util-linux \ - qemu-img || \ + qemu-img \ + policycoreutils-python || \ sudo zypper -n install \ bzip2 \ debootstrap \