-
Notifications
You must be signed in to change notification settings - Fork 45
/
Copy pathINSTALL
129 lines (94 loc) · 5.69 KB
/
INSTALL
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
---------------------------------------------------------------------------------------------------------------------------------------------------------------
----- ASTPP FREESWITCH INSTALLATION DOCUMENT -------
---------------------------------------------------------------------------------------------------------------------------------------------------------------
1. Setup EPEL Yum Repositories with newer packages and install Git:
rpm -Uvh http://dl.fedoraproject.org/pub/epel/5/`uname -m`/epel-release-5-4.noarch.rpm
2. Install YUM packages
yum install git
3. Install Freeswitch :
* Install Freeswitch pre-requisite packages using YUM
yum install expat-devel gnutls-devel libtiff-devel libX11-devel unixODBC-devel libssl-devel python-devel zlib-devel libzrtpcpp-devel alsa-lib-devel libogg-devel libvorbis-devel perl-libs gdbm-devel libdb-devel uuid-devel @development-tools gdbm-devel db4-devel libjpeg libjpeg-devel libtermcap libtermcap-devel ncurses ncurses-devel
* Download latest freeswitch version
cd /usr/local/src
git clone git://git.freeswitch.org/freeswitch.git
cd freeswitch
./bootstrap.sh
* Edit modules.conf
Enable mod_perl, mod_xml_curl, mod_xml_cdr
* Compile the Source
./configure
make
* Install Freeswitch with sound files
make all install cd-sounds-install cd-moh-install
4. ASTPP Install :
1. Download ASTPP
cd /usr/src/
git clone https://github.com/ASTPP/ASTPP.git
2. Goto ASTPP Folder & Run Make Command
1. cd ASTPP
2. make (Here you will get the instructions folder it)
Note : To install ASTPP with Freeswitch below command needs to be run. (Steps will be improved later)
1. make resolve_dep (It will prompt you many times. So, please be here with installation process)
2. make install_freeswitch_conf
3. make install_astpp
3. Start Services
1. Apache
2. Mysql
3. Freeswitch
4. Setup MySQL For ASTPP
* Set Root Password
mysqladmin -u root password 'SET YOUR PASSWORD'
* Create astpp, fs(Freeswitch Database) and fscdr(Freeswitch CDR DB) databases
* Create new mysql for above databases
GRANT ALL PRIVILEGES ON astpp.* TO astppuser@localhost IDENTIFIED BY 'SET YOUR PASSWORD';
GRANT ALL PRIVILEGES ON fs.* TO astppuser@localhost IDENTIFIED BY 'SET YOUR PASSWORD';
GRANT ALL PRIVILEGES ON fscdr.* TO astppuser@localhost IDENTIFIED BY 'SET YOUR PASSWORD';
flush privileges;
5. Install ASTPP Database
cd <ASTPP SOURCE DIR>/sql
./install.sh
Enter appropriate values in prompt
6. Setup database credential in /var/lib/astpp/astpp-config.conf
You are done with GUI installation. Enjoy :)
Visit the astpp admin page in your web browser. It can be found here: http://server_ip/cgi-bin/astpp-admin/astpp-admin.cgi Please change the ip address depending upon your box. The default password is " Passw0rd! ". you do not need to enter username.
Note : In case of any issue please refer apache error log.
7. ASTPP Freeswitch Configuration
cd <ASTPP SOURCE DIR>/freeswitch/conf
cp 02_astpp_callingcards.xml /usr/local/freeswitch/conf/dialplan/default/
Note : Edit 02_astpp_callingcards.xml file to change acccess number for calling card.
cp cdr_csv.conf.xml /usr/local/freeswitch/conf/autoload_configs/
cp 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 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.
Enable mod_xml_curl, mod_xml_cdr, mod_cdr_csv, mod_perl in /usr/local/freeswitch/conf/autoload_configs/modules.conf.xml file.
Once above setting are done, restart freeswitch and check if above modules are loaded or not. If not then please load it manually.
8. Setup Cron
Add these lines to cron:
@hourly /usr/local/astpp/astpp-update-balance.pl
@daily /usr/local/astpp/astpp-update-balance.pl sweep=0
0 0 * * 0 /usr/local/astpp/astpp-update-balance.pl sweep=1
0 0 1 * * /usr/local/astpp/astpp-update-balance.pl sweep=2
0 0 1 1,4,7,10 * /usr/local/astpp/astpp-update-balance.pl sweep=3
0 0 * 1,7 * /usr/local/astpp/astpp-update-balance.pl sweep=4
0 0 * 1 * /usr/local/astpp/astpp-update-balance.pl sweep=5
@daily /usr/local/astpp/astpp-rate-engine.pl runtype=sweep
@daily /usr/local/astpp/astpp-generate-invoices.pl sweep=0
0 0 * * 0 /usr/local/astpp/astpp-generate-invoices.pl sweep=1
0 0 1 * * /usr/local/astpp/astpp-generate-invoices.pl sweep=2
0 0 1 1,4,7,10 * /usr/local/astpp/astpp-generate-invoices.pl sweep=3
0 0 * 1,7 * /usr/local/astpp/astpp-generate-invoices.pl sweep=4
0 0 * 1 * /usr/local/astpp/astpp-generate-invoices.pl sweep=5
Manually install the script to rotate the cdrs.
cp <ASTPP SOURCE DIR>/freeswitch/contrib/wasim/cdrload.pl /usr/local/astpp
Then add the following line to crontab,
* * * * * /usr/local/astpp/cdrload.pl
9. If you want your logo on the pages put it in a file called logo.jpg in your webservers _astpp directory.
ASTPP Support :
Please email us at [email protected] for support.
ASTPP Forums :
http://astpp.org/index.php/forum/index
Refer astpp.org for more information.
---------------------------------------------------------------------------------------------------------------------------------------------------------------
----- Enjoy :) -------
---------------------------------------------------------------------------------------------------------------------------------------------------------------