With BigBlueButton clusters (with Scalelite & Greenlight) one never knows on which Server the session will be processed. This makes is quite difficult to route SIP-calls to the correct FreeSWITCH instance.
fsconfregger runs on BigBlueButton servers and is listening on FreeSWITCH Eventsocket. When a new conference room is created an external script is executed. The script generates a custom XML snippet which includes the SIP registration information for FreeSWITCH. After the script is finished, FreeSWITCH gets instructed to reload the XML config and starts to register.
In combination with a central SIP Registrar server (like Kamailio or Asterisk) you are now able to route incoming SIP calls to the correct BigBlueButton instance.
After all participants left the Room, the registration is cleaned up.
To have stable conference numbers BBB requires you to set the parameter voiceBridge accordincly when the rooms is created. At the moment Greenlight does not support this. So you are required to adapt it or find another way.
fsconfregger is required to run on the same machine as FreeSWITCH. If you are running multiple BBB servers this means you need one fsconfregger process on every BBB-Server.
You are required to have a properly configured SIP registrar which accepts the Registrations which are generated by the script.
Just adapt the systemd unitfile and the XML Generator script to your needs.
Example steps to build and setup on a BBB node. You propably want to build it once and deploy everything with ansible.
# install golang on ubuntu 16.04
apt install golang-1.10
# get and build fsconfregger
/usr/lib/go-1.10/bin/go get github.com/denzs/fsconfregger
cd ~/go/src/github.com/denzs/fsconfregger
cp ~/go/bin/fsconfregger sofia-generator.sh /usr/local/sbin/
cp fsconfregger.sample /etc/default/fsconfregger
cp fsconfregger.service /etc/systemd/system/
systemctl daemon-reload
systemctl enable fsconfregger
systemctl start fsconfregger
Parameter | Default | Description |
---|---|---|
-eshost | localhost | "FreeSWITCH Event Socket Host (default 'localhost') |
-esport | 8021 | FreeSWITCH Event Socket Port (default 8021) |
-espw | ClueCon | FreeSWITCH Event Socket Password (default 'ClueCon') |
-script | ./sofia-generator.sh | "Path to XML Generator (default ./sofia-generator.sh)") |
When a room is created the script is called with only one parameter:
- the room number
When a room is destroyed the script is called with two parameters:
- room number
- static string: 'del'
See sofia-generator.sh for an example.