GVSIP-NAF-GUI (beta)
UPDATE: Please follow the official Nerd Vittles tutorial now rather than relying on this beta version.
For the pioneers (only), we've got a new GVSIP-NAF implementation specifically tailored to management within the FreePBX GUI. It should work with CentOS/SL 6.9, Ubuntu 18.04, and Raspbian 8, not RASPBX. Works better with Incredible PBX because we know what's been installed.
Translation: You are responsible for creation of Inbound and Outbound Routes to manage your GVSIP trunks, numbered 1-n. The installer will handle creation of the GVSIP trunks themselves. It takes about 10 seconds to add a new GVSIP trunk. You can add as many as you like.
Overview: Running the installer (install-gvsip) the first time will get your Incredible PBX platform up to speed by installing the correct version of OpenSSL for your platform. Then it installs and patches Asterisk
13.21.1 13.22.0 to support GVSIP Google Voice trunks. Finally, it will let you create GVSIP trunks by simply entering a refresh_token and 10-digit phone number for your existing Google Voice trunk. For each trunk, the installer will create the necessary code to support a PJSIP trunk and a GVSIPn Custom Trunk to use for outbound routing. You can run the installer multiple times without worry. The second time you run it, you can install GVSIP trunk #2. The third time, it's GVSIP trunk #3. There's no limit. You can delete existing GVSIP trunks (#1 through #9) by running del-trunk. If you need to delete trunks higher than 9, edit del-trunk and add new sections for the number of trunks you have.
Setup: Once you have added at least one GVSIP trunk, you will need to go into FreePBX with a browser and add an Outbound Route for each of your trunks. Outbound calling with your new trunks will not work until you do this. We recommend dialing prefixes of *41-*49 for outgoing calls, but you can set things up however you like. That's what the GUI is for. Incoming calls to new trunks by default will go to Allison's Demo IVR if you're using Incredible PBX. You should add an Inbound Route for each of your trunks using the 10-digit DID of the GV trunk and specifying a destination for the incoming calls. For non-Incredible PBX users, inbound calls won't be processed until you add an incoming route.
Installation: To get started, login to your Linux CLI as root. Make a backup. Be sure your MySQL root password is set to passw0rd (with a zero) before proceeding. Then...
Code:
cd /root
wget http://incrediblepbx.com/gvsip-naf-gui.tar.gz
tar zxvf gvsip-naf-gui.tar.gz
rm -f gvsip-naf-gui.tar.gz
cd gvsip-naf
./install-gvsip
For instructions on obtaining refresh_tokens for your Google Voice trunks,
go here. For instructions on creating routes,
go here.
Should you ever want to refresh the patched version of Asterisk, copy pjsip_custom.conf to a safe place, delete the contents of pjsip_custom.conf, rerun the installer, and then copy your version of pjsip_custom.conf back to /etc/asterisk and restart Asterisk. That way you won't lose any of your previously configured GVSIP trunks.