
Installing a TURN server and integrating it with Nextcloud
In this post we will install the TURN service to allow you to use Talk from outside your organization, if we want our users to be able to use video conferencing from the Internet directly. As we know, Talk video calls only work on the same network segment as the server and if we need to access from another network we will need a TURN server.
We base the post on an Ubuntu machine 16.04 installed, Up-to-date and with a static IP address configured. We will install Coturn as a TURN server by simply running:
[SourceCode]sudo apt install coturn[/SourceCode]
We will enable the coturn service to start automatically with:
[SourceCode]sudo sed -i '/TURNSERVER_ENABLED/cTURNSERVER_ENABLED=1’ /etc/default/coturn[/SourceCode]
We edit the configuration file of the TURN service '/etc/turnserver.conf’ and added the following settings, We must take into account to correctly specify the secret and the realm attribute with the fqdn of our server, We can also set the port that interests us.
[SourceCode]listening-port=5349
fingerprint
lt-cred-mech
use-auth-secret
static-auth-secret=mambrusefuelaguerra
realm=turn.openservices.eus
total-quota=100
bps-capacity=0
stale-nonce
no-loopback-peers
no-multicast-peers[/SourceCode]
We restart Coturn…
[SourceCode]sudo systemctl restart coturn[/SourceCode]
And that's it! We should have our server ready and functional! We will create the corresponding public DNS records and redirect the port we indicated from our firewall/router to the TURN server, both UDP and TCP!
On NextCloud, we must specify who our TURN server will be with the FQDN format:PORT followed by the password or secret to authenticate and be able to use the TURN service, in addition to indicating that it uses UDP and TCP. With this and a cake we have already set up our reverse 'nateo service’ for our video conferences or video calls of our users using Nextcloud Talk, A marvilla!!!