You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

docker-compose-base.yml 3.5KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145
  1. services:
  2. es01:
  3. container_name: ragflow-es-01
  4. profiles:
  5. - elasticsearch
  6. image: docker.elastic.co/elasticsearch/elasticsearch:${STACK_VERSION}
  7. volumes:
  8. - esdata01:/usr/share/elasticsearch/data
  9. ports:
  10. - ${ES_PORT}:9200
  11. env_file: .env
  12. environment:
  13. - node.name=es01
  14. - ELASTIC_PASSWORD=${ELASTIC_PASSWORD}
  15. - bootstrap.memory_lock=false
  16. - discovery.type=single-node
  17. - xpack.security.enabled=true
  18. - xpack.security.http.ssl.enabled=false
  19. - xpack.security.transport.ssl.enabled=false
  20. - cluster.routing.allocation.disk.watermark.low=5gb
  21. - cluster.routing.allocation.disk.watermark.high=3gb
  22. - cluster.routing.allocation.disk.watermark.flood_stage=2gb
  23. - TZ=${TIMEZONE}
  24. mem_limit: ${MEM_LIMIT}
  25. ulimits:
  26. memlock:
  27. soft: -1
  28. hard: -1
  29. healthcheck:
  30. test: ["CMD-SHELL", "curl http://localhost:9200"]
  31. interval: 10s
  32. timeout: 10s
  33. retries: 120
  34. networks:
  35. - ragflow
  36. restart: on-failure
  37. infinity:
  38. container_name: ragflow-infinity
  39. profiles:
  40. - infinity
  41. image: infiniflow/infinity:v0.5.2
  42. volumes:
  43. - infinity_data:/var/infinity
  44. - ./infinity_conf.toml:/infinity_conf.toml
  45. command: ["-f", "/infinity_conf.toml"]
  46. ports:
  47. - ${INFINITY_THRIFT_PORT}:23817
  48. - ${INFINITY_HTTP_PORT}:23820
  49. - ${INFINITY_PSQL_PORT}:5432
  50. env_file: .env
  51. environment:
  52. - TZ=${TIMEZONE}
  53. mem_limit: ${MEM_LIMIT}
  54. ulimits:
  55. nofile:
  56. soft: 500000
  57. hard: 500000
  58. networks:
  59. - ragflow
  60. healthcheck:
  61. test: ["CMD", "curl", "http://localhost:23820/admin/node/current"]
  62. interval: 10s
  63. timeout: 10s
  64. retries: 120
  65. restart: on-failure
  66. mysql:
  67. # mysql:5.7 linux/arm64 image is unavailable.
  68. image: mysql:8.0.39
  69. container_name: ragflow-mysql
  70. env_file: .env
  71. environment:
  72. - MYSQL_ROOT_PASSWORD=${MYSQL_PASSWORD}
  73. - TZ=${TIMEZONE}
  74. command:
  75. --max_connections=1000
  76. --character-set-server=utf8mb4
  77. --collation-server=utf8mb4_unicode_ci
  78. --default-authentication-plugin=mysql_native_password
  79. --tls_version="TLSv1.2,TLSv1.3"
  80. --init-file /data/application/init.sql
  81. ports:
  82. - ${MYSQL_PORT}:3306
  83. volumes:
  84. - mysql_data:/var/lib/mysql
  85. - ./init.sql:/data/application/init.sql
  86. networks:
  87. - ragflow
  88. healthcheck:
  89. test: ["CMD", "mysqladmin" ,"ping", "-uroot", "-p${MYSQL_PASSWORD}"]
  90. interval: 10s
  91. timeout: 10s
  92. retries: 3
  93. restart: on-failure
  94. minio:
  95. image: quay.io/minio/minio:RELEASE.2023-12-20T01-00-02Z
  96. container_name: ragflow-minio
  97. command: server --console-address ":9001" /data
  98. ports:
  99. - ${MINIO_PORT}:9000
  100. - ${MINIO_CONSOLE_PORT}:9001
  101. env_file: .env
  102. environment:
  103. - MINIO_ROOT_USER=${MINIO_USER}
  104. - MINIO_ROOT_PASSWORD=${MINIO_PASSWORD}
  105. - TZ=${TIMEZONE}
  106. volumes:
  107. - minio_data:/data
  108. networks:
  109. - ragflow
  110. restart: on-failure
  111. redis:
  112. image: valkey/valkey:8
  113. container_name: ragflow-redis
  114. command: redis-server --requirepass ${REDIS_PASSWORD} --maxmemory 128mb --maxmemory-policy allkeys-lru
  115. env_file: .env
  116. ports:
  117. - ${REDIS_PORT}:6379
  118. volumes:
  119. - redis_data:/data
  120. networks:
  121. - ragflow
  122. restart: on-failure
  123. volumes:
  124. esdata01:
  125. driver: local
  126. infinity_data:
  127. driver: local
  128. mysql_data:
  129. driver: local
  130. minio_data:
  131. driver: local
  132. redis_data:
  133. driver: local
  134. networks:
  135. ragflow:
  136. driver: bridge