Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug: Docker container - unable to find webcam #5

Open
Saharsh1005 opened this issue Feb 26, 2024 · 0 comments
Open

Bug: Docker container - unable to find webcam #5

Saharsh1005 opened this issue Feb 26, 2024 · 0 comments
Labels
bug Something isn't working good first issue Good for newcomers

Comments

@Saharsh1005
Copy link
Owner

Saharsh1005 commented Feb 26, 2024

Upon running the app from a docker container, the app is unable to find the webcam.

$ docker run -p 5000:5000 human_nod
[ WARN:0@1.352] global cap_v4l.cpp:997 open VIDEOIO(V4L2:/dev/video0): can't open camera by index
[ERROR:0@1.358] global obsensor_uvc_stream_channel.cpp:159 getStreamChannelGroup Camera index out of range
Traceback (most recent call last):
  File "web/app.py", line 42, in <module>
    socketio.run(app, debug=True)
  File "/usr/local/lib/python3.8/site-packages/flask_socketio/__init__.py", line 640, in run
    raise RuntimeError('The Werkzeug web server is not '
RuntimeError: The Werkzeug web server is not designed to run in production. Pass allow_unsafe_werkzeug=True to the run() method to disable this error.

Try: docker run -it --rm --device=/dev/video0 -p 5000:5000 my-flask-app

docker: Error response from daemon: error gathering device information while adding custom device "/dev/video0": no such file or directory.

@Saharsh1005 Saharsh1005 added bug Something isn't working good first issue Good for newcomers labels Feb 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

1 participant