Dockerfile.infer 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. # 配置miva推理镜像
  2. # Use L4T base docker
  3. #FROM nvcr.io/nvidia/deepstream-l4t:5.1-21.02-samples
  4. FROM nvcr.io/nvidia/deepstream-l4t:6.0-samples
  5. ARG with_zltoolkit_code=yes
  6. ARG with_opencv_code=yes
  7. # install基础依赖
  8. RUN apt-get update && \
  9. DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends libgstreamer-plugins-base1.0-dev libgstreamer1.0-dev libgstrtspserver-1.0-dev libx11-dev \
  10. build-essential \
  11. cmake \
  12. libmysqlclient-dev \
  13. libssl-dev \
  14. libgoogle-glog-dev \
  15. libgflags-dev
  16. RUN if [ "$with_zltoolkit_code" = "yes" ]; then \
  17. # apt remove ca-certificates && apt install -y --no-install-recommends apt-utils ca-certificates && \
  18. cd /root && git clone https://gitee.com/xia-chu/ZLToolKit.git ZLToolKit && \
  19. cd /root/ZLToolKit && \
  20. sed -i 's/sudo//g' build_for_linux.sh && ./build_for_linux.sh && \
  21. rm -rf /root/ZLToolKit; \
  22. fi
  23. RUN if [ "$with_opencv_code" = "yes" ]; then \
  24. cd /root && git clone -b 4.1.1 https://gitee.com/flay/opencv.git && \
  25. cd /root/opencv && mkdir build && cd /root/opencv/build && \
  26. cmake .. && make -j4 && make install && \
  27. rm -rf /root/opencv; \
  28. fi
  29. WORKDIR /workspace