I started putting something together to get a FreePBX box up and running on Centos 7 using NAF’s gvsip branch of asterisk. Much of which was obtained and hacked together from others’ talent. Feel free to give that a try.
If virtualbox/vagrant are tools you are familiar with: (had to update link because forum wouldn’t allow me to post)
git clone https(colon)(slashes)github(dot)com(slash)jamiekowalczik(slash)asterisk-freepbx-gvsip(dot)git
cd asterisk-freepbx-gvsip/
vagrant up
When the box is all setup you will need to create /etc/asterisk/pjsip_custom.conf with your info.
If you already have a base centos 7 install and prefer not to use vagrant then the following ‘should’ work.
Preface: Alpha stage - do not do this on a functional box…
bash <(curl -s https(colon)(slashes)raw(dot)githubusercontent(dot)com(slash)jamiekowalczik(slash)asterisk-freepbx-gvsip(slash)master(slash)provision(slash)install(dot)bash)
The pre-requisite for that command is to have the 4 values needed for each google voice number (number, client_id, client_secret, refresh_token). The script will pause and ask you to set that up at which point you will open up another SSH connection to update the file with your text editor of choice - when complete press enter and the script will finish off the install. If you don’t have the values and just want to test out the install then press enter and use find/replace to put them in pjsip_custom.conf later on.
The file you will be asked to update is ./asterisk-freepbx/provision/freepbx-gvsip-el7.yml.
Near the top of the file you will see the following lines. Replace the 4 values surrounded by single quotes then save the file.
gvsip:
- { number: '1112223333', oauth_clientid: 'asdf(dot)apps(dot)googleusercontent(dot)com', oauth_secret: 'XXXXXX', refresh_token: 'asdfasdf' }
- { number: '1112223334', oauth_clientid: 'asdg(dot)apps(dot)googleusercontent(dot)com', oauth_secret: 'XXXXXY', refresh_token: 'asdfasdg' }
As noted - the code is ‘strange’. The project started out to be a way to deploy using vagrant and ansible but a previous co-worker had a centos7 install on a physical machine that he wanted to test naf’s gvsip on so that bash script mentioned in the provision folder will setup ansible on the centos7 host, pull down the ansible playbook, and install asterisk and freepbx using the playbook with one command. This is for a hobbiest install at best… Please feel free to clone to make more efficient and keep me posted on any developments. I will make my way to IRC some night - getting late for me.