From c418bf81e1285e5ecc8af86add0b6565d75a4bc3 Mon Sep 17 00:00:00 2001 From: Marko Date: Tue, 4 Jun 2019 13:41:35 +0300 Subject: [PATCH] MXS-2493 Add maxctrl show dbusers --- maxctrl/lib/show.js | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/maxctrl/lib/show.js b/maxctrl/lib/show.js index 359a701dc..34c737931 100644 --- a/maxctrl/lib/show.js +++ b/maxctrl/lib/show.js @@ -303,6 +303,19 @@ exports.builder = function(yargs) { ]) }) }) + .command('dbusers ', 'Show database users of the service', function(yargs) { + return yargs.epilog('Show information about the database users of the service') + .usage('Usage: show dbusers ') + }, function(argv) { + maxctrl(argv, function(host) { + return getSubCollection(host, 'services/' + argv.service, 'attributes.listeners[]', [ + {'Users': 'attributes.authenticator_diagnostics[]'}, + {'Listener': 'id'}, + {'Authenticator': 'attributes.parameters.authenticator'} + ]) + }) + }) + .usage('Usage: show ') .help() .command('*', 'the default command', {}, function(argv) {