summaryrefslogtreecommitdiff
path: root/net-analyzer/nagios-core
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2018-06-23 07:00:28 +0100
committerV3n3RiX <venerix@redcorelinux.org>2018-06-23 07:00:28 +0100
commite23cdda4dbb0c83b9e682ab5e916085a35203da5 (patch)
tree5a4ac448a3b288b731c24d947e0ce52df3cab07b /net-analyzer/nagios-core
parent8187a741807f3e9a9e26304973cf18087dcf2560 (diff)
gentoo resync : 23.06.2018
Diffstat (limited to 'net-analyzer/nagios-core')
-rw-r--r--net-analyzer/nagios-core/Manifest11
-rw-r--r--net-analyzer/nagios-core/files/99_nagios3.conf15
-rw-r--r--net-analyzer/nagios-core/files/conf.d9
-rw-r--r--net-analyzer/nagios-core/files/lighttpd_nagios3-r1.conf24
-rw-r--r--net-analyzer/nagios-core/files/nagios-core-3.5.1-process_cgivars.patch175
-rw-r--r--net-analyzer/nagios-core/files/nagios-core-4.3.1-fix-upstream-issue-337.patch21
-rw-r--r--net-analyzer/nagios-core/files/nagios352
-rw-r--r--net-analyzer/nagios-core/files/nagios4-r145
-rw-r--r--net-analyzer/nagios-core/nagios-core-3.5.1.ebuild216
-rw-r--r--net-analyzer/nagios-core/nagios-core-4.3.1-r1.ebuild249
10 files changed, 0 insertions, 817 deletions
diff --git a/net-analyzer/nagios-core/Manifest b/net-analyzer/nagios-core/Manifest
index 31a670554568..eab93682e4c5 100644
--- a/net-analyzer/nagios-core/Manifest
+++ b/net-analyzer/nagios-core/Manifest
@@ -1,19 +1,8 @@
-AUX 99_nagios3.conf 377 BLAKE2B e26a41d3a52f808615a920caae73d5d1314a296434572c57a93d7a45edff37ee152cbcf1131e0a9a67a93f17c2630b0b7c4a2fff831359549ab096f26059f3fc SHA512 53ceae12cf19d2dda1298e9faaa3ddab9b4d95163df87ccfaa0a58e54d60cf8e005ea32ed827348f1b43aee53258896972b72727145f9a20f6a4e1ce1e56ea3f
AUX 99_nagios4.conf 368 BLAKE2B 147f4b73bd2f7d71dabb56f646399b939d3a87c288efed9b135e9401120e81c27e2a05f96982b62e601d1dd9b21be494e866103467a363336234b8b15095daf1 SHA512 f0b239f23d74afa89483806f27fb9259054e46bc5742de8a414c9a9a9852a4fbdc14db45aeb148a15288196c8f7d51bdd485b005e20d012892e9e7321b50e161
-AUX conf.d 298 BLAKE2B 755ef6d5f69b7920cbe4e71643c64526743219f7967fefbc2046e51d1833186cf17c7b5ec4d8f8ad911e2e7c9470b41defa95c34a791a1b75c0aa932ffb4e897 SHA512 81d1bbbff88b56f2bbad7e38701977eeaeaa56c6511e98fa2675960040dbad45b3243f22742b68c1a18e7df1b2fadcc6593b61e92eac42f7362ae16c33989418
-AUX lighttpd_nagios3-r1.conf 482 BLAKE2B 3b3a70304174c0380fefc276f43462058a3968d06d8907f94248fb7eb0b0942830a405f8dfb81f7d17c006800c9ceeeaaca64c7ef235a1eb62ee835ed1897794 SHA512 8a6811432034f97aa136b4d2c4cf1382c8cb13388eec67a2112034aa1331e08fa73e5822ef78634cf25581b068280736a9efd15848fecaa7215364104778194b
AUX lighttpd_nagios4.conf 325 BLAKE2B f89b9d5aed8305d54f76adf29c65ba20bee74b6c82d149c8b0a786dddacc58c62337072691136c486d4050d1e3bce82420398d5f525ebc0bb36eefdf3a6a2e7f SHA512 a2f854713512ee8ee5c451235beb6ffccf2e04617a98619c6de807a5abca0a424e0581c34b4d255dcbc108e677e18bed25dd33e3d38df8fe10d7d8d4fab015c9
-AUX nagios-core-3.5.1-process_cgivars.patch 5282 BLAKE2B 09f1e16689dcdebe53a71a76fd8eed50b2b57c5dc4f7bfc1884148cfbb4e1d24972b31745e0a19b04a74230532382245a00f7d81e37dd756a99cc7ac78a7c2e8 SHA512 302d45f59f9165771ae766d1a3e085995056c515fc1ae8a61341b44afe7b903f85a2ac5a7dd68d3b9f1944a6d102d63d1fd9aded5d2c916e70affec5d43b766a
-AUX nagios-core-4.3.1-fix-upstream-issue-337.patch 810 BLAKE2B 65d75d238c00fbafb260fac8d98264b9c5975eeee3d13646b7b19d7930c6afd5b6d12497c2b1f96a5774f5e7a1f57e3363a899dd4752c8558ff7da84066c52e0 SHA512 67c4c8efe0df27e83cf8108bd43fc6d4cc9b75b531761cd9e17794965d9fed27593897f8ab2b8569e3980abd9b52b26c1edacfed90fae1134b3bf3526a39228f
-AUX nagios3 1208 BLAKE2B fa158d417bb48e6f85a88f7498c1b354df39a23d072eb66e8fd170249e2841eb87edfff3f795dbbcf29041ee3784266b3547b2b9656ad169d2f716d57a8e611e SHA512 92ed5cc52440c622af1e9346177dfd22167d2ebffbe00a24c2661d29de7dbf153f9a27143f29f7c42fb1a727b2bbb3dea0806a6adf1e1def7e010c3d7a9a5e75
-AUX nagios4-r1 1077 BLAKE2B 30ac1de0872caae1540c1c976c24d8964de3a3c2f9e5cba2314d95420494856b644d6c9bcb1ff76e63b8c76d34156afa740af9cfce8708fc53e3ba08906ba957 SHA512 91955f947b7bc70ba330bc541ea8770fafd7f4f77fbc1e08c2838029c7fbac6610adafc14afff01261d3d294cd8649456b78d2a940a87baa47808dace9ca3cc6
-DIST nagios-3.5.1.tar.gz 1763584 BLAKE2B e0391c906e11aec18a07bc8627ed47892f69415f5f777ab6ecf2f08f7486b1b71efc3687547665b5cf62eb9f477084d7fc58344e7e5754d1bea32be3a916779e SHA512 48e2ecb91002b08203937b12a438c87c62cd3c5c401a0ed9e861cd6d79074c7017ed373e9379f013d87dea1fd7cb8e3d85112d55c87ac91aed96b256868c112d
-DIST nagios-4.3.1.tar.gz 11095797 BLAKE2B 46c7ca25b7277dc1b114b08fba6eece6d841ea8bd2a499428f1b8637ae547a4990a66b4ab7feb7137d9bc4249a9fb73238f37145da76d98be7591abe0d87b4eb SHA512 d5f1919e2b32b0b2f4c5766367f0992fcf9b1f6766f4d3386e15e318cc1f57cdae6bc07f09464fd8212bef1713948fcb25d233eab588438036f996b6c479c97e
DIST nagios-4.3.3.tar.gz 11101531 BLAKE2B 537d49ecf28b457fbc1e24eaaa9c5d9e8c4db59ed69c91a573c0cacb6cfb6fd2d52c31e87c0cef34b81a69247bb5b9513983d95e7eae3ea7f861742da485d2d4 SHA512 588292a95342cb2d95d7b58f70442b82b99a23dd9fdc1390e9ae0743626a047e5127d77b1d7e6a1d8edd6f34a425e581bcd42459b673a0ddea14125bde4b7d9e
DIST nagios-4.3.4.tar.gz 11101966 BLAKE2B 6cb8182f40a4f83875c94df040bb1c62ce078d4130e10fa8595ea0b14cf715fc2a237ffb34199da9c1528e4789f3ce8deae3d993b5b795ad712d48b1e5fdb820 SHA512 f4e92aa98151739442a225a245871d93b5560d89510bdacb1a615959b9687f7a92675f10fcba71078b104ca8f237b0155a9261d67ec66f80aec7f033b4b3e316
DIST nagios-core-gentoo-icons-20141125.tar 40960 BLAKE2B 31c1953e1160c7c7b89606b72b1a80407e4c1b7a7938b40bd1c577cd0c309dd88ca6b775d692a9b846dbf67736537fa9c91e56aa15fdd447769608ca525bff09 SHA512 bf109879cddd6136b76baba55d0b60b2596e37431dcf5ce0905d34a9fa292ebf7e4bde82d9a084362c486e8fac344c76d88f9298b1b85541ed70ffd608493766
-EBUILD nagios-core-3.5.1.ebuild 6155 BLAKE2B fd6eb2d5bda94625f5f5b265d8e99e5e1cd802e94deaa04b3c1d4acba13d37c49dff07780aaa47ecf50073643b32dabcceb8d86b2eb71c1a1577c9e0304b7f79 SHA512 54259b2f4ba0251c92441a3fb7bd686a66c31d0abe6368c04d7d1c764089f004e2911534ccf2b005d687815f6d60307b9e97209c044db7c5c7adcea164a9f28c
-EBUILD nagios-core-4.3.1-r1.ebuild 7580 BLAKE2B 0ae2c990bdbbc08df278b40027763868bc88497d7462b57560558ec2e3bc04df9ece62358390b0ee510d7414f9bc20051a5124bee03804d1e3bbf65f279b8d1d SHA512 c9ac60fa3010434f409a5f889046546c8d6132652eb2a6bb9f89ada7d01447b79f130c1e529d88256636bc7ee45307489b2684532d4c0156a021d3dcae3b1d3b
EBUILD nagios-core-4.3.3.ebuild 7467 BLAKE2B f337eabcfbd918295f437ec735917fda59e0695ee2a6800eea4a15d9f49b1fb63ee135498c8556c0c1a545f7ff0f0141abfb2080a605f19928a5036cac1fdfac SHA512 250b84f3b417756fbb9034af2a909c94c7c2ec7e1539f66590f84b4ff3735314d403b8b6496880c9e0aee2f4052dd7d7829779d1fc4ae78e01f53449abe206ab
EBUILD nagios-core-4.3.4.ebuild 6644 BLAKE2B 74ea9541876cb35aafbae6721c096e572200b8aa0975b9867ea535a6878d4786c4d552c1f08263a5e5ef2c534b562223726dc248499a793f3a86acf29deb58e5 SHA512 7e51585249db59f040033e22ec2043dbae6cc6e96117f87ded0a4ce4049b4dcf6bdc10d597233f3d5fec95ec60842bdb98f3bf354665d9f4c1ef4ab27cd038e2
MISC metadata.xml 1466 BLAKE2B 655e382c72b7fcf8f4283055a503e2ad79dbfc695f730980543e6a7381f5aa093ab279341cd2df19a1d5e5053b2c686ecf6884c541a7b984dce60fc1ae4d4599 SHA512 51f819fc2cbe3b87ee96b048fd0e622f78673a29d5b42b2b8f1d963f6f71ead679b057863f5f1a56e997c1e19ff26edf52697c02f79ba89ed6a5480d0ae2296b
diff --git a/net-analyzer/nagios-core/files/99_nagios3.conf b/net-analyzer/nagios-core/files/99_nagios3.conf
deleted file mode 100644
index 074f9ce5e4a9..000000000000
--- a/net-analyzer/nagios-core/files/99_nagios3.conf
+++ /dev/null
@@ -1,15 +0,0 @@
-<IfDefine NAGIOS>
- ScriptAlias /nagios/cgi-bin/ /usr/lib/nagios/cgi-bin/
- <Directory "/usr/lib/nagios/cgi-bin/">
- AllowOverride AuthConfig
- Options ExecCGI
- Order allow,deny
- Allow from all
- </Directory>
- Alias /nagios /usr/share/nagios/htdocs
- <Directory "/usr/share/nagios/htdocs">
- AllowOverride AuthConfig
- Order allow,deny
- Allow from all
- </Directory>
-</IfDefine>
diff --git a/net-analyzer/nagios-core/files/conf.d b/net-analyzer/nagios-core/files/conf.d
deleted file mode 100644
index 68c7370c887c..000000000000
--- a/net-analyzer/nagios-core/files/conf.d
+++ /dev/null
@@ -1,9 +0,0 @@
-# Copyright 1999-2004 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-# Distributed monitoring users will want to configure here the ip/hostname of the central server.
-# It will be used by submit_check_result_via_nsca.
-NAGIOS_NSCA_HOST="localhost"
-
-
-
diff --git a/net-analyzer/nagios-core/files/lighttpd_nagios3-r1.conf b/net-analyzer/nagios-core/files/lighttpd_nagios3-r1.conf
deleted file mode 100644
index 6e2577029aca..000000000000
--- a/net-analyzer/nagios-core/files/lighttpd_nagios3-r1.conf
+++ /dev/null
@@ -1,24 +0,0 @@
-server.modules += ("mod_cgi")
-server.modules += ("mod_auth")
-server.modules += ("mod_alias")
-
-auth.require += ( "/nagios" =>
- (
- "method" => "digest",
- "realm" => "nagios",
- "require" => "valid-user"
- )
-)
-
-$HTTP["url"] =~ "^/nagios/cgi-bin/" {
- dir-listing.activate = "disable"
- cgi.assign = (
- ".pl" => "/usr/bin/perl",
- ".cgi" => ""
- )
-}
-
-alias.url += (
- "/nagios/cgi-bin" => "/usr/lib/nagios/cgi-bin",
- "/nagios" => "/usr/share/nagios/htdocs"
-)
diff --git a/net-analyzer/nagios-core/files/nagios-core-3.5.1-process_cgivars.patch b/net-analyzer/nagios-core/files/nagios-core-3.5.1-process_cgivars.patch
deleted file mode 100644
index 9d9536747794..000000000000
--- a/net-analyzer/nagios-core/files/nagios-core-3.5.1-process_cgivars.patch
+++ /dev/null
@@ -1,175 +0,0 @@
-commit d97e03f32741a7d851826b03ed73ff4c9612a866
-Author: Eric Stanley <estanley@nagios.com>
-Date: Fri Dec 20 13:14:30 2013 -0600
-
- CGIs: Fixed minor vulnerability where a custom query could crash the CGI.
-
- Most CGIs previously incremented the input variable counter twice when
- it encountered a long key value. This could cause the CGI to read past
- the end of the list of CGI variables. This commit removes the second
- increment, removing the possibility of reading past the end of the list
- of CGI variables.
-
-diff --git a/cgi/avail.c b/cgi/avail.c
-index 76afd86..64eaadc 100644
---- a/cgi/avail.c
-+++ b/cgi/avail.c
-@@ -1096,7 +1096,6 @@ int process_cgivars(void) {
-
- /* do some basic length checking on the variable identifier to prevent buffer overflows */
- if(strlen(variables[x]) >= MAX_INPUT_BUFFER - 1) {
-- x++;
- continue;
- }
-
-diff --git a/cgi/cmd.c b/cgi/cmd.c
-index fa6cf5a..50504eb 100644
---- a/cgi/cmd.c
-+++ b/cgi/cmd.c
-@@ -311,7 +311,6 @@ int process_cgivars(void) {
-
- /* do some basic length checking on the variable identifier to prevent buffer overflows */
- if(strlen(variables[x]) >= MAX_INPUT_BUFFER - 1) {
-- x++;
- continue;
- }
-
-diff --git a/cgi/config.c b/cgi/config.c
-index f061b0f..3360e70 100644
---- a/cgi/config.c
-+++ b/cgi/config.c
-@@ -344,7 +344,6 @@ int process_cgivars(void) {
-
- /* do some basic length checking on the variable identifier to prevent buffer overflows */
- if(strlen(variables[x]) >= MAX_INPUT_BUFFER - 1) {
-- x++;
- continue;
- }
-
-diff --git a/cgi/extinfo.c b/cgi/extinfo.c
-index 62a1b18..5113df4 100644
---- a/cgi/extinfo.c
-+++ b/cgi/extinfo.c
-@@ -591,7 +591,6 @@ int process_cgivars(void) {
-
- /* do some basic length checking on the variable identifier to prevent buffer overflows */
- if(strlen(variables[x]) >= MAX_INPUT_BUFFER - 1) {
-- x++;
- continue;
- }
-
-diff --git a/cgi/histogram.c b/cgi/histogram.c
-index 4616541..f6934d0 100644
---- a/cgi/histogram.c
-+++ b/cgi/histogram.c
-@@ -1060,7 +1060,6 @@ int process_cgivars(void) {
-
- /* do some basic length checking on the variable identifier to prevent buffer overflows */
- if(strlen(variables[x]) >= MAX_INPUT_BUFFER - 1) {
-- x++;
- continue;
- }
-
-diff --git a/cgi/notifications.c b/cgi/notifications.c
-index 8ba11c1..461ae84 100644
---- a/cgi/notifications.c
-+++ b/cgi/notifications.c
-@@ -327,7 +327,6 @@ int process_cgivars(void) {
-
- /* do some basic length checking on the variable identifier to prevent buffer overflows */
- if(strlen(variables[x]) >= MAX_INPUT_BUFFER - 1) {
-- x++;
- continue;
- }
-
-diff --git a/cgi/outages.c b/cgi/outages.c
-index 426ede6..cb58dee 100644
---- a/cgi/outages.c
-+++ b/cgi/outages.c
-@@ -225,7 +225,6 @@ int process_cgivars(void) {
-
- /* do some basic length checking on the variable identifier to prevent buffer overflows */
- if(strlen(variables[x]) >= MAX_INPUT_BUFFER - 1) {
-- x++;
- continue;
- }
-
-diff --git a/cgi/status.c b/cgi/status.c
-index 3253340..4ec1c92 100644
---- a/cgi/status.c
-+++ b/cgi/status.c
-@@ -567,7 +567,6 @@ int process_cgivars(void) {
-
- /* do some basic length checking on the variable identifier to prevent buffer overflows */
- if(strlen(variables[x]) >= MAX_INPUT_BUFFER - 1) {
-- x++;
- continue;
- }
-
-diff --git a/cgi/statusmap.c b/cgi/statusmap.c
-index ea48368..2580ae5 100644
---- a/cgi/statusmap.c
-+++ b/cgi/statusmap.c
-@@ -400,7 +400,6 @@ int process_cgivars(void) {
-
- /* do some basic length checking on the variable identifier to prevent buffer overflows */
- if(strlen(variables[x]) >= MAX_INPUT_BUFFER - 1) {
-- x++;
- continue;
- }
-
-diff --git a/cgi/statuswml.c b/cgi/statuswml.c
-index bd8cea2..d25abef 100644
---- a/cgi/statuswml.c
-+++ b/cgi/statuswml.c
-@@ -226,8 +226,13 @@ int process_cgivars(void) {
-
- for(x = 0; variables[x] != NULL; x++) {
-
-+ /* do some basic length checking on the variable identifier to prevent buffer overflows */
-+ if(strlen(variables[x]) >= MAX_INPUT_BUFFER - 1) {
-+ continue;
-+ }
-+
- /* we found the hostgroup argument */
-- if(!strcmp(variables[x], "hostgroup")) {
-+ else if(!strcmp(variables[x], "hostgroup")) {
- display_type = DISPLAY_HOSTGROUP;
- x++;
- if(variables[x] == NULL) {
-diff --git a/cgi/summary.c b/cgi/summary.c
-index 126ce5e..749a02c 100644
---- a/cgi/summary.c
-+++ b/cgi/summary.c
-@@ -725,7 +725,6 @@ int process_cgivars(void) {
-
- /* do some basic length checking on the variable identifier to prevent buffer overflows */
- if(strlen(variables[x]) >= MAX_INPUT_BUFFER - 1) {
-- x++;
- continue;
- }
-
-diff --git a/cgi/trends.c b/cgi/trends.c
-index b35c18e..895db01 100644
---- a/cgi/trends.c
-+++ b/cgi/trends.c
-@@ -1263,7 +1263,6 @@ int process_cgivars(void) {
-
- /* do some basic length checking on the variable identifier to prevent buffer overflows */
- if(strlen(variables[x]) >= MAX_INPUT_BUFFER - 1) {
-- x++;
- continue;
- }
-
-diff --git a/contrib/daemonchk.c b/contrib/daemonchk.c
-index 78716e5..9bb6c4b 100644
---- a/contrib/daemonchk.c
-+++ b/contrib/daemonchk.c
-@@ -174,7 +174,6 @@ static int process_cgivars(void) {
-
- /* do some basic length checking on the variable identifier to prevent buffer overflows */
- if(strlen(variables[x]) >= MAX_INPUT_BUFFER - 1) {
-- x++;
- continue;
- }
- }
diff --git a/net-analyzer/nagios-core/files/nagios-core-4.3.1-fix-upstream-issue-337.patch b/net-analyzer/nagios-core/files/nagios-core-4.3.1-fix-upstream-issue-337.patch
deleted file mode 100644
index d5344a6442cb..000000000000
--- a/net-analyzer/nagios-core/files/nagios-core-4.3.1-fix-upstream-issue-337.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-From e03e4fd470fbc8d4304d860d7b3b523c5d78373d Mon Sep 17 00:00:00 2001
-From: "John C. Frickson" <jfrickson@nagios.com>
-Date: Thu, 2 Mar 2017 10:24:24 -0600
-Subject: [PATCH] every 15sec /var/log/messages is flooded with "nagios:
- set_environment_var"
-
-Fix for https://github.com/NagiosEnterprises/nagioscore/issues/337
-diff --git a/base/utils.c b/base/utils.c
-index 733fdef..19e20c7 100644
---- a/base/utils.c
-+++ b/base/utils.c
-@@ -872,9 +872,6 @@ int set_environment_var(char *name, char *value, int set) {
-
- /* set the environment variable */
- if(set == TRUE) {
-- log_debug_info(DEBUGL_EVENTS, 0, "set_environment_var '%s'='%s'\n", name, value);
-- syslog(LOG_DAEMON|LOG_INFO, "set_environment_var '%s'='%s'\n", name, value);
--
- #ifdef HAVE_SETENV
- setenv(name, (value == NULL) ? "" : value, 1);
- #else
diff --git a/net-analyzer/nagios-core/files/nagios3 b/net-analyzer/nagios-core/files/nagios3
deleted file mode 100644
index 9b9049362277..000000000000
--- a/net-analyzer/nagios-core/files/nagios3
+++ /dev/null
@@ -1,52 +0,0 @@
-#!/sbin/openrc-run
-# Copyright 1999-2017 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-extra_commands="checkconfig"
-extra_started_commands="reload"
-
-nagios_config="/etc/nagios/nagios.cfg"
-nagios_cmdfile="/var/nagios/rw/nagios.cmd"
-
-command="/usr/sbin/nagios"
-command_args="-d ${nagios_config}"
-pidfile="/var/nagios/nagios.lock"
-start_stop_daemon_args="-e HOME=/var/nagios/home"
-
-depend() {
- need net
- use dns logger firewall
- after mysql postgresql
-}
-
-reload()
-{
- checkconfig || return 1
- ebegin "Reloading configuration"
- start-stop-daemon --signal HUP --pidfile ${pidfile}
- eend $?
-}
-
-checkconfig() {
- ebegin "Verifying config files"
-
- # Silent Check
- /usr/sbin/nagios -v ${nagios_config} &>/dev/null && return 0
-
- # Now we know there's problem - run again and display errors
- /usr/sbin/nagios -v ${nagios_config}
- eend $? "Configuration Error. Please fix your configfile"
-}
-
-start_pre() {
- checkconfig || return 1
-
- touch /var/nagios/nagios.log /var/nagios/status.sav
- chown nagios:nagios /var/nagios/nagios.log /var/nagios/status.sav
- rm -f ${nagios_cmdfile}
-}
-
-stop_post() {
- rm -f /var/nagios/status.log /var/nagios/nagios.tmp ${pidfile} \
- ${nagios_cmdfile}
-}
diff --git a/net-analyzer/nagios-core/files/nagios4-r1 b/net-analyzer/nagios-core/files/nagios4-r1
deleted file mode 100644
index 6309fcf06706..000000000000
--- a/net-analyzer/nagios-core/files/nagios4-r1
+++ /dev/null
@@ -1,45 +0,0 @@
-#!/sbin/openrc-run
-# Copyright 1999-2016 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-extra_commands="checkconfig"
-extra_started_commands="reload"
-
-nagios_config="/etc/nagios/nagios.cfg"
-
-command="/usr/sbin/nagios"
-command_args="-d ${nagios_config}"
-pidfile="/var/nagios/nagios.lock"
-start_stop_daemon_args="-e HOME=/var/nagios/home"
-
-depend(){
- need net
- use dns logger firewall
- after mysql postgresql
-}
-
-reload(){
- checkconfig || return 1
- ebegin "Reloading configuration"
- start-stop-daemon --signal HUP --pidfile ${pidfile}
- eend $?
-}
-
-checkconfig(){
- ebegin "Verifying config files"
-
- # Silent Check
- ${command} -v ${nagios_config} > /dev/null 2>&1 && return 0
-
- # Now we know there's a problem. Run the check again and
- # this time, display the errors.
- ${command} -v ${nagios_config}
- eend $? "Configuration Error. Please fix your config file."
-}
-
-start_pre() {
- # Without this, the "start" action will appear to succeed even
- # when the config file contains errors and the daemon failed to
- # start.
- checkconfig || return 1
-}
diff --git a/net-analyzer/nagios-core/nagios-core-3.5.1.ebuild b/net-analyzer/nagios-core/nagios-core-3.5.1.ebuild
deleted file mode 100644
index 06ad6320317a..000000000000
--- a/net-analyzer/nagios-core/nagios-core-3.5.1.ebuild
+++ /dev/null
@@ -1,216 +0,0 @@
-# Copyright 1999-2018 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=5
-
-inherit depend.apache eutils multilib toolchain-funcs user
-
-MY_P=${PN/-core}-${PV}
-DESCRIPTION="Nagios Core - Check daemon, CGIs, docs"
-HOMEPAGE="https://www.nagios.org/"
-SRC_URI="mirror://sourceforge/nagios/${MY_P}.tar.gz"
-
-LICENSE="GPL-2"
-SLOT="0"
-KEYWORDS="alpha amd64 ~arm ~arm64 hppa ppc ppc64 sparc x86"
-IUSE="debug lighttpd perl +web vim-syntax"
-DEPEND="virtual/mailx
- web? (
- >=media-libs/gd-1.8.3-r5[jpeg,png]
- lighttpd? ( www-servers/lighttpd dev-lang/php[cgi] )
- apache2? ( || ( dev-lang/php[apache2] dev-lang/php[cgi] ) )
- )
- perl? ( >=dev-lang/perl-5.6.1-r7:= )"
-RDEPEND="${DEPEND}
- !net-analyzer/nagios-imagepack
- vim-syntax? ( app-vim/nagios-syntax )"
-
-want_apache2
-
-S="${WORKDIR}/${PN/-core}"
-
-pkg_setup() {
- depend.apache_pkg_setup
-
- enewgroup nagios
- enewuser nagios -1 /bin/bash /var/nagios/home nagios
-}
-
-src_prepare() {
- epatch "${FILESDIR}/${PN}-3.5.1-process_cgivars.patch"
- local strip="$(echo '$(MAKE) strip-post-install')"
- sed -i -e "s:${strip}::" {cgi,base}/Makefile.in || die "sed failed in Makefile.in"
-}
-
-src_configure() {
- local myconf
-
- if use perl ; then
- myconf="${myconf} --enable-embedded-perl --with-perlcache"
- fi
-
- if use debug; then
- myconf="${myconf} --enable-DEBUG0"
- myconf="${myconf} --enable-DEBUG1"
- myconf="${myconf} --enable-DEBUG2"
- myconf="${myconf} --enable-DEBUG3"
- myconf="${myconf} --enable-DEBUG4"
- myconf="${myconf} --enable-DEBUG5"
- fi
-
- if use !apache2 && use !lighttpd ; then
- myconf="${myconf} --with-command-group=nagios"
- else
- if use apache2 ; then
- myconf="${myconf} --with-command-group=apache"
- myconf="${myconf} --with-httpd-conf=/etc/apache2/conf.d"
- elif use lighttpd ; then
- myconf="${myconf} --with-command-group=lighttpd"
- fi
- fi
-
- econf ${myconf} \
- --prefix=/usr \
- --bindir=/usr/sbin \
- --sbindir=/usr/$(get_libdir)/nagios/cgi-bin \
- --datadir=/usr/share/nagios/htdocs \
- --localstatedir=/var/nagios \
- --sysconfdir=/etc/nagios \
- --libexecdir=/usr/$(get_libdir)/nagios/plugins
-}
-
-src_compile() {
- emake CC=$(tc-getCC) nagios
-
- if use web ; then
- # Only compile the CGI's if "web" useflag is set.
- emake CC=$(tc-getCC) DESTDIR="${D}" cgis
- fi
-}
-
-src_install() {
- dodoc Changelog INSTALLING LEGAL README UPGRADING
-
- if ! use web ; then
- sed -i -e 's/cd $(SRC_CGI) && $(MAKE) $@/# line removed due missing web use flag/' \
- -e 's/cd $(SRC_HTM) && $(MAKE) $@/# line removed due missing web use flag/' \
- -e 's/$(MAKE) install-exfoliation/# line removed due missing web use flag/' \
- Makefile
- fi
-
- sed -i -e 's/^contactgroups$//g' Makefile
-
- emake DESTDIR="${D}" install
- emake DESTDIR="${D}" install-config
- emake DESTDIR="${D}" install-commandmode
- if use web; then
- emake DESTDIR="${D}" install-classicui
- fi
-
- newinitd "${FILESDIR}"/nagios3 nagios
- newconfd "${FILESDIR}"/conf.d nagios
-
- # Apache Module
- if use web ; then
- if use apache2 ; then
- insinto "${APACHE_MODULES_CONFDIR}"
- doins "${FILESDIR}"/99_nagios3.conf
- elif use lighttpd ; then
- insinto /etc/lighttpd
- newins "${FILESDIR}/lighttpd_nagios3-r1.conf" nagios.conf
- else
- ewarn "${CATEGORY}/${PF} only supports Apache-2.x or Lighttpd webserver"
- ewarn "out-of-the-box. Since you are not using one of them, you"
- ewarn "have to configure your webserver accordingly yourself."
- fi
-
- fi
-
- for dir in etc/nagios var/nagios ; do
- chown -R nagios:nagios "${D}/${dir}" || die "Failed chown of ${D}/${dir}"
- done
-
- dosbin p1.pl
-
- chown -R root:root "${D}"/usr/$(get_libdir)/nagios
- find "${D}"/usr/$(get_libdir)/nagios -type d -print0 | xargs -0 chmod 755
- find "${D}"/usr/$(get_libdir)/nagios/cgi-bin -type f -print0 | xargs -0 chmod 755
-
- keepdir /etc/nagios
- keepdir /var/nagios
- keepdir /var/nagios/archives
- keepdir /var/nagios/rw
- keepdir /var/nagios/spool/checkresults
-
- if use !apache2 && use !lighttpd; then
- chown -R nagios:nagios "${D}"/var/nagios/rw || die "Failed chown of ${D}/var/nagios/rw"
- else
- if use apache2 ; then
- chown -R nagios:apache "${D}"/var/nagios/rw || die "Failed chown of ${D}/var/nagios/rw"
- elif use lighttpd ; then
- chown -R nagios:lighttpd "${D}"/var/nagios/rw || die "Failed chown of ${D}/var/nagios/rw"
- fi
- fi
-
- chmod ug+s "${D}"/var/nagios/rw || die "Failed Chmod of ${D}/var/nagios/rw"
- chmod 0750 "${D}"/etc/nagios || die "Failed chmod of ${D}/etc/nagios"
-}
-
-pkg_postinst() {
- elog "If you want nagios to start at boot time"
- elog "remember to execute:"
- elog " rc-update add nagios default"
- elog
-
- if use web ; then
- elog "This does not include cgis that are perl-dependent"
- elog "Currently traceroute.cgi is perl-dependent"
- elog "To have ministatus.cgi requires copying of ministatus.c"
- elog "to cgi directory for compiling."
-
- elog "Note that the user your webserver is running at needs"
- elog "read-access to /etc/nagios."
- elog
-
- if use apache2 || use lighttpd ; then
- elog "There are several possible solutions to accomplish this,"
- elog "choose the one you are most comfortable with:"
- elog
- if use apache2 ; then
- elog " usermod -G nagios apache"
- elog "or"
- elog " chown nagios:apache /etc/nagios"
- elog
- elog "Also edit /etc/conf.d/apache2 and add \"-D NAGIOS\""
- elif use lighttpd ; then
- elog " usermod -G nagios lighttpd "
- elog "or"
- elog " chown nagios:lighttpd /etc/nagios"
- fi
- elog
- elog "That will make nagios's web front end visable via"
- elog "http://localhost/nagios/"
- elog
- else
- elog "IMPORTANT: Do not forget to add the user your webserver"
- elog "is running as to the nagios group!"
- fi
-
- else
- elog "Please note that you have installed Nagios without web interface."
- elog "Please don't file any bugs about having no web interface when you do this."
- elog "Thank you!"
- fi
-
- elog
- elog "If your kernel has /proc protection, nagios"
- elog "will not be happy as it relies on accessing the proc"
- elog "filesystem. You can fix this by adding nagios into"
- elog "the group wheel, but this is not recomended."
- elog
-}
-
-pkg_postinst() {
- einfo "Fixing permissions"
- chown nagios:nagios "${ROOT}"var/nagios
-}
diff --git a/net-analyzer/nagios-core/nagios-core-4.3.1-r1.ebuild b/net-analyzer/nagios-core/nagios-core-4.3.1-r1.ebuild
deleted file mode 100644
index 7e952737c4d0..000000000000
--- a/net-analyzer/nagios-core/nagios-core-4.3.1-r1.ebuild
+++ /dev/null
@@ -1,249 +0,0 @@
-# Copyright 1999-2018 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=6
-
-inherit toolchain-funcs user
-
-MY_P=${PN/-core}-${PV}
-DESCRIPTION="Nagios core - monitoring daemon, web GUI, and documentation"
-HOMEPAGE="https://www.nagios.org/"
-
-# The name of the directory into which our Gentoo icons will be
-# extracted, and also the basename of the archive containing it.
-GENTOO_ICONS="${PN}-gentoo-icons-20141125"
-SRC_URI="mirror://sourceforge/nagios/${MY_P}.tar.gz
- web? ( https://dev.gentoo.org/~mjo/distfiles/${GENTOO_ICONS}.tar )"
-
-LICENSE="GPL-2"
-SLOT="0"
-KEYWORDS="alpha amd64 ~arm ~arm64 hppa ppc ppc64 sparc x86"
-IUSE="apache2 classicui lighttpd perl +web vim-syntax"
-
-# In pkg_postinst(), we change the group of the Nagios configuration
-# directory to that of the web server user. It can't belong to both
-# apache/lighttpd groups at the same time, so we block this combination
-# for our own sanity.
-#
-# This could be made to work, but we would need a better way to allow
-# the web user read-only access to Nagios's configuration directory.
-#
-REQUIRED_USE="apache2? ( !lighttpd )"
-
-# sys-devel/libtool dependency is bug #401237.
-#
-# Note, we require one of the apache2 CGI modules:
-#
-# * mod_cgi
-# * mod_cgid
-# * mod_fcgid
-#
-# We just don't care /which/ one. And of course PHP supports both CGI
-# (USE=cgi) and FastCGI (USE=fpm). We're pretty lenient with the
-# dependencies, and expect the user not to do anything /too/
-# stupid. (For example, installing Apache with only FastCGI support, and
-# PHP with only CGI support.)
-#
-# Another annoyance is that the upstream Makefile uses app-arch/unzip to
-# extract a snapshot of AngularJS, but that's only needed when USE=web.
-#
-MOD_ALIAS=apache2_modules_alias
-DEPEND="sys-devel/libtool
- virtual/mailx
- perl? ( dev-lang/perl:= )
- web? (
- app-arch/unzip
- media-libs/gd[jpeg,png]
- lighttpd? ( www-servers/lighttpd[php] )
- apache2? (
- || (
- >=www-servers/apache-2.4[${MOD_ALIAS},apache2_modules_cgi]
- >=www-servers/apache-2.4[${MOD_ALIAS},apache2_modules_cgid]
- >=www-servers/apache-2.4[${MOD_ALIAS},apache2_modules_fcgid] )
- || (
- dev-lang/php:*[apache2]
- dev-lang/php:*[cgi]
- dev-lang/php:*[fpm] )
- )
- )"
-RDEPEND="${DEPEND}
- vim-syntax? ( app-vim/nagios-syntax )"
-
-S="${WORKDIR}/${MY_P}"
-
-PATCHES=( "${FILESDIR}"/${PN}-4.3.1-fix-upstream-issue-337.patch )
-
-pkg_setup() {
- enewgroup nagios
- enewuser nagios -1 /bin/bash /var/nagios/home nagios
-}
-
-src_configure() {
- local myconf
-
- if use perl; then
- myconf="${myconf} --enable-embedded-perl --with-perlcache"
- fi
-
- if use !apache2 && use !lighttpd ; then
- myconf="${myconf} --with-command-group=nagios"
- else
- if use apache2 ; then
- myconf="${myconf} --with-command-group=apache"
- myconf="${myconf} --with-httpd-conf=/etc/apache2/conf.d"
- elif use lighttpd ; then
- myconf="${myconf} --with-command-group=lighttpd"
- fi
- fi
-
- econf ${myconf} \
- --prefix=/usr \
- --bindir=/usr/sbin \
- --sbindir=/usr/$(get_libdir)/nagios/cgi-bin \
- --datadir=/usr/share/nagios/htdocs \
- --localstatedir=/var/nagios \
- --sysconfdir=/etc/nagios \
- --libexecdir=/usr/$(get_libdir)/nagios/plugins
-}
-
-src_compile() {
- emake CC=$(tc-getCC) nagios
-
- if use web; then
- # Only compile the CGIs/HTML when USE=web is set.
- emake CC=$(tc-getCC) DESTDIR="${D}" cgis html
- fi
-}
-
-src_install() {
- dodoc Changelog INSTALLING LEGAL README.asciidoc UPGRADING
-
- emake DESTDIR="${D}" install-base
- emake DESTDIR="${D}" install-basic
- emake DESTDIR="${D}" install-config
- emake DESTDIR="${D}" install-commandmode
-
- if use web; then
- emake DESTDIR="${D}" install-cgis
-
- # install-html installs the new exfoliation theme
- emake DESTDIR="${D}" install-html
-
- if use classicui; then
- # This overwrites the already-installed exfoliation theme
- emake DESTDIR="${D}" install-classicui
- fi
-
- # Install cute Gentoo icons (bug #388323), setting their
- # owner, group, and mode to match those of the rest of Nagios's
- # images.
- insopts --group=nagios --owner=nagios --mode=0664
- insinto /usr/share/nagios/htdocs/images/logos
- doins "${WORKDIR}/${GENTOO_ICONS}"/*.*
- insopts --mode=0644 # Back to the default...
- fi
-
- newinitd "${FILESDIR}"/nagios4-r1 nagios
- newconfd "${FILESDIR}"/conf.d nagios
-
- if use web ; then
- if use apache2 ; then
- # Install the Nagios configuration file for Apache.
- insinto "/etc/apache2/modules.d"
- doins "${FILESDIR}"/99_nagios4.conf
- elif use lighttpd ; then
- # Install the Nagios configuration file for Lighttpd.
- insinto /etc/lighttpd
- newins "${FILESDIR}/lighttpd_nagios4.conf" nagios.conf
- else
- ewarn "${CATEGORY}/${PF} only supports apache or lighttpd"
- ewarn "out of the box. Since you are not using one of them, you"
- ewarn "will have to configure your webserver yourself."
- fi
- fi
-
- for dir in etc/nagios var/nagios ; do
- chown -R nagios:nagios "${D}/${dir}" \
- || die "failed chown of ${D}/${dir}"
- done
-
- chown -R root:root "${D}/usr/$(get_libdir)/nagios" \
- || die "failed chown of ${D}/usr/$(get_libdir)/nagios"
-
- # The following two find...exec statements will die properly as long
- # as chmod is only called once (that is, as long as the argument
- # list is small enough).
- find "${D}/usr/$(get_libdir)/nagios" -type d \
- -exec chmod 755 '{}' + || die 'failed to make nagios dirs traversable'
-
- if use web; then
- find "${D}/usr/$(get_libdir)/nagios/cgi-bin" -type f \
- -exec chmod 755 '{}' + || die 'failed to make cgi-bins executable'
- fi
-
- keepdir /etc/nagios
- keepdir /var/nagios
- keepdir /var/nagios/archives
- keepdir /var/nagios/rw
- keepdir /var/nagios/spool/checkresults
-
- if use !apache2 && use !lighttpd; then
- chown -R nagios:nagios "${D}"/var/nagios/rw \
- || die "failed chown of ${D}/var/nagios/rw"
- else
- if use apache2 ; then
- chown -R nagios:apache "${D}"/var/nagios/rw \
- || die "failed chown of ${D}/var/nagios/rw"
- elif use lighttpd ; then
- chown -R nagios:lighttpd "${D}"/var/nagios/rw \
- || die "failed chown of ${D}/var/nagios/rw"
- fi
- fi
-
- chmod ug+s "${D}"/var/nagios/rw || die "failed chmod of ${D}/var/nagios/rw"
- chmod 0750 "${D}"/etc/nagios || die "failed chmod of ${D}/etc/nagios"
-}
-
-pkg_postinst() {
-
- if use web; then
- elog "Note that your web server user requires read-only access to"
- elog "${ROOT}etc/nagios."
-
- if use apache2 || use lighttpd ; then
- elog
- elog "To that end, we have changed the group of ${ROOT}etc/nagios"
- elog "to that of your web server user."
- elog
- if use apache2; then
- chown nagios:apache "${ROOT}etc/nagios" \
- || die "failed to change group of ${ROOT}etc/nagios"
-
- elog "To enable the Nagios web front-end, please edit"
- elog "${ROOT}etc/conf.d/apache2 and add \"-D NAGIOS -D PHP\""
- elog "to APACHE2_OPTS. Then Nagios will be available at,"
- elog
- elif use lighttpd; then
- chown nagios:lighttpd "${ROOT}etc/nagios" \
- || die "failed to change group of ${ROOT}etc/nagios"
- elog "To enable the Nagios web front-end, please add"
- elog "'include \"nagios.conf\"' to the lighttpd configuration"
- elog "file at ${ROOT}etc/lighttpd/lighttpd.conf. Then Nagios"
- elog "will be available at,"
- elog
- fi
-
- elog " http://localhost/nagios/"
- else
- elog "Since you're not using either Apache or Lighttpd, you"
- elog "will have to grant the necessary permissions yourself."
- fi
- fi
-
- elog
- elog "If your kernel has /proc protection, nagios"
- elog "will not be happy as it relies on accessing the proc"
- elog "filesystem. You can fix this by adding nagios into"
- elog "the group wheel, but this is not recomended."
- elog
-}