Skip to content

oshirohugo/opencv-python-dev-dockerfile

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 

Repository files navigation

OpenCV 2.x Dockerfile for development

Building

To build the image just run:

$ docker build . -t <image-name>

Running container

To run it you have to adjust the permission to the X server host. So run the following command in the docker host machine:

$ xhost +local:root

This is a lazy workaround to permit connection from the container, and it can be improved as explained here.

After that you can run your docker container:

$ docker run -it \
    --env="DISPLAY" \
    --env="QT_X11_NO_MITSHM=1" \
    --volume="/tmp/.X11-unix:/tmp/.X11-unix:rw" \
    --volume="<local-dev-dir>:/root" \
    --device /dev/video0 \
    <image-name>

Note that we map the host camera divice to be used by docker container.

When you finish, disable permission to connect to your X server host:

$ xhost -local:root

About

Dockerfile describing image to developing using opencv 2.9.x

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published