curl -sSL https://get.docker.com | sh
sudo usermod -aG docker <user>If you plan to clone this repository directly on raspberry, omit this step. However, it is much more comfortable to work with files on some host machine. Therefore, you need to connect your docker client on host machine to docker daemon on raspberry. I found rdocker useful for that.
git clone --recurse-submodules https://github.com/CT-18/networks-dockeror
git clone --recursive https://github.com/CT-18/networks-dockerfor old git versions (before 2.13)
docker build -t <name> .Here, "name" is an image name which we will use later.
docker run --privileged -d -p 1935:1935 --name <name> <image_name>-
--privilegedallows container access camera device. (you can use --device=/dev/<your_camera_name> instead) -
-dmeans detached mode - this command will return to your shell once container is started. To view container output, usedocker logs <name> -
-p 1935:1935exposes rtmp port to the world outside container -
<image_name> is the image name from pervious step. It determines which image to run.
-
<name> is the container name. Use it to manipulate particular container instance: pause, stop, view logs, etc...
Located at rtmp://<raspberry_addr>/rtmp/live