Gentoo Archives: gentoo-commits

From: Matt Thode <prometheanfire@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: net-analyzer/icinga2/, net-analyzer/icinga2/files/
Date: Thu, 31 Aug 2017 16:55:58
Message-Id: 1504198527.ba9c60694d004d01b0426c8d3d33cb7551054acd.prometheanfire@gentoo
1 commit: ba9c60694d004d01b0426c8d3d33cb7551054acd
2 Author: Matthew Thode <prometheanfire <AT> gentoo <DOT> org>
3 AuthorDate: Thu Aug 31 16:49:14 2017 +0000
4 Commit: Matt Thode <prometheanfire <AT> gentoo <DOT> org>
5 CommitDate: Thu Aug 31 16:55:27 2017 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ba9c6069
7
8 net-analyzer/icinga2: fixing ownership of the config directory
9
10 Package-Manager: Portage-2.3.6, Repoman-2.3.3
11 RepoMan-Options: --force
12
13 net-analyzer/icinga2/Manifest | 2 -
14 net-analyzer/icinga2/files/icinga2.confd | 4 -
15 net-analyzer/icinga2/icinga2-2.6.2.ebuild | 176 ---------------------
16 net-analyzer/icinga2/icinga2-2.6.3-r1.ebuild | 175 --------------------
17 ...cinga2-2.7.0.ebuild => icinga2-2.7.0-r1.ebuild} | 3 +-
18 net-analyzer/icinga2/icinga2-9999.ebuild | 9 +-
19 6 files changed, 7 insertions(+), 362 deletions(-)
20
21 diff --git a/net-analyzer/icinga2/Manifest b/net-analyzer/icinga2/Manifest
22 index e51208d8bbc..3f3288ae022 100644
23 --- a/net-analyzer/icinga2/Manifest
24 +++ b/net-analyzer/icinga2/Manifest
25 @@ -1,3 +1 @@
26 -DIST icinga2-2.6.2.tar.gz 2357220 SHA256 c2058c0e6c39860c52a57b8ce79224729f34b48bc96fb7b1ae2b742909e9b71b SHA512 733370fb120b79bbe3bdbf3d4b640083ff26d2a872c545f4efcd23be3462435f75e0b43b269b770296cb6de4a0529f2369fb766e06444d3fdb56f04db6a3dd03 WHIRLPOOL 0d28a429e5068a490a85ebced3b102780327519968f0cdc7eb3d939d91b6199ee285e0ca524d8596681b2c82832d8fc1909974f5f7e2ecbf0b7fe2ffc908327d
27 -DIST icinga2-2.6.3.tar.gz 2360602 SHA256 83d44871a70d1b368b1af717873ff9b1b185344d23fc79b83118e47a85da6d90 SHA512 c6512411689951611b19a5e80bf360b4cf5ddbf95dcb47cb393f90798e36c052c68b79a5a33a72cd6205ab58d4bb3ac44ec4cd82f9d1d17dc3c0e550723272b3 WHIRLPOOL 9e2c116be306cce35d780387cd2487a7a33b5819166308b83bb26d17cb856094f67d80ea110370b13e7fa19d84463b73da1a65fbf0de60663f2ad53e25c19108
28 DIST icinga2-2.7.0.tar.gz 2435398 SHA256 8f06d23e5d922ba7a74f92dbb9af792be063d06d3aea9011aba39370935c6980 SHA512 470dd4ffa4ef608a018ede5c25b41f16213bf18c679eed8aaeed155fe6adc74a70abcc2e8be42ca20bf60f9b4b620c971ebbc96d608de2a90e480d72b93111bb WHIRLPOOL c926086c296affaafc7d55471ea5c1414b2d2cb8545657215a53bb9744c3147c32f8398317ad670e0d12fb95c83b54f0712f061e5e93bab868c4f04d833c3b47
29
30 diff --git a/net-analyzer/icinga2/files/icinga2.confd b/net-analyzer/icinga2/files/icinga2.confd
31 deleted file mode 100644
32 index 5bfd8d72f04..00000000000
33 --- a/net-analyzer/icinga2/files/icinga2.confd
34 +++ /dev/null
35 @@ -1,4 +0,0 @@
36 -ICINGA2_ERROR_LOG=/var/log/icinga2/error.log
37 -ICINGA2_STARTUP_LOG=/var/log/icinga2/startup.log
38 -ICINGA2_LOG=/var/log/icinga2/icinga2.log
39 -ICINGA2_RUN_DIR=/run/icinga2
40
41 diff --git a/net-analyzer/icinga2/icinga2-2.6.2.ebuild b/net-analyzer/icinga2/icinga2-2.6.2.ebuild
42 deleted file mode 100644
43 index 36d3970dc4e..00000000000
44 --- a/net-analyzer/icinga2/icinga2-2.6.2.ebuild
45 +++ /dev/null
46 @@ -1,176 +0,0 @@
47 -# Copyright 1999-2017 Gentoo Foundation
48 -# Distributed under the terms of the GNU General Public License v2
49 -
50 -EAPI=5
51 -if [[ ${PV} != 9999 ]]; then
52 - inherit cmake-utils depend.apache eutils systemd toolchain-funcs user wxwidgets
53 - SRC_URI="https://github.com/Icinga/icinga2/archive/v${PV}.tar.gz -> ${P}.tar.gz"
54 - KEYWORDS="amd64 ~arm ~arm64 x86"
55 -else
56 - inherit cmake-utils depend.apache eutils git-2 systemd toolchain-funcs user wxwidgets
57 - EGIT_REPO_URI="https://github.com/Icinga/icinga2.git"
58 - EGIT_BRANCH="master"
59 - KEYWORDS=""
60 -fi
61 -
62 -DESCRIPTION="Distributed, general purpose, network monitoring engine"
63 -HOMEPAGE="http://icinga.org/icinga2"
64 -
65 -LICENSE="GPL-2"
66 -SLOT="0"
67 -IUSE="+mysql postgres classicui console libressl lto mail minimal nano-syntax +plugins studio +vim-syntax"
68 -WX_GTK_VER="3.0"
69 -
70 -CDEPEND="
71 - !libressl? ( dev-libs/openssl:0= )
72 - libressl? ( dev-libs/libressl:0= )
73 - >=dev-libs/boost-1.58-r1
74 - console? ( dev-libs/libedit )
75 - mysql? ( virtual/mysql )
76 - postgres? ( dev-db/postgresql:= )"
77 -
78 -DEPEND="
79 - ${CDEPEND}
80 - sys-devel/bison
81 - >=sys-devel/flex-2.5.35"
82 -
83 -RDEPEND="
84 - ${CDEPEND}
85 - plugins? ( || (
86 - net-analyzer/monitoring-plugins
87 - net-analyzer/nagios-plugins
88 - ) )
89 - mail? ( virtual/mailx )
90 - classicui? ( net-analyzer/icinga[web] )
91 - studio? ( x11-libs/wxGTK:3.0 )"
92 -
93 -REQUIRED_USE="!minimal? ( || ( mysql postgres ) )"
94 -
95 -want_apache2
96 -
97 -pkg_setup() {
98 - depend.apache_pkg_setup
99 - if use studio ; then
100 - setup-wxwidgets
101 - fi
102 - enewgroup icinga
103 - enewgroup icingacmd
104 - enewgroup nagios # for plugins
105 - enewuser icinga -1 -1 /var/lib/icinga2 "icinga,icingacmd,nagios"
106 -}
107 -
108 -src_configure() {
109 - sed -i 's/FLAGS\}\ \-g/FLAGS\}\ \-lpthread\ /g' CMakeLists.txt || die
110 - local mycmakeargs=(
111 - -DICINGA2_UNITY_BUILD=FALSE
112 - -DCMAKE_VERBOSE_MAKEFILE=ON
113 - -DCMAKE_BUILD_TYPE=None
114 - -DCMAKE_INSTALL_PREFIX=/usr
115 - -DCMAKE_INSTALL_SYSCONFDIR=/etc
116 - -DCMAKE_INSTALL_LOCALSTATEDIR=/var
117 - -DICINGA2_SYSCONFIGFILE=/etc/conf.d/icinga2
118 - -DICINGA2_USER=icinga
119 - -DICINGA2_GROUP=icingacmd
120 - -DICINGA2_COMMAND_USER=icinga
121 - -DICINGA2_COMMAND_GROUP=icingacmd
122 - -DINSTALL_SYSTEMD_SERVICE_AND_INITSCRIPT=yes
123 - -DLOGROTATE_HAS_SU=ON
124 - )
125 - # default to off if minimal, allow the flags to be set otherwise
126 - if use minimal; then
127 - mycmakeargs+=(
128 - -DICINGA2_WITH_MYSQL=OFF
129 - -DICINGA2_WITH_PGSQL=OFF
130 - )
131 - else
132 - mycmakeargs+=(
133 - -DICINGA2_WITH_PGSQL=$(usex postgres ON OFF)
134 - -DICINGA2_WITH_MYSQL=$(usex mysql ON OFF)
135 - )
136 - fi
137 - # LTO
138 - if use lto; then
139 - mycmakeargs+=(
140 - -DICINGA2_LTO_BUILD=ON
141 - )
142 - else
143 - mycmakeargs+=(
144 - -DICINGA2_LTO_BUILD=OFF
145 - )
146 - fi
147 - # STUDIO
148 - if use studio; then
149 - mycmakeargs+=(
150 - -DICINGA2_WITH_STUDIO=ON
151 - )
152 - else
153 - mycmakeargs+=(
154 - -DICINGA2_WITH_STUDIO=OFF
155 - )
156 - fi
157 -
158 - cmake-utils_src_configure
159 -}
160 -
161 -src_install() {
162 - BUILDDIR="${WORKDIR}"/icinga2-${PV}_build
163 - cd "${BUILDDIR}" || die
164 -
165 - emake DESTDIR="${D}" install
166 -
167 - einstalldocs
168 -
169 - newinitd "${FILESDIR}"/icinga2.initd icinga2
170 - newconfd "${FILESDIR}"/icinga2.confd icinga2
171 -
172 - if use mysql ; then
173 - docinto schema
174 - newdoc "${WORKDIR}"/icinga2-${PV}/lib/db_ido_mysql/schema/mysql.sql mysql.sql
175 - docinto schema/upgrade
176 - dodoc "${WORKDIR}"/icinga2-${PV}/lib/db_ido_mysql/schema/upgrade/*
177 - elif use postgres ; then
178 - docinto schema
179 - newdoc "${WORKDIR}"/icinga2-${PV}/lib/db_ido_pgsql/schema/pgsql.sql pgsql.sql
180 - docinto schema/upgrade
181 - dodoc "${WORKDIR}"/icinga2-${PV}/lib/db_ido_pgsql/schema/upgrade/*
182 - fi
183 -
184 - keepdir /etc/icinga2
185 - keepdir /var/lib/icinga2/api/zones
186 - keepdir /var/lib/icinga2/api/repository
187 - keepdir /var/lib/icinga2/api/log
188 - keepdir /var/spool/icinga2/perfdata
189 -
190 - rm -r "${D}/var/run" || die "failed to remove /var/run"
191 - rm -r "${D}/var/cache" || die "failed to remove /var/cache"
192 -
193 - fowners icinga:icinga /etc/icinga2
194 - fowners icinga:icinga /var/lib/icinga2
195 - fowners icinga:icinga /var/spool/icinga2
196 - fowners -R icinga:icingacmd /var/lib/icinga2/api
197 - fowners icinga:icinga /var/spool/icinga2/perfdata
198 - fowners icinga:icingacmd /var/log/icinga2
199 -
200 - fperms ug+rwX,o-rwx /etc/icinga2
201 - fperms ug+rwX,o-rwx /var/lib/icinga2
202 - fperms ug+rwX,o-rwx /var/spool/icinga2
203 - fperms ug+rwX,o-rwx /var/log/icinga2
204 -
205 - if use vim-syntax; then
206 - insinto /usr/share/vim/vimfiles
207 - doins -r "${WORKDIR}"/${P}/tools/syntax/vim/ftdetect
208 - doins -r "${WORKDIR}"/${P}/tools/syntax/vim/syntax
209 - fi
210 -
211 - if use nano-syntax; then
212 - insinto /usr/share/nano
213 - doins "${WORKDIR}"/${P}/tools/syntax/nano/icinga2.nanorc
214 - fi
215 -}
216 -
217 -pkg_postinst() {
218 - if [[ ${PV} != 9999 && -n ${REPLACING_VERSIONS} && ${REPLACING_VERSIONS} != ${PV} ]]; then
219 - elog "DB IDO schema upgrade may be required required.
220 - http://docs.icinga.org/icinga2/snapshot/doc/module/icinga2/chapter/upgrading-icinga-2"
221 - fi
222 -}
223
224 diff --git a/net-analyzer/icinga2/icinga2-2.6.3-r1.ebuild b/net-analyzer/icinga2/icinga2-2.6.3-r1.ebuild
225 deleted file mode 100644
226 index 5f0227d0451..00000000000
227 --- a/net-analyzer/icinga2/icinga2-2.6.3-r1.ebuild
228 +++ /dev/null
229 @@ -1,175 +0,0 @@
230 -# Copyright 1999-2017 Gentoo Foundation
231 -# Distributed under the terms of the GNU General Public License v2
232 -
233 -EAPI=5
234 -if [[ ${PV} != 9999 ]]; then
235 - inherit cmake-utils depend.apache eutils systemd toolchain-funcs user wxwidgets
236 - SRC_URI="https://github.com/Icinga/icinga2/archive/v${PV}.tar.gz -> ${P}.tar.gz"
237 - KEYWORDS="amd64 ~arm ~arm64 ~ppc ~ppc64 x86"
238 -else
239 - inherit cmake-utils depend.apache eutils git-2 systemd toolchain-funcs user wxwidgets
240 - EGIT_REPO_URI="https://github.com/Icinga/icinga2.git"
241 - EGIT_BRANCH="master"
242 - KEYWORDS="~ppc ~ppc64"
243 -fi
244 -
245 -DESCRIPTION="Distributed, general purpose, network monitoring engine"
246 -HOMEPAGE="http://icinga.org/icinga2"
247 -
248 -LICENSE="GPL-2"
249 -SLOT="0"
250 -IUSE="+mysql postgres classicui console libressl lto mail minimal nano-syntax +plugins studio +vim-syntax"
251 -WX_GTK_VER="3.0"
252 -
253 -CDEPEND="
254 - !libressl? ( dev-libs/openssl:0= )
255 - libressl? ( dev-libs/libressl:0= )
256 - >=dev-libs/boost-1.58-r1
257 - console? ( dev-libs/libedit )
258 - mysql? ( virtual/mysql )
259 - postgres? ( dev-db/postgresql:= )"
260 -
261 -DEPEND="
262 - ${CDEPEND}
263 - sys-devel/bison
264 - >=sys-devel/flex-2.5.35"
265 -
266 -RDEPEND="
267 - ${CDEPEND}
268 - plugins? ( || (
269 - net-analyzer/monitoring-plugins
270 - net-analyzer/nagios-plugins
271 - ) )
272 - mail? ( virtual/mailx )
273 - classicui? ( net-analyzer/icinga[web] )
274 - studio? ( x11-libs/wxGTK:3.0 )"
275 -
276 -REQUIRED_USE="!minimal? ( || ( mysql postgres ) )"
277 -
278 -want_apache2
279 -
280 -pkg_setup() {
281 - depend.apache_pkg_setup
282 - if use studio ; then
283 - setup-wxwidgets
284 - fi
285 - enewgroup icinga
286 - enewgroup icingacmd
287 - enewgroup nagios # for plugins
288 - enewuser icinga -1 -1 /var/lib/icinga2 "icinga,icingacmd,nagios"
289 -}
290 -
291 -src_configure() {
292 - sed -i 's/FLAGS\}\ \-g/FLAGS\}\ \-lpthread\ /g' CMakeLists.txt || die
293 - local mycmakeargs=(
294 - -DICINGA2_UNITY_BUILD=FALSE
295 - -DCMAKE_VERBOSE_MAKEFILE=ON
296 - -DCMAKE_BUILD_TYPE=None
297 - -DCMAKE_INSTALL_PREFIX=/usr
298 - -DCMAKE_INSTALL_SYSCONFDIR=/etc
299 - -DCMAKE_INSTALL_LOCALSTATEDIR=/var
300 - -DICINGA2_SYSCONFIGFILE=/etc/conf.d/icinga2
301 - -DICINGA2_USER=icinga
302 - -DICINGA2_GROUP=icingacmd
303 - -DICINGA2_COMMAND_USER=icinga
304 - -DICINGA2_COMMAND_GROUP=icingacmd
305 - -DINSTALL_SYSTEMD_SERVICE_AND_INITSCRIPT=yes
306 - -DLOGROTATE_HAS_SU=ON
307 - )
308 - # default to off if minimal, allow the flags to be set otherwise
309 - if use minimal; then
310 - mycmakeargs+=(
311 - -DICINGA2_WITH_MYSQL=OFF
312 - -DICINGA2_WITH_PGSQL=OFF
313 - )
314 - else
315 - mycmakeargs+=(
316 - -DICINGA2_WITH_PGSQL=$(usex postgres ON OFF)
317 - -DICINGA2_WITH_MYSQL=$(usex mysql ON OFF)
318 - )
319 - fi
320 - # LTO
321 - if use lto; then
322 - mycmakeargs+=(
323 - -DICINGA2_LTO_BUILD=ON
324 - )
325 - else
326 - mycmakeargs+=(
327 - -DICINGA2_LTO_BUILD=OFF
328 - )
329 - fi
330 - # STUDIO
331 - if use studio; then
332 - mycmakeargs+=(
333 - -DICINGA2_WITH_STUDIO=ON
334 - )
335 - else
336 - mycmakeargs+=(
337 - -DICINGA2_WITH_STUDIO=OFF
338 - )
339 - fi
340 -
341 - cmake-utils_src_configure
342 -}
343 -
344 -src_install() {
345 - BUILDDIR="${WORKDIR}"/icinga2-${PV}_build
346 - cd "${BUILDDIR}" || die
347 -
348 - emake DESTDIR="${D}" install
349 -
350 - einstalldocs
351 -
352 - newinitd "${FILESDIR}"/icinga2.initd icinga2
353 -
354 - if use mysql ; then
355 - docinto schema
356 - newdoc "${WORKDIR}"/icinga2-${PV}/lib/db_ido_mysql/schema/mysql.sql mysql.sql
357 - docinto schema/upgrade
358 - dodoc "${WORKDIR}"/icinga2-${PV}/lib/db_ido_mysql/schema/upgrade/*
359 - elif use postgres ; then
360 - docinto schema
361 - newdoc "${WORKDIR}"/icinga2-${PV}/lib/db_ido_pgsql/schema/pgsql.sql pgsql.sql
362 - docinto schema/upgrade
363 - dodoc "${WORKDIR}"/icinga2-${PV}/lib/db_ido_pgsql/schema/upgrade/*
364 - fi
365 -
366 - keepdir /etc/icinga2
367 - keepdir /var/lib/icinga2/api/zones
368 - keepdir /var/lib/icinga2/api/repository
369 - keepdir /var/lib/icinga2/api/log
370 - keepdir /var/spool/icinga2/perfdata
371 -
372 - rm -r "${D}/var/run" || die "failed to remove /var/run"
373 - rm -r "${D}/var/cache" || die "failed to remove /var/cache"
374 -
375 - fowners icinga:icinga /etc/icinga2
376 - fowners icinga:icinga /var/lib/icinga2
377 - fowners icinga:icinga /var/spool/icinga2
378 - fowners -R icinga:icingacmd /var/lib/icinga2/api
379 - fowners icinga:icinga /var/spool/icinga2/perfdata
380 - fowners icinga:icingacmd /var/log/icinga2
381 -
382 - fperms ug+rwX,o-rwx /etc/icinga2
383 - fperms ug+rwX,o-rwx /var/lib/icinga2
384 - fperms ug+rwX,o-rwx /var/spool/icinga2
385 - fperms ug+rwX,o-rwx /var/log/icinga2
386 -
387 - if use vim-syntax; then
388 - insinto /usr/share/vim/vimfiles
389 - doins -r "${WORKDIR}"/${P}/tools/syntax/vim/ftdetect
390 - doins -r "${WORKDIR}"/${P}/tools/syntax/vim/syntax
391 - fi
392 -
393 - if use nano-syntax; then
394 - insinto /usr/share/nano
395 - doins "${WORKDIR}"/${P}/tools/syntax/nano/icinga2.nanorc
396 - fi
397 -}
398 -
399 -pkg_postinst() {
400 - if [[ ${PV} != 9999 && -n ${REPLACING_VERSIONS} && ${REPLACING_VERSIONS} != ${PV} ]]; then
401 - elog "DB IDO schema upgrade may be required required.
402 - http://docs.icinga.org/icinga2/snapshot/doc/module/icinga2/chapter/upgrading-icinga-2"
403 - fi
404 -}
405
406 diff --git a/net-analyzer/icinga2/icinga2-2.7.0.ebuild b/net-analyzer/icinga2/icinga2-2.7.0-r1.ebuild
407 similarity index 98%
408 rename from net-analyzer/icinga2/icinga2-2.7.0.ebuild
409 rename to net-analyzer/icinga2/icinga2-2.7.0-r1.ebuild
410 index 35df65d8c19..8e9f5f4f36c 100644
411 --- a/net-analyzer/icinga2/icinga2-2.7.0.ebuild
412 +++ b/net-analyzer/icinga2/icinga2-2.7.0-r1.ebuild
413 @@ -144,7 +144,8 @@ src_install() {
414 rm -r "${D}/var/run" || die "failed to remove /var/run"
415 rm -r "${D}/var/cache" || die "failed to remove /var/cache"
416
417 - fowners icinga:icinga /etc/icinga2
418 + fowners root:icinga /etc/icinga2
419 + fperms 0750 /etc/icinga2
420 fowners icinga:icinga /var/lib/icinga2
421 fowners icinga:icinga /var/spool/icinga2
422 fowners -R icinga:icingacmd /var/lib/icinga2/api
423
424 diff --git a/net-analyzer/icinga2/icinga2-9999.ebuild b/net-analyzer/icinga2/icinga2-9999.ebuild
425 index af171a68b51..644d451cfc6 100644
426 --- a/net-analyzer/icinga2/icinga2-9999.ebuild
427 +++ b/net-analyzer/icinga2/icinga2-9999.ebuild
428 @@ -1,4 +1,4 @@
429 -# Copyright 1999-2016 Gentoo Foundation
430 +# Copyright 1999-2017 Gentoo Foundation
431 # Distributed under the terms of the GNU General Public License v2
432
433 EAPI=5
434 @@ -24,7 +24,7 @@ WX_GTK_VER="3.0"
435 CDEPEND="
436 !libressl? ( dev-libs/openssl:0= )
437 libressl? ( dev-libs/libressl:0= )
438 - >=dev-libs/boost-1.41
439 + >=dev-libs/boost-1.58-r1
440 console? ( dev-libs/libedit )
441 mysql? ( virtual/mysql )
442 postgres? ( dev-db/postgresql:= )"
443 @@ -69,6 +69,7 @@ src_configure() {
444 -DCMAKE_INSTALL_SYSCONFDIR=/etc
445 -DCMAKE_INSTALL_LOCALSTATEDIR=/var
446 -DICINGA2_SYSCONFIGFILE=/etc/conf.d/icinga2
447 + -DICINGA2_PLUGINDIR="/usr/$(get_libdir)/nagios/plugins"
448 -DICINGA2_USER=icinga
449 -DICINGA2_GROUP=icingacmd
450 -DICINGA2_COMMAND_USER=icinga
451 @@ -121,7 +122,6 @@ src_install() {
452 einstalldocs
453
454 newinitd "${FILESDIR}"/icinga2.initd icinga2
455 - newconfd "${FILESDIR}"/icinga2.confd icinga2
456
457 if use mysql ; then
458 docinto schema
459 @@ -144,7 +144,8 @@ src_install() {
460 rm -r "${D}/var/run" || die "failed to remove /var/run"
461 rm -r "${D}/var/cache" || die "failed to remove /var/cache"
462
463 - fowners icinga:icinga /etc/icinga2
464 + fowners root:icinga /etc/icinga2
465 + fperms 0750 /etc/icinga2
466 fowners icinga:icinga /var/lib/icinga2
467 fowners icinga:icinga /var/spool/icinga2
468 fowners -R icinga:icingacmd /var/lib/icinga2/api