New command to halt ejabberd abruptly with an error status code

Used for processone/ejabberd-contrib#97
This commit is contained in:
Badlop 2023-06-13 00:56:19 +02:00
parent d2c54fd5fe
commit dcc8149f58
1 changed files with 4 additions and 0 deletions

View File

@ -116,6 +116,10 @@ get_commands_spec() ->
desc = "Stop ejabberd gracefully",
module = ?MODULE, function = stop,
args = [], result = {res, rescode}},
#ejabberd_commands{name = halt, tags = [server],
desc = "Halt ejabberd abruptly with status code 1",
module = ejabberd, function = halt,
args = [], result = {res, rescode}},
#ejabberd_commands{name = restart, tags = [server],
desc = "Restart ejabberd gracefully",
module = ?MODULE, function = restart,