Commit 1b02aa3e authored by CI Runner's avatar CI Runner Committed by GitHub
Browse files

Merge pull request #3 from Zuckonit/master

fix bug when es and kibana deployed on diff host
parents 9130132b ebce1e3a
......@@ -18,15 +18,18 @@
* SearchGuard plugin extension for the Elasticsearch Javascript client.
*/
import util from 'util';
export default function (Client, config, components) {
const ca = components.clientAction.factory;
const host = config.host;
const url = util.format('%s//%s:%s/_searchguard/authinfo', host.protocol, host.host, host.port);
Client.prototype.searchguard = components.clientAction.namespaceFactory();
Client.prototype.searchguard.prototype.authinfo = ca({
url: {
fmt: '_searchguard/authinfo'
fmt: url
}
});
};
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment