Professional Documents
Culture Documents
3)
# chmod +x install.sh
# ./install.sh
Please refer What To Do Next
Manual Installation Guide
1. Setup EPEL Yum Repositories with newer packages and install Git:
[CentOS]
rpm -Uvh http://dl.fedoraproject.org/pub/epel/6/`uname -m`/epel-release-6-
8.noarch.rpm
2. Install packages
[Debian]
apt-get install git
[CentOS]
yum install git
3. Install Freeswitch :
Install Freeswitch pre-requisite packages
[Debian]
aptitude update && aptitude safe-upgrade && aptitude clean && aptitude
autoclean
cd /usr/src/
git clone git://github.com/ASTPP/ASTPP.git
2. Install ASTPP pre-requisite packages using YUM
[Debian]
aptitude install -y mysql-server apache2 apache2-threaded-dev php5 php5-
dev php5-common
php5-cli php5-gd php-pear php5-mysql php5-cli php-apc php5-curl
libapache2-mod-php5 perl
libapache2-mod-perl2 libxml2 libxml2-dev openssl libcurl4-openssl-dev
gettext libtool gcc g++
[CentOS]
yum install -y cpan autoconf automake bzip2 cpio curl curl-devel php php-
devel php-common
php-cli php-gd php-pear php-mysql php-pdo php-pecl-json mysql mysql-server
mysql-devel libxml2
libxml2-devel openssl openssl-devel gettext-devel libtool fileutils gcc-
c++ httpd httpd-devel
perl-YAML cpan perl
3. Normalize ASTPP (for debian only)
sed -i
"s#/var/log/httpd/astpp_access_log#/var/log/apache2/astpp_access_log#g"
/usr/src/ASTPP/web_interface/apache/astpp.conf
sed -i
"s#/var/log/httpd/astpp_error_log#/var/log/apache2/astpp_error_log#g"
/usr/src/ASTPP/web_interface/apache/astpp.conf
touch /var/log/apache2/astpp_access_log
touch /var/log/apache2/astpp_error_log
4. Install ASTPP Perl packages
DateTime::TimeZone,DateTime::Locale,XML::Simple,Data::Dumper,Module::Build,Stora
ble,Time::Zone,Date::Parse,Curses,
POE,Sys::Syslog,FCGI,DateTime::Set,DateTime::Event::Recurrence,DateTime::Incompl
ete,Date::Language,DateTime::Format::Strptime,
DBI::Shell,JSON,CGI::Fast,Locale::gettext_pp,Text::Template,Mail::Sendmail,XML::
Simple";
mkdir -p /var/lib/astpp/
mkdir -p /var/log/astpp/
mkdir -p /usr/local/astpp/
mkdir -p /var/www/
[Debian]
chown -Rf www-data.www-data /var/lib/astpp/
chown -Rf www-data.www-data /var/log/astpp/
chown -Rf www-data.www-data /usr/local/astpp/
chown -Rf www-data.www-data /var/www/
[CentOS]
chown -Rf apache.apache /var/lib/astpp/
chown -Rf apache.apache /var/log/astpp/
chown -Rf apache.apache /usr/local/astpp/
chown -Rf apache.apache /var/www/
cp /usr/src/ASTPP/freeswitch/astpp-callingcards.pl
/usr/local/freeswitch/scripts/astpp-callingcards.pl
cp -rf /usr/src/ASTPP/sounds/*.wav
/usr/local/freeswitch/sounds/en/us/callie//
chmod -Rf 777 /usr/local/freeswitch/sounds/en/us/callie/
6. Install ASTPP web interface
cp /usr/src/ASTPP/astpp_confs/sample.astpp-config.conf
/var/lib/astpp//astpp-config.conf
cp /usr/src/ASTPP/astpp_confs/sample.reseller-config.conf
/var/lib/astpp//sample.reseller-config.conf
mkdir -p /var/www//html/astpp
cp -rf /usr/src/ASTPP/web_interface/astpp/* /var/www//html/astpp/
cp /usr/src/ASTPP/web_interface/astpp/htaccess
/var/www//html/astpp/.htaccess
[Debian]
chown -Rf www-data.www-data /var/www//html/astpp
cp /usr/src/ASTPP/web_interface/apache/astpp.conf
/etc/apache2/conf.d/astpp.conf
[CentOS]
chown -Rf apache.apache /var/www//html/astpp
cp /usr/src/ASTPP/web_interface/apache/astpp.conf
/etc/httpd/conf.d/astpp.conf
1. Apache
[Debian]
/etc/init.d/apache2 start
[CentOS]
/etc/init.d/httpd start
2. Mysql
[Debian]
/etc/init.d/mysql start
[CentOS]
/etc/init.d/mysqld start
3. Freeswitch
/etc/init.d/freeswitch start
8. Install ASTPP Database
cd /usr/src/ASTPP/freeswitch/conf
cp autoload_configs/xml_curl.conf.xml
/usr/local/freeswitch/conf/autoload_configs/
Note : Edit xml_curl.conf.xml file and change localhost to your ip or
domain name.
cp autoload_configs/xml_cdr.conf.xml
/usr/local/freeswitch/conf/autoload_configs/
Note : Edit xml_cdr.conf.xml file and change localhost to your ip or
domain name.
cp autoload_configs/cdr_csv.conf.xml
/usr/local/freeswitch/conf/autoload_configs/
cp dialplan/default/astpp_callingcards.xml
/usr/local/freeswitch/conf/dialplan/default/
Note : Edit astpp_callingcards.xml file to change acccess number for
calling card.
Once above setting are done, restart freeswitch and check if above modules
are loaded or not. If not then please load it manually.
11. Setup cron
# Generate Invoice
0 1 * * * cd /var/www/html/astpp/cron/ && php cron.php GenerateInvoice
What to do next?
Secure your server Change the default GUI password and perhaps install Fail2ban for example.
Goto System Configuration >> Configuration and make the appropriate changes pertaining to your
setup.
Note :
1. We already have added demo data in few modules.
2. Pricelist module name is changed to Rate Group
3. In Termination Rates and Origination Rates, no need to append ^ and .*
manually.
[Origination Configuration]
1. Create Rate Group. Routing -> Rate Group
2. Add Origination Rates. Routing -> Origination rates (Pattern example : 1,
235)
Note : Please do not use ^ or .*
[Termination Configuration]
1. Create SIP Profile. Routing -> SIP Profile
2. Add Gateway under your sip profile. Routing -> Gateway
3. Add Provider. Global Accounts -> Provider List
4. Add your trunk. Routing -> Trunk
5. Add termination rates. Routing -> Termination rates (Pattern example : 1,
235)
Note : Please do not use ^ or .*
Create new Customer or Reseller and assign your created rate group. For customer add SIP Device
from View Account or Freeswitch SIP Devices.
For reseller configuration, create new reseller. Login as reseller. Add Routes. Create customers and
then make calls using that customer.
Register it and make outbound calls.