2020-10-15 16:47:45 +00:00
|
|
|
%{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
|
|
|
|
|
2021-04-01 10:59:45 +00:00
|
|
|
%global auditversion 0.3
|
|
|
|
|
2020-10-15 16:47:45 +00:00
|
|
|
Summary: A set of tools to gather troubleshooting information from a system
|
|
|
|
Name: sos
|
2021-03-26 07:40:22 +00:00
|
|
|
Version: 4.1
|
2021-04-01 13:33:41 +00:00
|
|
|
Release: 3%{?dist}
|
2021-04-01 10:59:45 +00:00
|
|
|
Group: Applications/System
|
|
|
|
Source0: https://github.com/sosreport/sos/archive/%{version}/sos-%{version}.tar.gz
|
|
|
|
Source1: sos-audit-%{auditversion}.tgz
|
2020-10-15 16:47:45 +00:00
|
|
|
License: GPLv2+
|
|
|
|
BuildArch: noarch
|
|
|
|
Url: https://github.com/sosreport/sos
|
|
|
|
BuildRequires: python3-devel
|
|
|
|
BuildRequires: gettext
|
|
|
|
Requires: libxml2-python3
|
2021-04-01 10:59:45 +00:00
|
|
|
#Requires: python3-rpm
|
2020-10-15 16:47:45 +00:00
|
|
|
Requires: tar
|
|
|
|
Requires: bzip2
|
|
|
|
Requires: xz
|
2021-04-01 10:59:45 +00:00
|
|
|
Recommends: python3-pexpect
|
|
|
|
Conflicts: vdsm < 4.40
|
2020-10-15 16:47:45 +00:00
|
|
|
Obsoletes: sos-collector <= 1.9
|
2021-04-01 10:59:45 +00:00
|
|
|
Patch1: sos-bz1925419-gluster-pubkeys-statusfile.patch
|
2020-10-15 16:47:45 +00:00
|
|
|
|
|
|
|
%description
|
|
|
|
Sos is a set of tools that gathers information about system
|
|
|
|
hardware and configuration. The information can then be used for
|
|
|
|
diagnostic purposes and debugging. Sos is commonly used to help
|
|
|
|
support technicians and developers.
|
|
|
|
|
|
|
|
%prep
|
|
|
|
%setup -qn %{name}-%{version}
|
2021-04-01 10:59:45 +00:00
|
|
|
%setup -T -D -a1 -q
|
|
|
|
%patch1 -p1
|
2020-10-15 16:47:45 +00:00
|
|
|
|
|
|
|
%build
|
|
|
|
%py3_build
|
|
|
|
|
|
|
|
%install
|
|
|
|
%py3_install '--install-scripts=%{_sbindir}'
|
|
|
|
|
|
|
|
install -d -m 755 %{buildroot}%{_sysconfdir}/%{name}
|
|
|
|
install -d -m 700 %{buildroot}%{_sysconfdir}/%{name}/cleaner
|
|
|
|
install -d -m 755 %{buildroot}%{_sysconfdir}/%{name}/presets.d
|
|
|
|
install -d -m 755 %{buildroot}%{_sysconfdir}/%{name}/groups.d
|
|
|
|
install -d -m 755 %{buildroot}%{_sysconfdir}/%{name}/extras.d
|
|
|
|
install -m 644 %{name}.conf %{buildroot}%{_sysconfdir}/%{name}/%{name}.conf
|
|
|
|
|
2021-03-26 07:40:22 +00:00
|
|
|
rm -rf %{buildroot}/usr/config/
|
|
|
|
|
2020-10-15 16:47:45 +00:00
|
|
|
%find_lang %{name} || echo 0
|
|
|
|
|
2021-04-01 10:59:45 +00:00
|
|
|
cd %{name}-audit-%{auditversion}
|
|
|
|
DESTDIR=%{buildroot} ./install.sh
|
|
|
|
cd ..
|
|
|
|
|
2020-10-15 16:47:45 +00:00
|
|
|
%files -f %{name}.lang
|
|
|
|
%{_sbindir}/sos
|
|
|
|
%{_sbindir}/sosreport
|
|
|
|
%{_sbindir}/sos-collector
|
2021-04-01 10:59:45 +00:00
|
|
|
#%dir /etc/sos/cleaner
|
2020-10-15 16:47:45 +00:00
|
|
|
%dir /etc/sos/presets.d
|
|
|
|
%dir /etc/sos/extras.d
|
|
|
|
%dir /etc/sos/groups.d
|
|
|
|
%{python3_sitelib}/*
|
|
|
|
%{_mandir}/man1/*
|
2021-04-01 13:33:41 +00:00
|
|
|
%{_mandir}/man5/sos.conf.5.gz
|
2020-10-15 16:47:45 +00:00
|
|
|
%doc AUTHORS README.md
|
|
|
|
%license LICENSE
|
|
|
|
%config(noreplace) %{_sysconfdir}/sos/sos.conf
|
2021-04-01 10:59:45 +00:00
|
|
|
%config(noreplace) %{_sysconfdir}/sos/cleaner
|
2020-10-15 16:47:45 +00:00
|
|
|
|
|
|
|
|
2021-04-01 10:59:45 +00:00
|
|
|
%package audit
|
|
|
|
Summary: Audit use of some commands for support purposes
|
|
|
|
License: GPLv2+
|
|
|
|
Group: Application/System
|
2020-10-15 16:47:45 +00:00
|
|
|
|
2021-04-01 10:59:45 +00:00
|
|
|
%description audit
|
2020-10-15 16:47:45 +00:00
|
|
|
|
2021-04-01 10:59:45 +00:00
|
|
|
Sos-audit provides configuration files for the Linux Auditing System
|
|
|
|
to track the use of some commands capable of changing the configuration
|
|
|
|
of the system. Currently storage and filesystem commands are audited.
|
2020-10-15 16:47:45 +00:00
|
|
|
|
2021-04-01 10:59:45 +00:00
|
|
|
%post audit
|
|
|
|
%{_sbindir}/sos-audit.sh
|
2020-10-15 16:47:45 +00:00
|
|
|
|
2021-04-01 10:59:45 +00:00
|
|
|
%files audit
|
|
|
|
%defattr(755,root,root,-)
|
|
|
|
%{_sbindir}/sos-audit.sh
|
|
|
|
%defattr(644,root,root,-)
|
|
|
|
%config(noreplace) %{_sysconfdir}/sos/sos-audit.conf
|
|
|
|
%defattr(444,root,root,-)
|
|
|
|
%{_prefix}/lib/sos/audit/*
|
|
|
|
%{_mandir}/man5/sos-audit.conf.5.gz
|
|
|
|
%{_mandir}/man8/sos-audit.sh.8.gz
|
|
|
|
%ghost /etc/audit/rules.d/40-sos-filesystem.rules
|
|
|
|
%ghost /etc/audit/rules.d/40-sos-storage.rules
|
2020-10-15 16:47:45 +00:00
|
|
|
|
|
|
|
|
2021-04-01 10:59:45 +00:00
|
|
|
%changelog
|
2021-04-01 13:33:41 +00:00
|
|
|
* Thu Apr 01 2021 Pavel Moravec <pmoravec@redhat.com> - 4.1-3
|
|
|
|
- adding sos-audit
|
|
|
|
- [gluster] Add glusterd public keys and status files
|
|
|
|
Resolves: bz1925419
|
2020-10-15 16:47:45 +00:00
|
|
|
|
2021-04-01 10:59:45 +00:00
|
|
|
* Wed Mar 10 2021 Sandro Bonazzola <sbonazzo@redhat.com> - 4.1-1
|
|
|
|
- Rebase to 4.1
|
2020-10-15 16:47:45 +00:00
|
|
|
|