Developing OpenVidu

This documentation is suitable for Ubuntu 14.04 or Ubuntu 16.04. Packages required:

Dependecy Check version Install
java 8 JDK java -version sudo apt-get install -y default-jdk
node node -v sudo curl -sL | sudo bash -
sudo apt-get install -y nodejs
maven mvn -v sudo apt-get install -y maven
angular-cli ng -v sudo npm install -g @angular/cli

Setup for development

Here we show how to develop an Angular app (openvidu-testapp) with openvidu-browser and openvidu-server as local dependencies, waiting to be modified as you want.

1) Install KMS

2) Add Kurento parent Maven dependency to your local repo

3) Clone repo:

git clone

4) openvidu/openvidu-browser/

npm install
npm run updatetsc
sudo npm link

5) openvidu/

mvn -DskipTests=true compile && mvn -DskipTests=true install

6) openvidu/openvidu-testapp/

npm install
npm link openvidu-browser
ng serve

7) Start KMS in your machine:

sudo service kurento-media-server-6.0 restart

8) openvidu/openvidu-server/

mvn exec:java

(or if you prefer you can just run the Java application in your favourite IDE)

At these point, you can start modifying openvidu-ng-testapp, openvidu-browser or openvidu-server.

  • openvidu-testapp : the previous "ng serve" command will take care of refreshing the browser's page whenever any change takes place.

  • openvidu-browser : after modifying any typescript file, you will need to run the following command to update your changes:


    npm run updatetsc

  • openvidu-server : after modifying any file, there is no other alternative but to re-launch the java application if you want to update your changes.


    mvn clean exec:java

    (or re-launch the Java application in your IDE. Some IDE's support automatic re-launch in response to changes)

Setup for advanced development: share the app through your network

You can also use different machines in the same network to build a more advanced development environment, so you can test the application in different devices at the same time. It's very similar to the process outlined above:

You will need a server for the built app (if you don't have any, we recommend http-server): npm install -g http-server

Run exactly the same commands as the process above, but on step 6) skip ng serve. We don't want Angular-CLI to serve our app. Instead, these commands will be the ones which you should launch (and relaunch to update your changes):


ng build -op ./dist
cd dist
openssl req -newkey rsa:2048 -new -nodes -x509 -days 3650 -subj '/ Company LTD./C=US' -keyout key.pem -out cert.pem
http-server -S

This builds the Angular project, generate a self-signed certificate (which unfortunately is a mandatory requirement for http-server SSL) and serves the content with http-server.

Finally, to launch the app connect to https://localhost:8080 in the machine running the http-server and to https://[HOST]:8080 in other devices of the same network ([HOST] being the IP of the machine running the http-server).

Installing KMS

How to install and run KMS in your development machine:

Ubuntu 14.04 LTS Trusty (64 bits)

echo "deb trusty kms6" | sudo tee /etc/apt/sources.list.d/kurento.list
wget -O - | sudo apt-key add -
sudo apt-get update
sudo apt-get install -y kurento-media-server-6.0

Ubuntu 16.04 LTS Xenial (64 bits)

echo "deb xenial kms6" | sudo tee /etc/apt/sources.list.d/kurento.list
wget -O - | sudo apt-key add -
sudo apt-get update
sudo apt-get install -y kurento-media-server-6.0

Start and stop the service

sudo service kurento-media-server-6.0 start
sudo service kurento-media-server-6.0 stop

Here you can check Kurento's official documentation.

Adding Kurento parent POM to your local respository

You will need development version of Kurento's parent POM in your local repository in order to compile the development version of openvidu-server. To achieve this, add a file ~/.m2/settings.xml with the following content (if it doesn't exist, create it on that exact path):

<settings xmlns=""


                  <name>Kurento Snapshot Repository</name>
                  <name>Kurento Snapshot Repository</name>