Created
February 20, 2017 16:00
-
-
Save MacroMan/c40df7545516aec2cb7836bf0b0d1a63 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
read -p $"This will install Asterisk. [Enter] to continue..." | |
# get deps | |
apt -y install build-essential libncurses5-dev libxml2-dev libsqlite3-dev libssl-dev libsrtp0-dev uuid-dev libjansson-dev | |
read -p $"Installed dependencies. [Enter] to continue..." | |
# download and install | |
cd /usr/src | |
wget http://downloads.asterisk.org/pub/telephony/asterisk/asterisk-14-current.tar.gz | |
tar -zxvf asterisk-14-current.tar.gz | |
rm asterisk-14-current.tar.gz | |
cd asterisk-14* | |
read -p $"Downloaded source. [Enter] to continue..." | |
./contrib/scripts/install_prereq install | |
./contrib/scripts/install_prereq install-unpackaged | |
./contrib/scripts/get_mp3_source.sh | |
read -p $"Installed prereqs. [Enter] to continue..." | |
make clean | |
./configure | |
make menuselect | |
read -p $"Configured [Enter] to continue..." | |
make | |
read -p $"Made. [Enter] to continue..." | |
make install | |
read -p $"Installed. [Enter] to continue..." | |
make samples | |
make config | |
read -p $"Config installed. [Enter] to continue..." | |
# configure | |
mkdir /etc/asterisk/keys | |
cd contrib/scripts/ | |
./ast_tls_cert -C x.x.x.x -O "TEST CERTIFICATE" -d /etc/asterisk/keys | |
read -p $"TLS cert generated. [Enter] to continue..." | |
service asterisk stop | |
service asterisk start | |
read -p $"Asterisk restarted. [Enter] to continue..." | |
echo "Run 'http show status' once cli is launched" | |
asterisk -vvvvr |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment