docker
docker copied to clipboard
How can I specify multiple TURN servers
In a regular installation, we can edit turn-stun-servers.xml to include multiple turn servers. Example below. How can we do this with this docker version?
/usr/share/bbb-web/WEB-INF/classes/spring/turn-stun-servers.xml
<?xml version="1.0" encoding="UTF-8"?>
...
<bean id="stun0" class="org.bigbluebutton.web.services.turn.StunServer">
<constructor-arg index="0" value="stun:turn2.example.com"/>
</bean>
<bean id="turn0" class="org.bigbluebutton.web.services.turn.TurnServer">
<constructor-arg index="0" value="c6..."/>
<constructor-arg index="1" value="turns:turn1.example.com:443?transport=tcp"/>
<constructor-arg index="2" value="86400"/>
</bean>
<bean id="turn1" class="org.bigbluebutton.web.services.turn.TurnServer">
<constructor-arg index="0" value="48..."/>
<constructor-arg index="1" value="turns:turn2.example.com:443?transport=tcp"/>
<constructor-arg index="2" value="86400"/>
</bean>
...
bbb-docker/mod/bbb-web/turn-stun-servers.xml
add a second var like;
{{if .Env.TURN_SERVER2 }} <bean id="turn0" class="org.bigbluebutton.web.services.turn.TurnServer"> <constructor-arg index="0" value="{{ .Env.TURN_SECRET2 }}"/> <constructor-arg index="1" value="{{ .Env.TURN_SERVER2 }}"/> <constructor-arg index="2" value="86400"/> </bean> {{end}}
and update ur env file