File: run.php

package info (click to toggle)
icingaweb2-module-graphite 1.2.5-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 1,000 kB
  • sloc: php: 3,546; javascript: 88; sh: 54; makefile: 15
file content (29 lines) | stat: -rw-r--r-- 987 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
<?php

/** @var \Icinga\Application\Modules\Module $this */

use Icinga\Module\Graphite\ProvidedHook\Icingadb\IcingadbSupport;

$this->provideHook('monitoring/DetailviewExtension');
$this->provideHook('icingadb/IcingadbSupport');
$this->provideHook('icingadb/HostDetailExtension');
$this->provideHook('icingadb/ServiceDetailExtension');

if (! $this->exists('icingadb') || ! IcingadbSupport::useIcingaDbAsBackend()) {
    $this->addRoute('graphite/monitoring-graph/host', new Zend_Controller_Router_Route(
        'graphite/graph/host',
        [
            'controller'    => 'monitoring-graph',
            'action'        => 'host',
            'module'        => 'graphite'
        ]
    ));
    $this->addRoute('graphite/monitoring-graph/service', new Zend_Controller_Router_Route(
        'graphite/graph/service',
        [
            'controller'    => 'monitoring-graph',
            'action'        => 'service',
            'module'        => 'graphite'
        ]
    ));
}