Incorporate changes from openSUSE OBS
* Improve RPM groups * Improve grammar in RPM subpackage descriptions * Remove redundant %clean section from rpm spec * Fix service.d dir which was not referenced by any package * Use sle_version instead of deprecated leap_version see https://en.opensuse.org/openSUSE:Build_Service_cross_distribution_howto#leap_version_macro_.28deprecated.29 * Also add systemd limits file to openSUSE Tumbleweed * Documentation should not hard-require the program as it is technically "usable" without it.
This commit is contained in:
parent
b94ddfeb68
commit
1e989a6dad
39
icinga2.spec
39
icinga2.spec
|
@ -60,7 +60,7 @@
|
||||||
%define apachegroup www
|
%define apachegroup www
|
||||||
%if 0%{?suse_version} >= 1310
|
%if 0%{?suse_version} >= 1310
|
||||||
%define use_systemd 1
|
%define use_systemd 1
|
||||||
%if 0%{?leap_version} >= 420100 || 0%{?sle_version} >= 120200
|
%if 0%{?sle_version} >= 120200 || 0%{?suse_version} > 1320
|
||||||
# for installing limits.conf on systemd >= 228
|
# for installing limits.conf on systemd >= 228
|
||||||
%define configure_systemd_limits 1
|
%define configure_systemd_limits 1
|
||||||
%else
|
%else
|
||||||
|
@ -86,7 +86,7 @@ Version: 2.8.0
|
||||||
Release: %{revision}%{?dist}
|
Release: %{revision}%{?dist}
|
||||||
License: GPL-2.0+
|
License: GPL-2.0+
|
||||||
URL: https://www.icinga.com/
|
URL: https://www.icinga.com/
|
||||||
Group: Applications/System
|
Group: System/Monitoring
|
||||||
Source: https://github.com/Icinga/%{name}/archive/v%{version}.tar.gz
|
Source: https://github.com/Icinga/%{name}/archive/v%{version}.tar.gz
|
||||||
|
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||||
|
@ -97,7 +97,7 @@ Meta package for Icinga 2 Core, DB IDO and Web.
|
||||||
|
|
||||||
%package bin
|
%package bin
|
||||||
Summary: Icinga 2 binaries and libraries
|
Summary: Icinga 2 binaries and libraries
|
||||||
Group: Applications/System
|
Group: System/Monitoring
|
||||||
|
|
||||||
%if "%{_vendor}" == "suse"
|
%if "%{_vendor}" == "suse"
|
||||||
PreReq: permissions
|
PreReq: permissions
|
||||||
|
@ -160,11 +160,11 @@ Requires: %{name}-libs = %{version}-%{release}
|
||||||
|
|
||||||
%description bin
|
%description bin
|
||||||
Icinga 2 is a general-purpose network monitoring application.
|
Icinga 2 is a general-purpose network monitoring application.
|
||||||
Provides binaries for Icinga 2 Core.
|
This subpackage provides the binaries for Icinga 2 Core.
|
||||||
|
|
||||||
%package common
|
%package common
|
||||||
Summary: Common Icinga 2 configuration
|
Summary: Common Icinga 2 configuration
|
||||||
Group: Applications/System
|
Group: System/Monitoring
|
||||||
%if (0%{?amzn} || 0%{?fedora} || 0%{?rhel})
|
%if (0%{?amzn} || 0%{?fedora} || 0%{?rhel})
|
||||||
Requires(pre): shadow-utils
|
Requires(pre): shadow-utils
|
||||||
Requires(post): shadow-utils
|
Requires(post): shadow-utils
|
||||||
|
@ -185,31 +185,30 @@ Recommends: logrotate
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%description common
|
%description common
|
||||||
Provides common directories, uid and gid among Icinga 2 related
|
This subpackage provides common directories, and the UID and GUID definitions
|
||||||
packages.
|
among Icinga 2 related packages.
|
||||||
|
|
||||||
|
|
||||||
%package doc
|
%package doc
|
||||||
Summary: Documentation for Icinga 2
|
Summary: Documentation for Icinga 2
|
||||||
Group: Applications/System
|
Group: Documentation/Other
|
||||||
Requires: %{name} = %{version}-%{release}
|
|
||||||
|
|
||||||
%description doc
|
%description doc
|
||||||
Provides documentation for Icinga 2.
|
This subpackage provides documentation for Icinga 2.
|
||||||
|
|
||||||
|
|
||||||
%package libs
|
%package libs
|
||||||
Summary: Libraries for Icinga 2
|
Summary: Libraries for Icinga 2
|
||||||
Group: Applications/System
|
Group: System/Libraries
|
||||||
Requires: %{name}-common = %{version}-%{release}
|
Requires: %{name}-common = %{version}-%{release}
|
||||||
|
|
||||||
%description libs
|
%description libs
|
||||||
Provides internal libraries for the daemon or studio.
|
This subpackage provides the internal libraries for the daemon or studio.
|
||||||
|
|
||||||
|
|
||||||
%package ido-mysql
|
%package ido-mysql
|
||||||
Summary: IDO MySQL database backend for Icinga 2
|
Summary: IDO MySQL database backend for Icinga 2
|
||||||
Group: Applications/System
|
Group: System/Monitoring
|
||||||
%if "%{_vendor}" == "suse"
|
%if "%{_vendor}" == "suse"
|
||||||
BuildRequires: libmysqlclient-devel
|
BuildRequires: libmysqlclient-devel
|
||||||
%if 0%{?suse_version} >= 1310
|
%if 0%{?suse_version} >= 1310
|
||||||
|
@ -229,7 +228,7 @@ IDOUtils schema >= 1.12
|
||||||
|
|
||||||
%package ido-pgsql
|
%package ido-pgsql
|
||||||
Summary: IDO PostgreSQL database backend for Icinga 2
|
Summary: IDO PostgreSQL database backend for Icinga 2
|
||||||
Group: Applications/System
|
Group: System/Monitoring
|
||||||
%if "%{_vendor}" == "suse" && 0%{?suse_version} < 1210
|
%if "%{_vendor}" == "suse" && 0%{?suse_version} < 1210
|
||||||
BuildRequires: postgresql-devel >= 8.4
|
BuildRequires: postgresql-devel >= 8.4
|
||||||
%else
|
%else
|
||||||
|
@ -247,7 +246,7 @@ IDOUtils schema >= 1.12
|
||||||
|
|
||||||
%package selinux
|
%package selinux
|
||||||
Summary: SELinux policy module supporting icinga2
|
Summary: SELinux policy module supporting icinga2
|
||||||
Group: System Environment/Base
|
Group: System/Base
|
||||||
BuildRequires: checkpolicy, selinux-policy-devel, hardlink
|
BuildRequires: checkpolicy, selinux-policy-devel, hardlink
|
||||||
Requires: %{name} = %{version}-%{release}
|
Requires: %{name} = %{version}-%{release}
|
||||||
Requires(post): policycoreutils-python
|
Requires(post): policycoreutils-python
|
||||||
|
@ -261,7 +260,7 @@ SELinux policy module supporting icinga2
|
||||||
%if 0%{?fedora}
|
%if 0%{?fedora}
|
||||||
%package studio
|
%package studio
|
||||||
Summary: Studio for Icinga 2
|
Summary: Studio for Icinga 2
|
||||||
Group: Applications/System
|
Group: System/Monitoring
|
||||||
Requires: %{name}-libs = %{version}-%{release}
|
Requires: %{name}-libs = %{version}-%{release}
|
||||||
Requires: wxGTK3
|
Requires: wxGTK3
|
||||||
|
|
||||||
|
@ -272,7 +271,7 @@ Provides a GUI for the Icinga 2 API.
|
||||||
|
|
||||||
%package -n vim-icinga2
|
%package -n vim-icinga2
|
||||||
Summary: Vim syntax highlighting for icinga2
|
Summary: Vim syntax highlighting for icinga2
|
||||||
Group: Applications/System
|
Group: Productivity/Text/Editors
|
||||||
%if "%{_vendor}" == "suse"
|
%if "%{_vendor}" == "suse"
|
||||||
BuildRequires: vim
|
BuildRequires: vim
|
||||||
Requires: vim
|
Requires: vim
|
||||||
|
@ -286,7 +285,7 @@ Vim syntax highlighting for icinga2
|
||||||
|
|
||||||
%package -n nano-icinga2
|
%package -n nano-icinga2
|
||||||
Summary: Nano syntax highlighting for icinga2
|
Summary: Nano syntax highlighting for icinga2
|
||||||
Group: Applications/System
|
Group: Productivity/Text/Editors
|
||||||
Requires: nano
|
Requires: nano
|
||||||
|
|
||||||
%description -n nano-icinga2
|
%description -n nano-icinga2
|
||||||
|
@ -431,9 +430,6 @@ install -D -m 0644 tools/syntax/vim/ftdetect/%{name}.vim %{buildroot}%{_datadir}
|
||||||
|
|
||||||
install -D -m 0644 tools/syntax/nano/%{name}.nanorc %{buildroot}%{_datadir}/nano/%{name}.nanorc
|
install -D -m 0644 tools/syntax/nano/%{name}.nanorc %{buildroot}%{_datadir}/nano/%{name}.nanorc
|
||||||
|
|
||||||
%clean
|
|
||||||
[ "%{buildroot}" != "/" ] && [ -d "%{buildroot}" ] && rm -rf %{buildroot}
|
|
||||||
|
|
||||||
%pre common
|
%pre common
|
||||||
getent group %{icinga_group} >/dev/null || %{_sbindir}/groupadd -r %{icinga_group}
|
getent group %{icinga_group} >/dev/null || %{_sbindir}/groupadd -r %{icinga_group}
|
||||||
getent group %{icingacmd_group} >/dev/null || %{_sbindir}/groupadd -r %{icingacmd_group}
|
getent group %{icingacmd_group} >/dev/null || %{_sbindir}/groupadd -r %{icingacmd_group}
|
||||||
|
@ -663,6 +659,7 @@ fi
|
||||||
%if 0%{?use_systemd}
|
%if 0%{?use_systemd}
|
||||||
%attr(644,root,root) %{_unitdir}/%{name}.service
|
%attr(644,root,root) %{_unitdir}/%{name}.service
|
||||||
%if 0%{?configure_systemd_limits}
|
%if 0%{?configure_systemd_limits}
|
||||||
|
%dir /etc/systemd/system/%{name}.service.d
|
||||||
%attr(644,root,root) %config(noreplace) /etc/systemd/system/%{name}.service.d/limits.conf
|
%attr(644,root,root) %config(noreplace) /etc/systemd/system/%{name}.service.d/limits.conf
|
||||||
%endif
|
%endif
|
||||||
%else
|
%else
|
||||||
|
|
Loading…
Reference in New Issue