Você não pode selecionar mais de 25 tópicos Os tópicos devem começar com uma letra ou um número, podem incluir traços ('-') e podem ter até 35 caracteres.

build_docker_image.mdx 2.2KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. ---
  2. sidebar_position: 1
  3. slug: /build_docker_image
  4. ---
  5. # Build a RAGFlow Docker Image
  6. import Tabs from '@theme/Tabs';
  7. import TabItem from '@theme/TabItem';
  8. A guide explaining how to build a RAGFlow Docker image from its source code. By following this guide, you'll be able to create a local Docker image that can be used for development, debugging, or testing purposes.
  9. ## Target Audience
  10. - Developers who have added new features or modified the existing code and require a Docker image to view and debug their changes.
  11. - Testers looking to explore the latest features of RAGFlow in a Docker image.
  12. ## Prerequisites
  13. - CPU ≥ 4 cores
  14. - RAM ≥ 16 GB
  15. - Disk ≥ 50 GB
  16. - Docker ≥ 24.0.0 & Docker Compose ≥ v2.26.1
  17. ## Build a Docker image
  18. <Tabs
  19. defaultValue="without"
  20. values={[
  21. {label: 'Build a Docker image without embedding models', value: 'without'},
  22. {label: 'Build a Docker image including embedding models', value: 'including'}
  23. ]}>
  24. <TabItem value="without">
  25. This image is approximately 2 GB in size and relies on external LLM and embedding services.
  26. :::tip NOTE
  27. While we also test RAGFlow on ARM64 platforms, we do not plan to maintain RAGFlow Docker images for ARM. However, you can build an image yourself on a `linux/arm64` or `darwin/arm64` host machine as well.
  28. :::
  29. ```bash
  30. git clone https://github.com/infiniflow/ragflow.git
  31. cd ragflow/
  32. docker build --build-arg LIGHTEN=1 -f Dockerfile -t infiniflow/ragflow:nightly-slim .
  33. ```
  34. </TabItem>
  35. <TabItem value="including">
  36. This image is approximately 9 GB in size. As it includes embedding models, it relies on external LLM services only.
  37. :::tip NOTE
  38. While we also test RAGFlow on ARM64 platforms, we do not plan to maintain RAGFlow Docker images for ARM. However, you can build an image yourself on a `linux/arm64` or `darwin/arm64` host machine.
  39. :::
  40. ```bash
  41. git clone https://github.com/infiniflow/ragflow.git
  42. cd ragflow/
  43. pip3 install huggingface_hub nltk
  44. python3 download_deps.py
  45. docker build -f Dockerfile.deps -t infiniflow/ragflow_deps .
  46. docker build -f Dockerfile -t infiniflow/ragflow:nightly .
  47. docker build --build-arg LIGHTEN=1 -f Dockerfile -t infiniflow/ragflow:nightly-slim .
  48. ```
  49. </TabItem>
  50. </Tabs>