docker-compose.yml 906 B

123456789101112131415161718192021222324252627282930313233343536
  1. version: '2.3'
  2. services:
  3. infer:
  4. image: 192.168.31.174:8080/miva/infer:latest
  5. volumes:
  6. - /tmp/.X11-unix:/tmp/.X11-unix
  7. - /dev:/dev
  8. - /usr/share/zoneinfo/Asia/Shanghai:/etc/localtime
  9. - /opt/datas/video:/home/data/video
  10. - $PWD/source/:/opt/MIVA/
  11. - $PWD/data/:/opt/data/
  12. network_mode: "host"
  13. privileged: true
  14. tty: true
  15. environment:
  16. - NVIDIA_VISIBLE_DEVICES=all
  17. - DISPLAY:$DISPLAY
  18. ipc: "host"
  19. pid: "host"
  20. runtime: "nvidia"
  21. depends_on:
  22. - db
  23. command: /bin/bash -c "cp /opt/MIVA/lib/* /usr/local/lib/ && sleep 5 && cd /opt/MIVA && ./start.sh"
  24. db:
  25. image: 192.168.31.174:8080/miva/db:latest
  26. environment:
  27. TZ: Asia/Shanghai
  28. MYSQL_ROOT_PASSWORD: 'sunwin2022'
  29. ports:
  30. - "3306:3306"
  31. volumes:
  32. - $PWD/source/db/:/docker-entrypoint-initdb.d
  33. - /var/lib/mysql:/var/lib/mysql