From eb84bc9b9216215262e8f1eccb76c1013abb77d9 Mon Sep 17 00:00:00 2001 From: Alba Hita Catala Date: Fri, 11 Nov 2022 15:10:58 +0100 Subject: [PATCH] Set SELinux policy to permissive for insights_client_t module Signed-off-by: Alba Hita Catala Resolves:rhbz#2141443 --- insights-client.spec | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/insights-client.spec b/insights-client.spec index 5a2e647..f46d807 100644 --- a/insights-client.spec +++ b/insights-client.spec @@ -3,7 +3,7 @@ Name: insights-client Summary: Uploads Insights information to Red Hat on a periodic basis Version: 3.1.7 -Release: 11%{?dist} +Release: 12%{?dist} Source0: https://github.com/RedHatInsights/insights-client/releases/download/v%{version}/insights-client-%{version}.tar.gz Source1: https://api.access.redhat.com/r/insights/v1/static/core/insights-core.egg Source2: https://api.access.redhat.com/r/insights/v1/static/core/insights-core.egg.asc @@ -44,6 +44,7 @@ BuildRequires: python3-devel BuildRequires: platform-python-devel BuildRequires: systemd BuildRequires: pam +Requires(post): policycoreutils-python-utils %description @@ -83,7 +84,7 @@ if [ -d %{_sysconfdir}/motd.d ]; then fi fi - +semanage permissive --add insights_client_t %preun %systemd_preun %{name}.timer @@ -95,6 +96,10 @@ fi %systemd_postun %{name}.service %systemd_postun %{name}-boot.service +if [ $1 -eq 0 ]; then + %{_sbindir}/semanage permissive -d insights_client_t || true +fi + # Clean up files created by insights-client that are unowned by the RPM if [ $1 -eq 0 ]; then rm -f %{_sysconfdir}/cron.daily/insights-client @@ -136,6 +141,9 @@ rm -rf %{buildroot} %changelog +* Thu Nov 10 2022 Alba Hita Catala 0:3.1.7-12 +- Set SELinux policy to permissive for rhcd_t module (RHBZ#2141443) + * Wed Nov 09 2022 Link Dupont 0:3.1.7-11 - Include insights-core.egg as RPM source (RHBZ#2141087)