Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package pcp for openSUSE:Factory checked in at 2024-09-03 13:37:38 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/pcp (Old) and /work/SRC/openSUSE:Factory/.pcp.new.2698 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "pcp" Tue Sep 3 13:37:38 2024 rev:76 rq:1198240 version:6.2.1 Changes: -------- --- /work/SRC/openSUSE:Factory/pcp/pcp.changes 2024-05-16 17:13:09.875549696 +0200 +++ /work/SRC/openSUSE:Factory/.pcp.new.2698/pcp.changes 2024-09-03 13:37:58.391838678 +0200 @@ -62,0 +63,5 @@ +Tue May 14 15:36:47 UTC 2024 - Cathy Hu <cathy...@suse.com> + +- Enable custom pcp-selinux module (bsc#1223260) + +------------------------------------------------------------------- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ pcp.spec ++++++ --- /var/tmp/diff_new_pack.w8hrea/_old 2024-09-03 13:37:59.275875533 +0200 +++ /var/tmp/diff_new_pack.w8hrea/_new 2024-09-03 13:37:59.279875700 +0200 @@ -89,9 +89,8 @@ # PATCH-FIX-UPSTREAM, dd...@suse.de Patch10: 0010-services-switch-logutil-and-pmieutil-scripts-from-ty.patch -%if 0%{?fedora} || 0%{?rhel} %global disable_selinux 0 -%else +%if 0%{?suse_version} < 1600 %global disable_selinux 1 %endif @@ -368,7 +367,7 @@ %endif # default_qt %endif # !disable_qt %if !%{disable_selinux} -Requires: pcp-selinux = %{version}-%{release} +Requires: (pcp-selinux = %{version}-%{release} if selinux-policy-targeted) %endif Requires: bash @@ -402,8 +401,7 @@ %global _pmdasdir %{_localstatedir}/lib/pcp/pmdas %global _pmdasexecdir %{_libexecdir}/pcp/pmdas %global _testsdir %{_localstatedir}/lib/pcp/testsuite -%global _selinuxdir %{_localstatedir}/lib/pcp/selinux -%global _selinuxexecdir %{_libexecdir}/pcp/selinux +%global _selinuxdir %{_datadir}/selinux/packages/targeted %global _logconfdir %{_localstatedir}/lib/pcp/config/pmlogconf %global _ieconfdir %{_localstatedir}/lib/pcp/config/pmieconf %global _tapsetdir %{_datadir}/systemtap/tapset @@ -534,16 +532,6 @@ fi } -%global selinux_handle_policy() %{expand: -if [ %1 -ge 1 ] -then - %{_libexecdir}/pcp/bin/selinux-setup %{_selinuxdir} install %2 -elif [ %1 -eq 0 ] -then - %{_libexecdir}/pcp/bin/selinux-setup %{_selinuxdir} remove %2 -fi -} - %description Performance Co-Pilot (PCP) provides a framework and services to support system-level performance monitoring and performance management. @@ -554,6 +542,7 @@ + # # pcp-conf # @@ -573,6 +562,7 @@ + # # pcp-libs # @@ -660,6 +650,7 @@ + # # pcp-devel # @@ -680,6 +671,7 @@ + # # pcp-testsuite # @@ -705,6 +697,7 @@ + # # perl-PCP-PMDA. This is the PCP agent perl binding. # @@ -727,6 +720,7 @@ + # # perl-PCP-MMV # @@ -750,6 +744,7 @@ + # # perl-PCP-LogImport # @@ -770,6 +765,7 @@ + # # perl-PCP-LogSummary # @@ -793,6 +789,7 @@ + # # pcp-import-sar2pcp # @@ -816,6 +813,7 @@ + # # pcp-import-iostat2pcp # @@ -880,6 +878,7 @@ + # # pcp-import-ganglia2pcp # @@ -902,6 +901,7 @@ + # # pcp-import-collectl2pcp # @@ -963,6 +963,7 @@ + # # pcp-export-pcp2graphite # @@ -985,6 +986,7 @@ + # pcp-export-pcp2influxdb # %package export-pcp2influxdb @@ -1008,6 +1010,7 @@ + # # pcp-export-pcp2json # @@ -1028,6 +1031,7 @@ + # # pcp-export-pcp2spark # @@ -1086,6 +1090,7 @@ + # # pcp-export-pcp2zabbix # @@ -1192,6 +1197,7 @@ + #end pcp-pmda-activemq # # pcp-pmda-bind2 @@ -1212,6 +1218,7 @@ + #end pcp-pmda-bind2 # # pcp-pmda-redis @@ -1273,6 +1280,7 @@ + #end pcp-pmda-bonding # # pcp-pmda-dbping @@ -1294,6 +1302,7 @@ + #end pcp-pmda-dbping # # pcp-pmda-ds389 @@ -1319,6 +1328,7 @@ + #end pcp-pmda-ds389 # # pcp-pmda-ds389log @@ -1340,6 +1350,7 @@ + #end pcp-pmda-ds389log # # pcp-pmda-gpfs @@ -1360,6 +1371,7 @@ + #end pcp-pmda-gpfs # # pcp-pmda-gpsd @@ -1381,6 +1393,7 @@ + #end pcp-pmda-gpsd # # pcp-pmda-docker @@ -1397,6 +1410,7 @@ + #end pcp-pmda-docker # # pcp-pmda-lustre @@ -1417,6 +1431,7 @@ + #end pcp-pmda-lustre # # pcp-pmda-lustrecomm @@ -1438,6 +1453,7 @@ + #end pcp-pmda-lustrecomm # # pcp-pmda-memcache @@ -1459,6 +1475,7 @@ + #end pcp-pmda-memcache # # pcp-pmda-mysql @@ -1484,6 +1501,7 @@ + #end pcp-pmda-mysql # # pcp-pmda-named @@ -1505,6 +1523,7 @@ + #end pcp-pmda-named # pcp-pmda-netfilter # @@ -1525,6 +1544,7 @@ + #end pcp-pmda-netfilter # # pcp-pmda-news @@ -1546,6 +1566,7 @@ + #end pcp-pmda-news # # pcp-pmda-nginx @@ -1568,6 +1589,7 @@ + #end pcp-pmda-nginx # # pcp-pmda-oracle @@ -1590,6 +1612,7 @@ + #end pcp-pmda-oracle # # pcp-pmda-pdns @@ -1611,6 +1634,7 @@ + #end pcp-pmda-pdns # # pcp-pmda-postfix @@ -1649,6 +1673,7 @@ + #end pcp-pmda-postfix # # pcp-pmda-rsyslog @@ -1675,6 +1700,7 @@ + #end pcp-pmda-rsyslog # # pcp-pmda-samba @@ -1696,6 +1722,7 @@ + #end pcp-pmda-samba # # pcp-pmda-slurm @@ -1757,6 +1784,7 @@ + #end pcp-pmda-vmware # # pcp-pmda-zimbra @@ -1775,6 +1803,7 @@ + #end pcp-pmda-zimbra # # pcp-pmda-dm @@ -1813,6 +1842,7 @@ + # end pcp-pmda-gluster # # pcp-pmda-nfsclient @@ -1870,6 +1900,7 @@ + # end pcp-pmda-zswap # # pcp-pmda-unbound @@ -1890,6 +1921,7 @@ + # end pcp-pmda-unbound # # pcp-pmda-mic @@ -1910,6 +1942,7 @@ + # end pcp-pmda-mic # # pcp-pmda-haproxy @@ -1975,6 +2008,7 @@ + #end pcp-pmda-elasticsearch # # pcp-pmda-openvswitch @@ -1995,6 +2029,7 @@ + #end pcp-pmda-openvswitch # # pcp-pmda-rabbitmq @@ -2067,6 +2102,7 @@ + #end pcp-pmda-openmetrics # # pcp-pmda-lmsensors @@ -2090,6 +2126,7 @@ + # end pcp-pmda-lmsensors # # pcp-pmda-netcheck @@ -2215,6 +2252,7 @@ + # end pcp-pmda-apache # # pcp-pmda-bash @@ -2235,6 +2273,7 @@ + # end pcp-pmda-bash # # pcp-pmda-cifs @@ -2254,6 +2293,7 @@ + # end pcp-pmda-cifs # # pcp-pmda-cisco @@ -2274,6 +2314,7 @@ + # end pcp-pmda-cisco # # pcp-pmda-gfs2 @@ -2293,6 +2334,7 @@ + # end pcp-pmda-gfs2 # # pcp-pmda-logger @@ -2314,6 +2356,7 @@ + # end pcp-pmda-logger # # pcp-pmda-mailq @@ -2334,6 +2377,7 @@ + # end pcp-pmda-mailq # # pcp-pmda-mounts @@ -2354,6 +2398,7 @@ + # end pcp-pmda-mounts # # pcp-pmda-nvidia-gpu @@ -2373,6 +2418,7 @@ + # end pcp-pmda-nvidia-gpu # # pcp-pmda-roomtemp @@ -2433,6 +2479,7 @@ + # end pcp-pmda-sendmail # # pcp-pmda-shping @@ -2454,6 +2501,7 @@ + # end pcp-pmda-shping # # pcp-pmda-smart @@ -2472,6 +2520,7 @@ + #end pcp-pmda-smart # # pcp-pmda-sockets @@ -2490,6 +2539,7 @@ + #end pcp-pmda-sockets # # pcp-pmda-hacluster @@ -2507,6 +2557,7 @@ + # end pcp-pmda-hacluster # # pcp-pmda-summary @@ -2565,6 +2616,7 @@ + # end pcp-pmda-trace # # pcp-pmda-weblog @@ -2586,6 +2638,7 @@ + # end pcp-pmda-weblog # end C pmdas @@ -2944,8 +2997,6 @@ %if !%{disable_selinux} ls -1 %{buildroot}/%{_selinuxdir} |\ sed -e 's#^#'%{_selinuxdir}'\/#' > pcp-selinux.list -ls -1 %{buildroot}/%{_selinuxexecdir} |\ - sed -e 's#^#'%{_selinuxexecdir}'\/#' >> pcp-selinux.list ls -1 %{buildroot}/%{_libexecdir}/pcp/bin |\ grep -E 'selinux-setup' |\ sed -e 's#^#'%{_libexecdir}/pcp/bin'\/#' >> pcp-selinux.list @@ -3094,17 +3145,6 @@ %endif %endif #zeroconf -%if !%{disable_selinux} -%post selinux -%{selinux_handle_policy "$1" "pcpupstream"} - -%triggerin selinux -- docker-selinux -%{selinux_handle_policy "$1" "pcpupstream-docker"} - -%triggerin selinux -- container-selinux -%{selinux_handle_policy "$1" "pcpupstream-container"} -%endif - %post PCP_PMNS_DIR=%{_pmnsdir} PCP_LOG_DIR=%{_logsdir} @@ -3166,17 +3206,6 @@ %postun -n libpcp_web%{libpcp_web_sover} -p /sbin/ldconfig %endif -%if !%{disable_selinux} -%preun selinux -%{selinux_handle_policy "$1" "pcpupstream"} - -%triggerun selinux -- docker-selinux -%{selinux_handle_policy "$1" "pcpupstream-docker"} - -%triggerun selinux -- container-selinux -%{selinux_handle_policy "$1" "pcpupstream-container"} -%endif - %if 0%{?suse_version} %postun /sbin/ldconfig @@ -3188,6 +3217,25 @@ %endif %endif +%if !%{disable_selinux} +%pre selinux +%selinux_relabel_pre -s targeted + +%post selinux +PCP_SELINUX_DIR=%{_selinuxdir} +semodule -r pcpupstream-container >/dev/null 2>&1 || true +semodule -r pcpupstream-docker >/dev/null 2>&1 || true +semodule -r pcpupstream >/dev/null 2>&1 || true +%selinux_modules_install -s targeted "$PCP_SELINUX_DIR/pcp.pp.bz2" +%selinux_relabel_post -s targeted + +%postun selinux +if [ $1 -eq 0 ]; then + %selinux_modules_uninstall -s targeted pcp + %selinux_relabel_post -s targeted +fi +%endif + %files -f base.list # # Note: there are some headers (e.g. domain.h) and in a few cases some @@ -4068,7 +4116,6 @@ %if !%{disable_selinux} %files selinux -f pcp-selinux.list %dir %{_selinuxdir} -%dir %{_selinuxexecdir} %endif %if !%{disable_python3}