-
Notifications
You must be signed in to change notification settings - Fork 3
/
index.js
37 lines (31 loc) · 921 Bytes
/
index.js
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
var path = require('path');
module.exports = function (kibana) {
return new kibana.Plugin({
name: 'kibana-keynote',
require: ['kibana', 'elasticsearch'],
uiExports: {
app: {
title: 'Keynote',
description: 'Weeeeee',
icon: 'plugins/kibana-keynote/icon.svg',
main: 'plugins/kibana-keynote/app',
injectVars: function (server, options) {
var config = server.config();
return {
kbnIndex: config.get('kibana.index'),
esShardTimeout: config.get('elasticsearch.shardTimeout'),
esApiVersion: config.get('elasticsearch.apiVersion')
};
}
}
},
config: function (Joi) {
return Joi.object({
enabled: Joi.boolean().default(true),
}).default();
},
init: function (server, options) {
// Add server routes and initalize the plugin here
}
});
};