Add the following lines to your Dockerfile:
RUN apt-get update
RUN apt-get install ffmpeg libsm6 libxext6 -y
These commands install the cv2 dependencies that are normally present on the local machine, but might be missing in your Docker container causing the issue.