Skip to content

Commit c87c2af

Browse files
committed
building image locally added
1 parent 14300dd commit c87c2af

File tree

1 file changed

+19
-5
lines changed

1 file changed

+19
-5
lines changed

scripts/Docker/readme.md

Lines changed: 19 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,47 +13,61 @@ https://www.digitalocean.com/community/tutorials/how-to-install-and-use-docker-o
1313
- Support scripts for building and running the image are also included
1414
Add python version, openGL?, self info to be printed
1515

16-
## Getting librealsense docker
16+
# Getting librealsense docker - pre-built
1717

1818
As long as the repo is private, login is needed:
1919
1. add the password in some password.txt file
20-
2. run: cat password.txt | docker login –username=“…” –password-stdin
20+
2. run:
21+
```
22+
cat password.txt | docker login –username=“…” –password-stdin
23+
```
2124

2225
Then run the command:
26+
```
2327
docker pull librealsense/librealsense
28+
```
2429

2530
## Running the Container
2631
Now running the command: docker images, the docker librealsense/librealsense should appear.
2732

2833
### Default Command
2934
Then run the container with default command:
30-
35+
```
3136
docker run -it --rm \
3237
-v /dev:/dev \
3338
--device-cgroup-rule "c 81:* rmw" \
3439
--device-cgroup-rule "c 189:* rmw" \
3540
librealsense/librealsense
41+
```
3642

3743
The default command that will run is: rs-enumerate-devices --compact
3844

3945
### Custom Command
4046
In order to run another command, one can run for example:
41-
47+
```
4248
docker run -it --rm \
4349
-v /dev:/dev \
4450
--device-cgroup-rule "c 81:* rmw" \
4551
--device-cgroup-rule "c 189:* rmw" \
4652
librealsense/librealsense rs-depth
53+
```
4754

4855
### Running shell
4956
Or, in order to open bash inside the container:
50-
57+
```
5158
docker run -it --rm \
5259
-v /dev:/dev \
5360
--device-cgroup-rule "c 81:* rmw" \
5461
--device-cgroup-rule "c 189:* rmw" \
5562
librealsense/librealsense /bin/bash
63+
```
64+
65+
# Building librealsense docker image
66+
67+
The librealsense's docker image can be built locally using the [Dockerfile](Dockerfile).
68+
This is done by running the [image building script](build_image.sh).
5669

70+
Then, running the container is done as described [above](#Running-the-Container) .
5771

5872

5973

0 commit comments

Comments
 (0)