First time post to this forum… I’m a PHP/MySQL developer. A client doesn’t want to expose their FreePBX machine to the WWW for customers to login and check voicemail, set their away status, etc. I know there is a nice GUI already built into FreePBX for this sort of thing but how can I move that to another server and not expose the actual FreePBX machine?
Thanks in advance,
First welcome to the forum.
You have struck a nerve with me, customers, that implies this is a revenue generating operation, reselling service on a platform that is not designed for this use? If this assumption is wrong then the rest of my post does not matter.
So the client is paying you and you come in and ask how to move an application to another server? Don’t you think that is an awful broad question?
If you look at the code and start the process and have questions you will probably get a warmer response. Most of the variables for the server that the ARI (the interface you are talking about) are defined in an includes. Did you even look at the code before posting.
Now if you really wanted to warm up to the team you could have posted something like this out of the box:
Hi, I am new to the forum and I have a client that has requested I make some changes to FreePBX to support their business model. Since they understand that this community is self supporting and they want to contribute back to the project and code that I develop.
Our goal is to move the ARI interface to a separate server than the server running FreePBX and Asterisk. I have moved the ARI to the new server, setup the database and Asterisk Manager Interface credentials for the new machine and I am having the following problems:
How can I work with the developers to insure that my changes have the best change of being accepted into the main line release?
----- End suggestion
Remember you get more flies with honey than vinegar. Basically what I took from your post was “I want to modify this open source software for my business, I haven’t really looked at it but I was hoping somebody with point me in the right direction.”
Wow… that’s quite a welcome SkykingOH!
Let’s start over shall we?
Hi, I’m new to the forum and I have a client that’s requesting we basically move the ARI module of FreePBX away from their live phone server and migrate it to a new server in the same network. This is a friend of mine who has had a bad experience exposing their production FreePBX box to port 80… they were hacked within 24 hours. So, they asked me if it was possible to move (or create) a “stand alone” version of the user interface component. Prior to talking to my friend I had never seen, connected to, or even heard of FreePBX but he knew I had PHP/MySQL and I told him I’d take a look and see what it would involve.
A little history, Yes… I did take a look at the code behind FreePBX and I saw that there were a lot of variables in the include files… I have done the following to explore the FreePBX system… I hope this helps you understand my position and commitment to learning!
- Setup a FreePBX/Asterisk (2.10) server on Amazon EC2 for testing purposes
- Purchased a SIP Trunk (Bandwidth.com) and a SIP phone (Aastra 6757i)
- Configured a DNS entry for the system
- Tried to map out PHP code
- Identified the variables that point to MySQL Server Address
- Identified the variables that point to the file system locations of Asterisk files
- Found the “Standalone” setting but need to understand more about what that does.
I hope to open a dialog with the forum to learn more about FreePBX, Asterisk, and how I can potentially contribute to the source code. I look forward to hearing/learning from you all.
Ok thanks. As you can see that code is quite old. I am not a programmer but can read (for the most part) and hack at existing code.
The ARI is actually scheduled to be totally rewritten. I have no idea what the standaloe variable does. This code predates FreePBX to the original amportal (7 years ago at least).
Anyway, I can’t see why it would have to write to the local filesystem. That is one area that you need to ask very specific questions and we might learn something.
I am not a big fan of EC2 instances either. The latency is all over the place and audio is inconsistent. The last thing you want in an application that relies on millisecond clock precision (Asterisk).
So I would install the entire FreePBX on machine 2 and then try and get the ARI to connect to the production machine.
This in no way addresses all the security concerns. Unless the phones are behind a VPN or an access list that only allows the customer networks the SIP stack is still wide open.
You may ask why is it a bad idea to use FreePBX in this application? First reason is it does not support multiple tenants. On the technical side it does not support any type of clustering of live failover and on the regulatory side no e911 or CALEA support. Lastly people expect their phones to work so you need an extremely good Internet connection to provide any reasonable grade of service.
Let us know how it goes.