How to – Scratch install the dynportal on CentOs, Rocky, or Alma Linux
This article will go over the steps to Scratch install the dynportal on a scratch CentOs, Rocky or Alma Linux Vicidial box that normally comes with the ISO. I have created the files you need and host them on one of my sites for download.
Step 1 – Download the necessary files
You will need 4 files to get this working on your server that you can download below
yum install -y firewalld
cd /home
wget https://dialer.one/dynportal.zip
wget https://dialer.one/firewall.zip
wget https://dialer.one/aggregate
wget https://dialer.one/VB-firewall
Step 2 – Move and unzip the files
You can copy and paste the following
- mkdir -p /var/www/vhosts/dynportal
- mv /home/dynportal.zip /var/www/vhosts/dynportal/
- mv /home/firewall.zip /etc/firewalld/
- cd /var/www/vhosts/dynportal/
- unzip dynportal.zip
- cd etc/httpd/conf.d/
- mv viciportal-ssl.conf viciportal.conf /etc/httpd/conf.d/
- cd /etc/firewalld/
- unzip -o firewall.zip
- mv /home/aggregate /usr/bin/
- chmod +x /usr/bin/aggregate
- mv /home/VB-firewall /usr/bin/
- chmod +x /usr/bin/VB-firewall
Step 3 – Add your SSL cert to dynportal-ssl.conf and location for redirect is defaults.inc.php
You need to edit your dynportal-ssl.conf file in /etc/httpd/conf.d/
nano /etc/httpd/conf.d/viciportal-ssl.conf
change the location to your SSL cert files
nano /var/www/vhosts/dynportal/inc/defaults.inc.php
Step 4 – add entry to crontab
Add the following lines to the bottom of your crontab by typing: crontab -e
### ViciBox integrated firewall, by default just load the VoIP Black list and reload it every 4 hours
### You can lock everyone out of your server if you set this wrong, so understand what you are doing!!!
@reboot /usr/bin/VB-firewall --whitelist=ViciWhite --dynamic --quiet
* * * * * /usr/bin/VB-firewall --whitelist=ViciWhite --dynamic --quiet --flush
Step 5 – Add ports to firewall and apache
Now use firewall-cmd and open port 446 on the firewall for public zone like such:
firewall-offline-cmd --add-port=446/tcp --zone=public --permanent
And edit the apache conf file to add the port to it:
- nano /etc/httpd/conf/httpd.conf
- Add this line: Listen 446
Step 6 – Restart services
- service firewalld restart
- service httpd restart
- systemctl enable firewalld
That’s it, now go to http://yourdomain.com:446/valid8.php and you should see the following:
kashinc
got this fixed… just add this to the crontab and setup the public interface and reboot
@reboot /usr/bin/VB-firewall –-whitelist=ViciWhite –-dynamic –-quiet
* * * * * /usr/bin/VB-firewall –-whitelist=ViciWhite –-dynamic –-quiet –-flush