wazuh-kibana-app/index.js

37 lines
1.2 KiB
JavaScript
Raw Normal View History

2016-06-29 01:43:18 +00:00
module.exports = function (kibana) {
return new kibana.Plugin({
2016-08-01 14:50:18 +00:00
id: 'wazuh',
2016-06-29 01:43:18 +00:00
name: 'wazuh',
require: ['kibana', 'elasticsearch'],
uiExports: {
app: {
2016-08-01 14:50:18 +00:00
id: 'wazuh',
2016-07-22 09:03:49 +00:00
title: 'Wazuh',
2016-12-22 19:54:57 +00:00
description: 'Wazuh App for Kibana',
icon: 'plugins/wazuh/img/icon.png',
2016-06-29 01:43:18 +00:00
main: 'plugins/wazuh/app',
injectVars: function (server, options) {
const serverConfig = server.config();
const configuredUrl = server.config().get('tilemap.url');
const isOverridden = typeof configuredUrl === 'string' && configuredUrl !== '';
const tilemapConfig = serverConfig.get('tilemap');
2016-06-29 01:43:18 +00:00
return {
kbnIndex: serverConfig.get('kibana.index'),
esApiVersion: serverConfig.get('elasticsearch.apiVersion'),
esShardTimeout: serverConfig.get('elasticsearch.shardTimeout'),
tilemapsConfig: {
deprecated: {
isOverridden: isOverridden,
config: tilemapConfig,
},
manifestServiceUrl: serverConfig.get('tilemap.manifestServiceUrl')
}
2016-06-29 01:43:18 +00:00
};
}
}
},
init: require('./init.js')
});
};