MXS-2375: Provide aliases for [start|stop] maxscale

The `start services` and `stop services` command aliases now map to the
same command as `start maxscale` and `stop maxscale`. This should help
alleviate the confusion that the command naming caused.
This commit is contained in:
Markus Mäkelä 2019-03-12 07:24:19 +02:00
parent 84e456eee2
commit e2ac52826a
No known key found for this signature in database
GPG Key ID: 72D48FCE664F7B19
2 changed files with 4 additions and 4 deletions

View File

@ -33,10 +33,10 @@ exports.builder = function(yargs) {
return doRequest(host, 'monitors/' + argv.name + '/start', null, {method: 'PUT'})
})
})
.command('maxscale', 'Start MaxScale by starting all services', function(yargs) {
.command(['services', 'maxscale'], 'Start all services', function(yargs) {
return yargs.epilog('This command will execute the `start service` command for ' +
'all services in MaxScale.')
.usage('Usage: start maxscale')
.usage('Usage: start [services|maxscale]')
}, function(argv) {
maxctrl(argv, function(host) {
return doRequest(host, 'services/', function(res) {

View File

@ -37,10 +37,10 @@ exports.builder = function(yargs) {
return doRequest(host, 'monitors/' + argv.name + '/stop', null, {method: 'PUT'})
})
})
.command('maxscale', 'Stop MaxScale by stopping all services', function(yargs) {
.command(['services', 'maxscale'], 'Stop all services', function(yargs) {
return yargs.epilog('This command will execute the `stop service` command for ' +
'all services in MaxScale.')
.usage('Usage: stop maxscale')
.usage('Usage: stop [services|maxscale]')
}, function(argv) {
maxctrl(argv, function(host) {
return doRequest(host, 'services/', function(res) {