Skip to content

Instantly share code, notes, and snippets.

@hamidrhashmi
Created June 21, 2024 07:58
Show Gist options
  • Save hamidrhashmi/ef7ca35e395c1fabfd1ba66397a2d0dc to your computer and use it in GitHub Desktop.
Save hamidrhashmi/ef7ca35e395c1fabfd1ba66397a2d0dc to your computer and use it in GitHub Desktop.
Free Call Center Solution for SMEs

STEP 1: Domain

If you are configuring GoAUtoDial on amchine with Private Ip or LAN IP. Then Set domain it etc/hosts

vim /etc/hosts

machine IP and domain For Example

192.168.0.111 goautodial.hbvoice.local

STEP 2: Generate License.

Go to this link to create Self Signed Certs After creating self-signed certs execute the following commands

cp server.key /etc/pki/tls/private/
cp server.crt /etc/pki/tls/certs/
cp rootCA.crt /etc/pki/ca-trust/source/anchors/HBVOICE.crt
update-ca-trust

STEP 3: Follow GoAUtodial Wiki

Update all package to the latest avaible versions.

yum update -y
yum install -y nano wget
yum groupinstall -y "Development Tools" 

Install the Goautodial yum repository

cd /etc/yum.repos.d/
wget http://downloads2.goautodial.org/centos/7/goautodial.repo

Install MariaDB 10 PHP 7, Asterisk 13, Kamailio 5, RTPengine and other dependencies

yum install MariaDB-server MariaDB-devel php70w-mysql php70w-mcrypt php70w-devel php70w-mbstring php70w-common php70w-xml php70w-pear php70w-cli php70w-imap php70w-fpm php70w-gd php70w-opcache php70w-pdo php70w-process php70w php70w-intl php70w-pear.noarch php70w-xmlrpc asterisk-mysql-13.17.2-vici.el7.centos.x86_64 asterisk-perl-0.08-2.go.x86_64 asterisk-voicemail-plain-13.17.2-vici.el7.centos.x86_64 asterisk-devel-13.17.2-vici.el7.centos.x86_64 asterisk-voicemail-13.17.2-vici.el7.centos.x86_64 asterisk-alsa-13.17.2-vici.el7.centos.x86_64 asterisk-sip-13.17.2-vici.el7.centos.x86_64 asterisk-13.17.2-vici.el7.centos.x86_64 asterisk-dahdi-13.17.2-vici.el7.centos.x86_64 asterisk-iax2-13.17.2-vici.el7.centos.x86_64 asterisk-mp3-13.17.2-vici.el7.centos.x86_64 kamailio-tls kamailio kamailio-mysql kamailio-ims kamailio-utils kamailio-websocket  kamailio-json perl-Math-Round perl-Net-Server perl-File-Touch perl-Sys-RunAlone perl-Switch perl-Time-Local ngcp-rtpengine ngcp-rtpengine-kernel ngcp-rtpengine-dkms dkms dahdi-linux dahdi-linux-devel kernel-devel perl-Crypt-Eksblowfish perl-DBI perl-DBD-mysql perl-Net-Telnet lame httpd mod_ssl screen crontabs mailx net-tools glibc.i686

Start Mysql

systemctl start mysql
systemctl status mysql
mysql -u root -p

Enable EPEL repository

yum install -y epel-release
yum install perl-Crypt-Eksblowfish perl-Sys-RunAlone

Edit /etc/yum.repos.d/epel.repo

nano /etc/yum.repos.d/epel.repo

Append to the bottom of [epel] entries:

exclude=dahdi-tools*

Or if EPEL repo is not enabled:

Edit /etc/yum.conf

nano /etc/yum.conf

Append to the bottom:

exclude=dahdi-tools*

Note

there's an asterisk (*) at the end of the line above. It's not a typo error.

This will avoid dahdi-tools package conflict with the EPEL repo.

yum update

Enable at system startup and start the service

