[Freeswitch-users] Bridging/Connecting Freeswitch servers

Frank Carmickle frank at carmickle.com
Wed Dec 2 06:01:55 PST 2009


On Wed, Dec 02, Otis wrote:
> Hello
> 
> I am experimenting with FS and would like to know  how to connect  two 
> independent servers with  user on one beinng able to call users on the 
> other.  Do I set each server to be the gateway of the corresponding one ?

You can if you need them to authenticate to eachother.  You have to decide on what you need.  Do you not want extensions reachable from the public context?  If not then you can do what I do.  

  <extension name="fjc-pbx-inbound">
  <condition field="network_addr" expression="^2001\:470\:1f..\:6..\:.e0\:.1f.\:fe34\:b29d$"/>
    <condition field="destination_number" expression="^(.*)$">
      <action application="transfer" data="$1 xml default"/>
    </condition>
  </extension>

You can certainly put an ipv4 address in instead of the mangled ipv6 that's in this example.

Then create an extension that matches on the extensions on the other machine and bridge them to the correct hostname and port.

If you just want all the extensions reachable from the public context then do something like this in your dialplan/public.xml

  <extension name="the_big_phat_transfer">
    <condition field="destination_number" expression="^(0\d{7}$|^1\d{4}$|^[2-9]{2}\d{2}$)">
      <action application="transfer" data="$1 xml default"/>
    </condition>
  </extension>

There are yet other ways to get this done.
 
HTH
--FC




More information about the FreeSWITCH-users mailing list