From fbe76ba9baddac2eadc7a2251397182ba1196926 Mon Sep 17 00:00:00 2001 From: Andre Heider Date: Thu, 4 Nov 2021 08:57:09 +0100 Subject: [PATCH] asterisk: add a reregister extra command The new `/etc/init.d/asterisk reregister` will re-register all outbound registrations. Signed-off-by: Andre Heider --- net/asterisk/files/asterisk.init | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/net/asterisk/files/asterisk.init b/net/asterisk/files/asterisk.init index f056c6c8..b5a64070 100644 --- a/net/asterisk/files/asterisk.init +++ b/net/asterisk/files/asterisk.init @@ -66,3 +66,9 @@ start_service() { reload_service() { procd_send_signal $NAME } + +extra_command "reregister" "Re-register all outbound registrations" +reregister() { + log info "re-registering all outbound registrations" + $COMMAND -x 'pjsip send unregister *all' -x 'pjsip send register *all' +}