1 %define plugin check_cups_queue
2 Summary: Nagios CUPS plugin
3 Name: nagios-plugin-%{plugin}
8 Source0: http://dev.lusis.org/nagios/check_cups_queue.txt
9 # Source0-md5: fe2dffc066980e2385d88755703f97fe
10 Patch0: %{name}-force-locales.patch
11 URL: http://dev.lusis.org/nagios/
13 Requires: cups-clients
17 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
19 %define _sysconfdir /etc/nagios/plugins
20 %define plugindir %{_prefix}/lib/nagios/plugins
23 This plugin will check the status of a remote CUPS print queue. It
24 will provide the size of the queue and optionally the age of the queue
31 cat > nagios.cfg <<'EOF'
35 command_name %{plugin}
36 command_line %{plugindir}/%{plugin} -H $HOSTADDRESS$
41 rm -rf $RPM_BUILD_ROOT
42 install -d $RPM_BUILD_ROOT{%{_sysconfdir},%{plugindir}}
43 install check_cups_queue.txt $RPM_BUILD_ROOT%{plugindir}/%{plugin}
44 cp -a nagios.cfg $RPM_BUILD_ROOT%{_sysconfdir}/%{plugin}.cfg
47 rm -rf $RPM_BUILD_ROOT
50 %defattr(644,root,root,755)
51 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{plugin}.cfg
52 %attr(755,root,root) %{plugindir}/%{plugin}