systemctl status php-fpm
systemctl start php-fpm
systemctl status php-fpm
systemctl status httpd
systemctl start httpd
systemctl status httpd
systemctl status mariadb
systemctl status kamailio
systemctl status kamailio
systemctl status ngcp-rtpengine
systemctl enable php-fpm
systemctl enable httpd
systemctl enable mariadb
systemctl enable kamailio
systemctl enable ngcp-rtpengine

Disable firewalld (IMPORTANT!)

systemctl stop firewalld
systemctl disable firewalld

We're using Iptables (customize /etc/sysconfig/iptables if needed)

Create missing Kamailio runtime directory
mkdir /var/run/kamailio
chown kamailio /var/run/kamailio
Install GOautodial
yum -y install goautodial-ce
cd /usr/src/goautodial
./install.sh
Install CPAN
yum install -y cpan
cpan install Net::Server
cpan install Asterisk::AGI

Configure RTPengine

vim /etc/rtpengine/rtpengine.conf

Change 123.234.345.456 to your public IP address

### a single interface:
interface = 123.234.345.456

:%s/123.234.345.456/192.168.0.111/g

Configure Kamailio
vim /etc/kamailio/kamailio.cfg
Change 10.10.100.19 to your public IP address
:%s/10.10.100.19/192.168.0.111/g
:%s/vaglxc01.goautodial.com/demo.hbvoice.local/g

/* add local domain aliases */
alias="10.10.100.19" 
#!substdef "!MY_IP_ADDR!10.10.100.19!g" 
listen=udp:10.10.100.19:5060

Change TLSv1 to TLSv1+ (add the plus sign)

vim /etc/kamailio/tls.cfg

[server:default]
method = TLSv1
Should be:

[server:default]
method = TLSv1+

:%s/localhost/server/g

Crontab Entries Check if the entry is applied.

crontab -l

If its blank run command and apply entries below

crontab -e

Cron Jobs

### recording mixing/compressing/ftping scripts
0,3,6,9,12,15,18,21,24,27,30,33,36,39,42,45,48,51,54,57 * * * * /usr/share/astguiclient/AST_CRON_audio_1_move_mix.pl
#0,3,6,9,12,15,18,21,24,27,30,33,36,39,42,45,48,51,54,57 * * * * /usr/share/astguiclient/AST_CRON_audio_1_move_mix.pl --MIX
#0,3,6,9,12,15,18,21,24,27,30,33,36,39,42,45,48,51,54,57 * * * * /usr/share/astguiclient/AST_CRON_audio_1_move_VDonly.pl
1,4,7,10,13,16,19,22,25,28,31,34,37,40,43,46,49,52,55,58 * * * * /usr/share/astguiclient/AST_CRON_audio_2_compress.pl --MP3
#2,5,8,11,14,17,20,23,26,29,32,35,38,41,44,47,50,53,56,59 * * * * /usr/share/astguiclient/AST_CRON_audio_3_ftp.pl --MP3

### keepalive script for astguiclient processes
* * * * * /usr/share/astguiclient/ADMIN_keepalive_ALL.pl

### kill Hangup script for Asterisk updaters
* * * * * /usr/share/astguiclient/AST_manager_kill_hung_congested.pl

### updater for voicemail
* * * * * /usr/share/astguiclient/AST_vm_update.pl

### updater for conference validator
* * * * * /usr/share/astguiclient/AST_conf_update.pl

### flush queue DB table every hour for entries older than 1 hour
11 * * * * /usr/share/astguiclient/AST_flush_DBqueue.pl -q

### fix the vicidial_agent_log once every hour and the full day run at night
33 * * * * /usr/share/astguiclient/AST_cleanup_agent_log.pl
50 0 * * * /usr/share/astguiclient/AST_cleanup_agent_log.pl --last-24hours

### updater for VICIDIAL hopper
* * * * * /usr/share/astguiclient/AST_VDhopper.pl -q

### adjust the GMT offset for the leads in the vicidial_list table
1 1 * * * /usr/share/astguiclient/ADMIN_adjust_GMTnow_on_leads.pl --debug

