12 lines
526 B
Bash
12 lines
526 B
Bash
#! /bin/bash
|
|
|
|
echo "Reloading config files..."
|
|
curl -so /etc/asterisk/asterisk.conf https://ap5.gonknet.org/asterisk/$HOSTNAME/$GONK_KEY
|
|
curl -so /etc/asterisk/pjsip.conf https://ap5.gonknet.org/pjsip/$HOSTNAME/$GONK_KEY
|
|
curl -so /etc/asterisk/modules.conf https://ap5.gonknet.org/modules/$HOSTNAME/$GONK_KEY
|
|
curl -so /etc/asterisk/logger.conf https://ap5.gonknet.org/logger/$HOSTNAME/$GONK_KEY
|
|
|
|
sed "s/##EXTERNAL_IP##/$(curl https://ipv4.myip.wtf/text)/g" /etc/asterisk/pjsip.conf
|
|
|
|
|
|
asterisk -x "core restart when convenient" |