-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathsetup.php
47 lines (41 loc) · 1.93 KB
/
setup.php
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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
<?php
/*
ex: set tabstop=4 shiftwidth=4 autoindent:
+-------------------------------------------------------------------------+
| Copyright (C) 2016 Matthew Modestino, Philippe Tang, Menno Vanderlist |
| |
| This program is free software; you can redistribute it and/or |
| modify it under the terms of the GNU General Public License |
| as published by the Free Software Foundation; either version 2 |
| of the License, or (at your option) any later version. |
| |
| This program is distributed in the hope that it will be useful, |
| but WITHOUT ANY WARRANTY; without even the implied warranty of |
| MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| GNU General Public License for more details. |
+-------------------------------------------------------------------------+
| https://github.com/n00badmin/mirage |
| http://docs.cacti.net/plugin:mirage |
+-------------------------------------------------------------------------+
*/
function plugin_mirage_install () {
global $config;
api_plugin_register_hook('mirage', 'poller_output', 'mirage_poller_output', 'includes/polling.php');
api_plugin_register_hook('mirage', 'config_settings', 'mirage_config_settings', 'includes/settings.php');
}
function plugin_mirage_uninstall () {
// Do any extra Uninstall stuff here
}
function plugin_mirage_check_config () {
// Here we will check to ensure everything is configured
return true;
}
function mirage_version () {
return plugin_mirage_version();
}
function plugin_mirage_version () {
global $config;
$info = parse_ini_file($config['base_path'] . '/plugins/mirage/INFO', true);
return $info['info'];
}
?>