1 |
commit: da9387c1434a6e4bdf146be4fefb23e0cb5ae0a2 |
2 |
Author: Ian Stakenvicius <axs <AT> gentoo <DOT> org> |
3 |
AuthorDate: Thu Oct 13 20:52:49 2016 +0000 |
4 |
Commit: Ian Stakenvicius <axs <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu Oct 13 20:53:31 2016 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=da9387c1 |
7 |
|
8 |
net-analyzer/check_mk: peg slot on media-libs/libpng , remove old |
9 |
|
10 |
A couple of simple things to ensure repoman reports cleanly |
11 |
|
12 |
Package-Manager: portage-2.3.0 |
13 |
|
14 |
net-analyzer/check_mk/check_mk-1.2.4_p5-r1.ebuild | 4 +- |
15 |
net-analyzer/check_mk/check_mk-1.2.4_p5.ebuild | 306 ---------------------- |
16 |
2 files changed, 2 insertions(+), 308 deletions(-) |
17 |
|
18 |
diff --git a/net-analyzer/check_mk/check_mk-1.2.4_p5-r1.ebuild b/net-analyzer/check_mk/check_mk-1.2.4_p5-r1.ebuild |
19 |
index c13250e..721bed0 100644 |
20 |
--- a/net-analyzer/check_mk/check_mk-1.2.4_p5-r1.ebuild |
21 |
+++ b/net-analyzer/check_mk/check_mk-1.2.4_p5-r1.ebuild |
22 |
@@ -1,4 +1,4 @@ |
23 |
-# Copyright 1999-2015 Gentoo Foundation |
24 |
+# Copyright 1999-2016 Gentoo Foundation |
25 |
# Distributed under the terms of the GNU General Public License v2 |
26 |
# $Id$ |
27 |
|
28 |
@@ -24,7 +24,7 @@ DEPEND="wato? ( app-admin/sudo ) |
29 |
xinetd? ( sys-apps/xinetd ) |
30 |
!agent-only? ( || ( net-analyzer/nagios-core net-analyzer/icinga ) ) |
31 |
!agent-only? ( www-servers/apache www-apache/mod_python ) |
32 |
- media-libs/libpng" |
33 |
+ media-libs/libpng:0" |
34 |
RDEPEND="${DEPEND}" |
35 |
|
36 |
REQUIRED_USE=" |
37 |
|
38 |
diff --git a/net-analyzer/check_mk/check_mk-1.2.4_p5.ebuild b/net-analyzer/check_mk/check_mk-1.2.4_p5.ebuild |
39 |
deleted file mode 100644 |
40 |
index 004203d..00000000 |
41 |
--- a/net-analyzer/check_mk/check_mk-1.2.4_p5.ebuild |
42 |
+++ /dev/null |
43 |
@@ -1,306 +0,0 @@ |
44 |
-# Copyright 1999-2014 Gentoo Foundation |
45 |
-# Distributed under the terms of the GNU General Public License v2 |
46 |
-# $Id$ |
47 |
- |
48 |
-EAPI="5" |
49 |
-MY_P="${P/_p/p}" |
50 |
-MY_PV="${MY_P/check_mk-/}" |
51 |
-S="${WORKDIR}/${MY_P}" |
52 |
- |
53 |
-inherit eutils toolchain-funcs |
54 |
- |
55 |
-DESCRIPTION="General purpose Nagios/Icinga plugin for retrieving data" |
56 |
-HOMEPAGE="http://mathias-kettner.de/check_mk.html" |
57 |
-SRC_URI="http://mathias-kettner.de/download/${MY_P}.tar.gz" |
58 |
- |
59 |
-LICENSE="GPL-2" |
60 |
-SLOT="0" |
61 |
-KEYWORDS="~amd64 ~x86" |
62 |
-IUSE="agent-only apache_status dmi_sysinfo livestatus logwatch mysql |
63 |
-nfsexports oracle postgres smart wato xinetd zypper" |
64 |
-REQUIRED_USE="livestatus? ( !agent-only ) |
65 |
-wato? ( !agent-only )" |
66 |
- |
67 |
-RDEPEND="${DEPEND} |
68 |
- ( || ( dev-lang/python:2.6 dev-lang/python:2.7 ) ) |
69 |
- wato? ( app-admin/sudo ) |
70 |
- xinetd? ( sys-apps/xinetd ) |
71 |
- !agent-only? ( || ( net-analyzer/nagios-core net-analyzer/icinga ) ) |
72 |
- !agent-only? ( www-servers/apache www-apache/mod_python )" |
73 |
- |
74 |
-src_prepare() { |
75 |
- # modify setup.sh for gentoo |
76 |
- epatch "${FILESDIR}"/${PN}-1.2.4p3-setup.sh.patch |
77 |
-} |
78 |
- |
79 |
-src_configure() { |
80 |
- if has_version net-analyzer/nagios-core; then |
81 |
- export mydaemon=nagios |
82 |
- export nagpipe=/var/nagios/rw/nagios.cmd |
83 |
- export check_result_path=/var/nagios/spool/checkresults |
84 |
- export nagios_status_file=/var/nagios/status.dat |
85 |
- export rrd_path=/var/nagios/perfdata |
86 |
- else |
87 |
- export mydaemon=icinga |
88 |
- export nagpipe=/var/lib/icinga/rw/icinga.cmd |
89 |
- export check_result_path=/var/lib/icinga/spool/checkresults |
90 |
- export nagios_status_file=/var/lib/icinga/status.dat |
91 |
- export rrd_path=/var/lib/icinga/perfdata |
92 |
- fi |
93 |
- |
94 |
- export nagiosuser=${mydaemon} |
95 |
- export nagios_binary=/usr/sbin/${mydaemon} |
96 |
- export nagios_config_file=/etc/${mydaemon}/${mydaemon}.cfg |
97 |
- export nagconfdir=/etc/${mydaemon}/check_mk.d |
98 |
- export nagios_startscript=/etc/init.d/${mydaemon} |
99 |
- export htpasswd_file=/etc/${mydaemon}/htpasswd.users |
100 |
- export nagios_auth_name="${mydaemon} Access" |
101 |
- export docdir=/usr/share/doc/${PF} |
102 |
- export checkmandir=/usr/share/doc/${PF}/checks |
103 |
- export check_icmp_path=/usr/lib/nagios/plugins/check_icmp |
104 |
- export wwwuser=apache |
105 |
- export wwwgroup=apache |
106 |
- export apache_config_dir=/etc/apache2/modules.d/ |
107 |
- |
108 |
- if use livestatus; then |
109 |
- export enable_livestatus=yes |
110 |
- else |
111 |
- export enable_livestatus=no |
112 |
- fi |
113 |
- |
114 |
- export STRIPPROG=/bin/true |
115 |
-} |
116 |
- |
117 |
-src_compile() { |
118 |
- DESTDIR=${S} ./setup.sh --yes || die "Error while running setup.sh" |
119 |
- |
120 |
- # compile waitmax |
121 |
- cd "${S}"/usr/share/check_mk/agents || die "Couldn't cd to ${S}/usr/share/check_mk/agents" |
122 |
- if [[ -f waitmax ]]; then |
123 |
- rm waitmax || die "Couldn't delete precompiled waitmax file" |
124 |
- fi |
125 |
- sed -i -e 's#gcc -s -o waitmax waitmax\.c#gcc -o waitmax waitmax.c#' "${S}"/usr/share/check_mk/agents/Makefile || die "Couldn't modify remove strip from waitmax Makefile" |
126 |
- emake CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" CC="$(tc-getCC)" || die "Couldn't compile waitmax" |
127 |
-} |
128 |
- |
129 |
-src_install() { |
130 |
- if ! use agent-only; then |
131 |
- # Apache configuration |
132 |
- insinto /etc/apache2/modules.d |
133 |
- doins etc/apache2/modules.d/zzz_check_mk.conf |
134 |
- |
135 |
- if use wato; then |
136 |
- # sudoers configuration |
137 |
- cat << EOF > "${T}"/check_mk || die |
138 |
-# Needed for WATO - the Check_MK Web Administration Tool |
139 |
-Defaults:apache !requiretty |
140 |
-apache ALL = (root) NOPASSWD: /usr/bin/check_mk --automation * |
141 |
-EOF |
142 |
- insinto /etc/sudoers.d |
143 |
- doins "${T}"/check_mk |
144 |
- fi |
145 |
- |
146 |
- # check_mk configuration |
147 |
- keepdir /etc/check_mk |
148 |
- insinto /etc/check_mk |
149 |
- doins etc/check_mk/main.mk |
150 |
- doins etc/check_mk/main.mk-${MY_PV} |
151 |
- doins etc/check_mk/multisite.mk |
152 |
- doins etc/check_mk/multisite.mk-${MY_PV} |
153 |
- keepdir /etc/check_mk/conf.d |
154 |
- insinto /etc/check_mk/conf.d |
155 |
- doins etc/check_mk/conf.d/README |
156 |
- keepdir /etc/check_mk/conf.d/wato |
157 |
- touch "${D}"/etc/check_mk/conf.d/distributed_wato.mk |
158 |
- keepdir /etc/check_mk/multisite.d |
159 |
- keepdir /etc/check_mk/multisite.d/wato |
160 |
- touch "${D}"/etc/check_mk/multisite.d/sites.mk |
161 |
- |
162 |
- insinto /etc/${mydaemon} |
163 |
- doins etc/${mydaemon}/auth.serials |
164 |
- |
165 |
- # Nagios / Icinga check_mk templates |
166 |
- insinto /etc/${mydaemon}/check_mk.d |
167 |
- doins etc/${mydaemon}/check_mk.d/check_mk_templates.cfg |
168 |
- |
169 |
- dobin usr/bin/check_mk |
170 |
- dobin usr/bin/mkp |
171 |
- insinto /usr/bin |
172 |
- doins usr/bin/cmk |
173 |
- |
174 |
- # remove compiled agent_modbus |
175 |
- if [[ -f ${S}/usr/share/doc/${PF}/treasures/modbus/agent_modbus ]]; then |
176 |
- rm "${S}"/usr/share/doc/${PF}/treasures/modbus/agent_modbus || die "Couldn't remove precompiled agent_modbus" |
177 |
- fi |
178 |
- |
179 |
- insinto /usr/share/check_mk |
180 |
- doins -r usr/share/check_mk/* |
181 |
- |
182 |
- keepdir /var/lib/check_mk/autochecks |
183 |
- keepdir /var/lib/check_mk/cache |
184 |
- keepdir /var/lib/check_mk/counters |
185 |
- keepdir /var/lib/check_mk/logwatch |
186 |
- keepdir /var/lib/check_mk/notify |
187 |
- keepdir /var/lib/check_mk/packages |
188 |
- insinto /var/lib/check_mk/packages |
189 |
- doins var/lib/check_mk/packages/check_mk |
190 |
- keepdir /var/lib/check_mk/precompiled |
191 |
- keepdir /var/lib/check_mk/snmpwalks |
192 |
- keepdir /var/lib/check_mk/tmp |
193 |
- keepdir /var/lib/check_mk/wato |
194 |
- keepdir /var/lib/check_mk/web |
195 |
- |
196 |
- # Update check_mk defaults |
197 |
- sed -i -e "s#^\(check_mk_automation\s*= 'sudo -u\) portage \(.*\)\$#\1 ${mydaemon} \2#" "${D}"/usr/share/check_mk/modules/defaults || die "Couldn't update check_mk defaults" |
198 |
- cp "${D}"/usr/share/check_mk/modules/defaults "${D}"/usr/share/check_mk/web/htdocs/defaults.py || die "Couldn't copy check_mk defaults" |
199 |
- |
200 |
- # Change permissions |
201 |
- fowners -R ${mydaemon}:apache /etc/${mydaemon}/auth.serials |
202 |
- fperms -R 0660 /etc/${mydaemon}/auth.serials |
203 |
- fowners -R ${mydaemon}:${mydaemon} /etc/${mydaemon}/check_mk.d |
204 |
- fperms -R 0775 /etc/${mydaemon}/check_mk.d |
205 |
- fowners -R root:apache /etc/check_mk/conf.d/wato |
206 |
- fperms -R 0775 /etc/check_mk/conf.d/wato |
207 |
- fowners root:apache /etc/check_mk/conf.d/distributed_wato.mk |
208 |
- fperms 0664 /etc/check_mk/conf.d/distributed_wato.mk |
209 |
- fowners -R root:apache /etc/check_mk/multisite.d/wato |
210 |
- fperms -R 0775 /etc/check_mk/multisite.d/wato |
211 |
- fowners root:apache /etc/check_mk/multisite.d/sites.mk |
212 |
- fperms 0664 /etc/check_mk/multisite.d/sites.mk |
213 |
- fowners root:${mydaemon} /var/lib/check_mk/cache |
214 |
- fperms 0775 /var/lib/check_mk/counters |
215 |
- fowners -R root:${mydaemon} /var/lib/check_mk/counters |
216 |
- fperms 0775 /var/lib/check_mk/notify |
217 |
- fowners -R root:${mydaemon} /var/lib/check_mk/notify |
218 |
- fperms 0775 /var/lib/check_mk/logwatch |
219 |
- fowners -R root:${mydaemon} /var/lib/check_mk/logwatch |
220 |
- fperms 0775 /var/lib/check_mk/cache |
221 |
- fowners -R root:${mydaemon} /var/lib/check_mk/cache |
222 |
- fperms -R 0775 /var/lib/check_mk/tmp |
223 |
- fowners -R root:apache /var/lib/check_mk/tmp |
224 |
- fperms -R 0775 /var/lib/check_mk/web |
225 |
- fowners -R root:apache /var/lib/check_mk/web |
226 |
- fperms -R 0775 /var/lib/check_mk/wato |
227 |
- fowners -R root:apache /var/lib/check_mk/wato |
228 |
- fi |
229 |
- |
230 |
- # Install agent related files |
231 |
- newbin usr/share/check_mk/agents/check_mk_agent.linux check_mk_agent |
232 |
- dobin usr/share/check_mk/agents/waitmax |
233 |
- |
234 |
- if use xinetd; then |
235 |
- insinto /etc/xinetd.d |
236 |
- newins usr/share/check_mk/agents/xinetd.conf check_mk |
237 |
- fi |
238 |
- |
239 |
- keepdir /usr/lib/check_mk_agent/local |
240 |
- keepdir /usr/lib/check_mk_agent/plugins |
241 |
- |
242 |
- # Install Livestatus |
243 |
- if use livestatus; then |
244 |
- cat << EOF > "${T}"/livestatus.cfg || die |
245 |
-define module{ |
246 |
- module_name mk-livestatus |
247 |
- module_type neb |
248 |
- path /usr/lib/check_mk/livestatus.o |
249 |
- args /var/lib/${mydaemon}/rw/live |
250 |
- } |
251 |
-EOF |
252 |
- |
253 |
- insinto /etc/${mydaemon}/modules |
254 |
- doins "${T}"/livestatus.cfg |
255 |
- fowners ${mydaemon}:${mydaemon} /etc/${mydaemon}/modules/livestatus.cfg |
256 |
- |
257 |
- insinto /usr/lib/check_mk |
258 |
- doins usr/lib/check_mk/livestatus.o |
259 |
- |
260 |
- dobin usr/bin/unixcat |
261 |
- |
262 |
- keepdir /usr/share/check_mk/livestatus |
263 |
- fi |
264 |
- |
265 |
- # Documentation |
266 |
- if ! use agent-only; then |
267 |
- dodoc -r usr/share/doc/${PF}/* |
268 |
- docompress -x /usr/share/doc/${PF}/checks/ |
269 |
- else |
270 |
- dodoc usr/share/doc/${PF}/AUTHORS usr/share/doc/${PF}/COPYING usr/share/doc/${PF}/ChangeLog |
271 |
- docompress |
272 |
- fi |
273 |
- |
274 |
- # Install the check_mk_agent logwatch plugin |
275 |
- if use logwatch; then |
276 |
- insinto /etc/check_mk |
277 |
- doins usr/share/check_mk/agents/logwatch.cfg |
278 |
- exeinto /usr/lib/check_mk_agent/plugins |
279 |
- doexe usr/share/check_mk/agents/plugins/mk_logwatch |
280 |
- fi |
281 |
- |
282 |
- # Install the check_mk_agent smart plugin |
283 |
- if use smart; then |
284 |
- exeinto /usr/lib/check_mk_agent/plugins |
285 |
- doexe usr/share/check_mk/agents/plugins/smart |
286 |
- fi |
287 |
- |
288 |
- # Install the check_mk_agent mysql plugin |
289 |
- if use mysql; then |
290 |
- exeinto /usr/lib/check_mk_agent/plugins |
291 |
- doexe usr/share/check_mk/agents/plugins/mk_mysql |
292 |
- fi |
293 |
- |
294 |
- # Install the check_mk_agent postgres plugin |
295 |
- if use postgres; then |
296 |
- exeinto /usr/lib/check_mk_agent/plugins |
297 |
- doexe usr/share/check_mk/agents/plugins/mk_postgres |
298 |
- fi |
299 |
- |
300 |
- # Install the check_mk_agent apache_status plugin |
301 |
- if use apache_status; then |
302 |
- exeinto /usr/lib/check_mk_agent/plugins |
303 |
- doexe usr/share/check_mk/agents/plugins/apache_status |
304 |
- fi |
305 |
- |
306 |
- # Install the check_mk_agent zypper plugin |
307 |
- if use zypper; then |
308 |
- exeinto /usr/lib/check_mk_agent/plugins |
309 |
- doexe usr/share/check_mk/agents/plugins/mk_zypper |
310 |
- fi |
311 |
- |
312 |
- # Install the check_mk_agent oracle plugin |
313 |
- if use oracle; then |
314 |
- exeinto /usr/lib/check_mk_agent/plugins |
315 |
- doexe usr/share/check_mk/agents/plugins/mk_oracle |
316 |
- fi |
317 |
- |
318 |
- # Install the check_mk_agent nfsexports plugin |
319 |
- if use nfsexports; then |
320 |
- exeinto /usr/lib/check_mk_agent/plugins |
321 |
- doexe usr/share/check_mk/agents/plugins/nfsexports |
322 |
- fi |
323 |
- |
324 |
- # Install the check_mk_agent dmi_sysinfo plugin |
325 |
- if use dmi_sysinfo; then |
326 |
- exeinto /usr/lib/check_mk_agent/plugins |
327 |
- doexe usr/share/check_mk/agents/plugins/dmi_sysinfo |
328 |
- fi |
329 |
-} |
330 |
- |
331 |
-pkg_postinst() { |
332 |
- if ! use agent-only; then |
333 |
- elog "IMPORTANT: Please add the following line to your" |
334 |
- elog "/etc/${mydaemon}/${mydaemon}.cfg, so that" |
335 |
- elog "${mydaemon} can load your check_mk configuration." |
336 |
- elog |
337 |
- elog " cfg_dir=/etc/${mydaemon}/check_mk.d" |
338 |
- elog |
339 |
- fi |
340 |
- if use wato; then |
341 |
- elog "INFO: Your webserver needs write access to" |
342 |
- elog "/etc/${mydaemon}/htpasswd.users!" |
343 |
- elog "otherwise wato will not function correctly!" |
344 |
- elog |
345 |
- elog "chown ${mydaemon}: /etc/${mydaemon}/htpasswd.users" |
346 |
- elog "chmod 660 /etc/${mydaemon}/htpasswd.users" |
347 |
- elog |
348 |
- fi |
349 |
-} |