Docsright arrowTelepresenceright arrow2.3right arrowRunning Telepresence inside a container

2 min • read

Running Telepresence inside a container

It is sometimes desirable to run Telepresence inside a container. One reason can be to avoid any side effects on the workstation's network, another can be to establish multiple sessions with the traffic manager, or even work with different clusters simultaneously.

Building the container

Building a container with a ready-to-run Telepresence is easy because there are relatively few external dependencies. Add the following to a Dockerfile:

In order to build the container, do this in the same directory as the Dockerfile:

Running the container

Telepresence will need access to the /dev/net/tun device on your Linux host (or, in case the host isn't Linux, the Linux VM that Docker starts automatically), and a Kubernetes config that identifies the cluster. It will also need --cap-add=NET_ADMIN to create its Virtual Network Interface.

The command to run the container can look like this: