docker-compose.yaml 634 B

12345678910111213141516171819202122232425
  1. version: '3.5'
  2. services:
  3. intent:
  4. container_name: ai-slibra-intent
  5. image: tiangolo/gunicorn:latest
  6. #entrypoint: python web.py
  7. restart: always
  8. user: 0:0
  9. environment:
  10. - CUDA_VISIBLE_DEVICES=0
  11. - TZ=Asia/Shanghai # 设置时区
  12. volumes:
  13. - /root/aibot/intent/models:/home/model-server
  14. - /root/aibot/intent/m3e:/home/model-server/m3e
  15. ports:
  16. - "50072:50072"
  17. deploy:
  18. resources:
  19. reservations:
  20. devices:
  21. - driver: nvidia
  22. #count: 1
  23. capabilities: [gpu]
  24. ipc: host
  25. command: ["/bin/sh", "-c", "python web.py"]