Skip to content

Commit

Permalink
fix: bz-2126966: use SIGTERM for rpm instead of SIGKILL (#3524)
Browse files Browse the repository at this point in the history
Signed-off-by: Xiangce Liu <[email protected]>

Signed-off-by: Xiangce Liu <[email protected]>
(cherry picked from commit 6fc4e78)
  • Loading branch information
xiangce authored and bfahr committed Sep 20, 2022
1 parent 7533005 commit e338a54
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion insights/specs/datasources/system_user_dirs.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

import grp
import pwd
import signal

from insights.core.context import HostContext
from insights.core.dr import SkipComponent
Expand All @@ -17,7 +18,8 @@ class LocalSpecs(Specs):
Local spec used only by the system_user_dirs datasource
"""
rpm_args = simple_command(
'rpm -qa --qf="[%{=NAME}; %{FILEMODES:perms}; %{FILEUSERNAME}; %{FILEGROUPNAME}\n]"'
'rpm -qa --qf="[%{=NAME}; %{FILEMODES:perms}; %{FILEUSERNAME}; %{FILEGROUPNAME}\n]"',
signum=signal.SIGTERM
)


Expand Down
2 changes: 1 addition & 1 deletion insights/specs/default.py
Original file line number Diff line number Diff line change
Expand Up @@ -541,7 +541,7 @@ class DefaultSpecs(Specs):
rhsm_releasever = simple_file('/var/lib/rhsm/cache/releasever.json')
rndc_status = simple_command("/usr/sbin/rndc status")
ros_config = simple_file("/var/lib/pcp/config/pmlogger/config.ros")
rpm_ostree_status = simple_command("/usr/bin/rpm-ostree status --json")
rpm_ostree_status = simple_command("/usr/bin/rpm-ostree status --json", signum=signal.SIGTERM)
rpm_V_packages = simple_command("/bin/rpm -V coreutils procps procps-ng shadow-utils passwd sudo chrony", keep_rc=True, signum=signal.SIGTERM)
rsyslog_conf = glob_file(["/etc/rsyslog.conf", "/etc/rsyslog.d/*.conf"])
samba = simple_file("/etc/samba/smb.conf")
Expand Down

0 comments on commit e338a54

Please sign in to comment.