How to Install Spreed WebRTC Server Using Docker Image
In a previous tutorial, we discussed how to install Spreed WebRTC server on Ubuntu 16.04 using the official PPA. This tutorial is going to show you how to install Spreed WebRTC server on your Linux distribution using Docker image. There are some details in the installation process we need to pay attention to in order to make Spreed work.
Installing Spreed WebRTC Server on Linux Using Docker Image
It doesn’t matter whether you are using Debian, Ubuntu, CentOS, Redhat, SUSE or whatever, as long as your distribution can run docker engine, you can install Spreed WebRTC on it. First, please go to the following pages to see how to install Docker engine on your Linux distribution.
Once you have Docker installed, run the following command to create a directory for Spreed WebRTC and download a
server.conf file to that directory. This file allows you to provide customized parameters to Spreed WebRTC server when running the Docker image.
sudo mkdir /etc/spreed/ cd /etc/spreed/ sudo wget https://raw.githubusercontent.com/strukturag/spreed-webrtc/master/server.conf.in -O server.conf
Then edit the file.
sudo nano server.conf
Find the following line.
listen = 127.0.0.1:8080
Add a semicolon in the beginning to comment it out.
;listen = 127.0.0.1:8080
Save and close the file.
Before running the Spreed WebRTC Docker container, we need to create enough entropy for server secrets generation. we can use
rng-tools to create entropy.
sudo apt install rng-tools sudo yum install rng-tools sudo pacman -S rng-tools
Once installed, run
sudo rngd -r /dev/urandom
Then issue the following command to run the
spreed/webrtc docker image with your
sudo docker run --name my-spreed-webrtc -p 8080:8080 -p 8443:8443 -v /etc/spreed:/etc/spreed -i -t spreed/webrtc -c /etc/spreed/server.conf
Spreed will create a new self signed TLS certificate.
Creating new self signed TLS certificate ... TLS certificate: Certificate: Data: Version: 3 (0x2) Serial Number: 8d:d8:d3:39:a1:49:46:1b Signature Algorithm: ecdsa-with-SHA256 Issuer: CN=spreed-webrtc Validity Not Before: Dec 27 03:07:16 2016 GMT Not After : Dec 25 03:07:16 2026 GMT ... Creating new server secrets ... ... Staring Spreed WebRTC server ... server 2016/12/27 03:07:16 Starting HTTP server on 0.0.0.0:8080 server 2016/12/27 03:07:16 Starting HTTPS server on 0.0.0.0:8443
Now Spreed WebRTC server is listening on port
8080 (http) and port
8443 (https). You can visit Spreed WebRTC via
You need to make browser trust your self-signed certificate, of course.
Now you are in Spreed WebRTC web interface.
To make the Spreed WebRTC run in the background, press
CTRL+C to stop it, then remove the existing container.
sudo docker rm my-spreed-webrtc
Next, start a new container and add
-d flag to the docker run command.
sudo docker run -d --name my-spreed-webrtc -p 8080:8080 -p 8443:8443 -v /etc/spreed:/etc/spreed -i -t spreed/webrtc -c /etc/spreed/server.conf
I hope this tutorial helped you install Spreed WebRTC server using the Docker image. As always, if you found this post useful, then subscribe to our free newsletter. You can also follow us on Google+, Twitter or like our Facebook page.
That is all.
Actually, that is not all. Check out the following tutorial to see how to integrate Spreed.Me with NextCloud.