File monitoring-plugins-tw_cli.spec of Package monitoring-plugins-tw_cli

# spec file for package monitoring-plugins-tw_cli
# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany.
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via

Name:           monitoring-plugins-tw_cli
Summary:        Reporting the RAID status of 3ware raids
Version:        0.3.1
Release:        100
License:        BSD-4-Clause
Group:          System/Monitoring
Patch1:         check_tw_cli.patch
%if 0%{?suse_version} > 1020
# nagios can execute the script with embedded perl
Recommends:     perl
Requires:       perl
BuildRequires:  nagios-rpm-macros
Provides:       nagios-plugins-tw_cli = %{version}-%{release}
Obsoletes:      nagios-plugins-tw_cli < %{version}-%{release}
Requires:       tw_cli
BuildArch:      noarch
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

check_tw_cli reports the raidstatus of 3ware raids based on the results of
tw_cli. It was basicly tested with the newer tw_cli tool from the 9.2.x code
set which supports sysfs.

IMHO this plugin should work with older tw_cli version, too. Feedback is very
welcome! Testhardware is limited here, so I'm instructed by your feedback.

%setup -q -T -c %{name}
install -m644 %{SOURCE0} .
%patch1 -p0


install -D -m755 %{buildroot}/%{nagios_plugindir}/check_tw_cli

rm -rf %{buildroot}

# avoid build dependecy of nagios - own the dirs
%dir %{nagios_libdir}
%dir %{nagios_plugindir}

openSUSE Build Service is sponsored by