### reset several temporary-info tables in the database
2 1 * * * /usr/share/astguiclient/AST_reset_mysql_vars.pl

### optimize the database tables within the asterisk database
3 1 * * * /usr/share/astguiclient/AST_DB_optimize.pl

## adjust time on the server with ntp
30 * * * * /usr/sbin/ntpdate -u pool.ntp.org 2>/dev/null 1>&2

### VICIDIAL agent time log weekly and daily summary report generation
#2 0 * * 0 /usr/share/astguiclient/AST_agent_week.pl
#22 0 * * * /usr/share/astguiclient/AST_agent_day.pl

### VICIDIAL campaign export scripts (OPTIONAL)
#32 0 * * * /usr/share/astguiclient/AST_VDsales_export.pl
#42 0 * * * /usr/share/astguiclient/AST_sourceID_summary_export.pl

### remove old ORIG recordings more than 2 days old
24 0 * * * /usr/bin/find /var/spool/asterisk/monitorDONE/ORIG/ -maxdepth 2 -type f -mtime +2 -print | xargs rm -f

### remove all recordings more than 6 months old
30 0 * * * /usr/bin/find /var/spool/asterisk/monitorDONE/ -maxdepth 2 -type f -mtime +180 -print | xargs rm -f

### roll logs monthly on high-volume dialing systems
#30 1 1 * * /usr/share/astguiclient/ADMIN_archive_log_tables.pl

### remove old vicidial logs and asterisk logs more than 2 days old
28 0 * * * /usr/bin/find /var/log/astguiclient -maxdepth 1 -type f -mtime +2 -print | xargs rm -f
29 0 * * * /usr/bin/find /var/log/asterisk -maxdepth 3 -type f -mtime +2 -print | xargs rm -f
30 0 * * * /usr/bin/find / -maxdepth 1 -name "screenlog.0*" -mtime +4 -print | xargs rm -f

Reboot your server (very important!)

reboot

Update GOautodial web application

cd /var/www/html
git config --global user.email "root@localhost" 
git stash
git pull
cd /var/www/html/goAPIv2
git stash
git pull

Check HOWTO Update Latest Version via Github for updated instructions Access your GOautodial application (Google Chrome is recommended)

https://IPADDRESS User: goadmin Pass: G0autodial2018

Notes Kamailio default port 5060/UDP Asterisk default port 5070/UDP

https://goautodial.org/projects/goautodialce/wiki/Version_4_How_To_Install_Goautodial_From_Scratch_using_CentOS_7X

ls -lhtr /usr/share/astguiclient/
vim /etc/astguiclient.conf

dsaadsa

grep vaglxc01.goautodial.com * -r
php/CRMDefaults.php:define ('BASE_URL', 'https://vaglxc01.goautodial.com');
[root@goautodial html]# vim php/CRMDefaults.php


cd /etc/httpd/
vim conf.d/ssl.conf
systemctl restart httpds
systemctl restart httpd
systemctl status httpd


grep 192.168.0.111 * -r
php/goCRMAPISettings.php:define ('gourl', 'https://192.168.0.111/goAPIv2');

cd /usr/src/ngcp-rtpengine-6.4.0.0-1.el7/
make
cp -fr xt_RTPENGINE.ko /lib/modules/`uname -r`/extra/xt_RTPENGINE.ko
depmod -a
modprobe -v xt_RTPENGINE
lsmod | grep xt_RTPENGINE

https://blog.kolmisoft.com/rtpengine-install-on-centos-7/

firewall-cmd --zone=public --add-port={443/tcp,5060/tcp,5060/udp,10000-20000/udp,4443/tcp,9080/tcp,8080/tcp,5061/tcp,5070/udp,5038/tcp}

change /etc/asterisk/sip-visdial.conf disable WITH_AUTH in kamailio.cfg There would be an error in kamailio.cfg disable auth functions in MSRP section.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment