Merge pull request #1 from Rhizomatica/ciaby/rtp-bridge

Ciaby/rtp bridge
This commit is contained in:
ciaby 2015-09-23 22:23:05 +02:00
commit 9f7214b2ff
8 changed files with 59 additions and 19 deletions

@ -1 +1 @@
Subproject commit 09967704c152f5fd044ed4ddbc7382ef2e24aea5
Subproject commit eb52429dbf78778a4871169571a744bff44a6287

View file

@ -91,9 +91,9 @@
<param name="outbound-codec-prefs" value="$${global_codec_prefs}"/>
<param name="rtp-timer-name" value="soft"/>
<!-- ip address to use for rtp, DO NOT USE HOSTNAMES ONLY IP ADDRESSES -->
<param name="rtp-ip" value="127.0.0.1"/>
<param name="rtp-ip" value="172.16.0.1"/>
<!-- ip address to bind to, DO NOT USE HOSTNAMES ONLY IP ADDRESSES -->
<param name="sip-ip" value="127.0.0.1"/>
<param name="sip-ip" value="172.16.0.1"/>
<!--<param name="hold-music" value="$${hold_music}"/>-->
<param name="apply-nat-acl" value="nat.auto"/>
@ -272,8 +272,8 @@
auto - Use guessed ip.
auto-nat - Use ip learned from NAT-PMP or UPNP
-->
<param name="ext-rtp-ip" value="auto-nat"/>
<param name="ext-sip-ip" value="auto-nat"/>
<param name="ext-rtp-ip" value="172.16.0.1"/>
<param name="ext-sip-ip" value="172.16.0.1"/>
<!-- rtp inactivity timeout -->
<param name="rtp-timeout-sec" value="300"/>

View file

@ -1,2 +1,2 @@
#!/bin/sh
/usr/sbin/lcr start
exec /usr/sbin/lcr start

View file

@ -3,15 +3,15 @@ gsm-bs
tones yes
earlyb no
# These two lines enable RTP bridging
#bridge Ext
#rtp-bridge
bridge Ext
rtp-bridge
[Ext]
#sip <local ip>[:<local port>] <remote ip>[:<remote port>]
sip 127.0.0.1:5050 127.0.0.1:5060
sip 172.16.0.1:5050 172.16.0.1:5060
earlyb yes
tones yes
extern
# These two lines enable RTP bridging
#bridge gsm
#rtp-bridge
bridge gsm
rtp-bridge

View file

@ -154,7 +154,7 @@ class rhizo_base {
ensure => present,
provider => git,
source => 'https://github.com/Rhizomatica/rccn.git',
revision => '1.0.5',
revision => '1.0.5-rtp',
require => [ File['/var/rhizomatica'], Package['git'] ],
notify => [ Exec['locale-gen'],
Exec['restart-freeswitch'],

View file

@ -12,8 +12,14 @@
#
class rhizo_base::lcr {
package { 'lcr':
ensure => installed,
ensure => latest,
require => Class['rhizo_base::apt'],
notify => Exec['restart-lcr'],
}
exec { 'restart-lcr':
command => '/usr/bin/sv restart lcr',
refreshonly => true,
}
service { 'lcr':

View file

@ -24,16 +24,35 @@ class rhizo_base::openbsc {
$bts3_ip_address = $rhizo_base::bts3_ip_address
$smsc_password = $rhizo_base::smsc_password
package { ['osmocom-nitb', 'osmocom-nitb-dbg',
'libdbd-sqlite3', 'libsmpp0']:
ensure => installed,
package { [ 'libosmoabis4', 'libosmocore6',
'libosmoctrl0', 'libosmogsm5',
'libosmovty1', 'osmocom-nitb',
'osmocom-nitb-dbg']:
ensure => latest,
require => Class['rhizo_base::apt'],
notify => Exec['hlr_pragma_wal'],
notify => [ Exec['hlr_pragma_wal'],
Exec['restart-nitb'] ],
}
package { [ 'libosmoabis3', 'libosmocore4',
'libosmogsm6', 'libosmovty0',
'libgtp', 'libgtp0',
'libgtp0-dev', 'openggsn',
'libosmo-abis', 'libosmo-abis-dbg',
'libosmo-abis-dev', 'libosmo-netif-dbg',
'libosmo-netif-dev', 'libosmo-sccp',
'libosmo-sccp-dbg', 'libosmo-sccp-dev',
'libosmocodec0', 'libosmocore',
'libosmocore-dbg', 'libosmocore-dev',
'libosmocore-utils', 'libosmogb3',
'libosmonetif2', 'libosmosim0',
'libosmotrau0']:
ensure => purged,
}
service { 'osmocom-nitb':
enable => false,
require => Package['osmocom-nitb']
require => Package['osmocom-nitb'],
}
file { '/etc/osmocom/osmo-nitb.cfg':
@ -47,4 +66,11 @@ class rhizo_base::openbsc {
require => Class['rhizo_base::packages'],
refreshonly => true,
}
exec { 'restart-nitb':
command => '/usr/bin/sv restart osmo-nitb',
require => Class['rhizo_base::packages'],
refreshonly => true,
}
}

View file

@ -6,6 +6,7 @@ password foo
log stderr
logging filter all 1
logging color 1
logging print category 0
logging timestamp 0
logging level all notice
logging level rll notice
@ -31,6 +32,7 @@ log stderr
logging level nat notice
logging level ctrl notice
logging level smpp notice
logging level filter notice
logging level lglobal notice
logging level llapd notice
logging level linp notice
@ -38,6 +40,8 @@ log stderr
logging level lmi notice
logging level lmib notice
logging level lsms notice
logging level lctrl notice
logging level lgtp notice
!
line vty
no login
@ -404,9 +408,13 @@ network
mncc-int
default-codec tch-f fr
default-codec tch-h hr
nitb
subscriber-create-on-demand
no assign-tmsi
smpp
local-tcp-port 2775
policy closed
smpp-first
esme OSMPP
password <%= @smsc_password %>
default-route