docker-compose.yml 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674
  1. name: dataops-test
  2. services:
  3. postgres:
  4. image: pgvector/pgvector:pg16
  5. environment:
  6. POSTGRES_DB: dataops
  7. POSTGRES_USER: dataops
  8. POSTGRES_PASSWORD: dataops-test-password
  9. ports:
  10. - "${DATAOPS_POSTGRES_PORT:-15432}:5432"
  11. volumes:
  12. - dataops-test-postgres:/var/lib/postgresql/data
  13. - ./postgres/init:/docker-entrypoint-initdb.d:ro
  14. - ../../database:/dataops-schema:ro
  15. healthcheck:
  16. test: ["CMD-SHELL", "pg_isready -U dataops -d dataops"]
  17. interval: 5s
  18. timeout: 5s
  19. retries: 20
  20. networks:
  21. - dataops-test-net
  22. kestra-db-init:
  23. image: postgres:16-alpine
  24. environment:
  25. PGPASSWORD: dataops-test-password
  26. volumes:
  27. - ./postgres/init/010-kestra-runtime.sql:/opt/dataops/010-kestra-runtime.sql:ro
  28. command:
  29. - psql
  30. - -v
  31. - ON_ERROR_STOP=1
  32. - -h
  33. - postgres
  34. - -U
  35. - dataops
  36. - -d
  37. - postgres
  38. - -f
  39. - /opt/dataops/010-kestra-runtime.sql
  40. depends_on:
  41. postgres:
  42. condition: service_healthy
  43. restart: "no"
  44. networks:
  45. - dataops-test-net
  46. db-role-init:
  47. image: ${DATAOPS_MIGRATOR_IMAGE:-dataops-platform-migrator:local}
  48. build:
  49. context: ../..
  50. dockerfile: deploy/docker/backend.Dockerfile
  51. target: migrator
  52. environment:
  53. DB_ROLE_INIT_DATABASE_URL: postgresql://dataops:dataops-test-password@postgres:5432/dataops
  54. MIGRATION_DATABASE_URL: postgresql://dataops:dataops-test-password@postgres:5432/dataops
  55. DATABASE_URL: postgresql://dataops_app:${DATAOPS_RUNTIME_PASSWORD:-dataops-app-test-password}@postgres:5432/dataops
  56. DATAOPS_MIGRATOR_USER: dataops
  57. DATAOPS_RUNTIME_USER: dataops_app
  58. DATAOPS_RUNTIME_PASSWORD: ${DATAOPS_RUNTIME_PASSWORD:-dataops-app-test-password}
  59. command: ["python", "-m", "app.core.edge_gateway.runtime_roles"]
  60. depends_on:
  61. postgres:
  62. condition: service_healthy
  63. restart: "no"
  64. networks:
  65. - dataops-test-net
  66. db-migrate:
  67. image: ${DATAOPS_MIGRATOR_IMAGE:-dataops-platform-migrator:local}
  68. build:
  69. context: ../..
  70. dockerfile: deploy/docker/backend.Dockerfile
  71. target: migrator
  72. command: ["alembic", "-c", "alembic.ini", "upgrade", "head"]
  73. environment:
  74. MIGRATION_DATABASE_URL: postgresql://dataops:dataops-test-password@postgres:5432/dataops
  75. depends_on:
  76. postgres:
  77. condition: service_healthy
  78. db-role-init:
  79. condition: service_completed_successfully
  80. restart: "no"
  81. networks:
  82. - dataops-test-net
  83. source-postgres:
  84. image: postgres:16-alpine
  85. environment:
  86. POSTGRES_DB: acceptance
  87. POSTGRES_USER: source_reader
  88. POSTGRES_PASSWORD: source-test-password
  89. ports:
  90. - "${SOURCE_POSTGRES_PORT:-25432}:5432"
  91. volumes:
  92. - dataops-test-source-postgres:/var/lib/postgresql/data
  93. - ./datasources/postgres/init.sql:/docker-entrypoint-initdb.d/010-acceptance.sql:ro
  94. healthcheck:
  95. test: ["CMD-SHELL", "pg_isready -U source_reader -d acceptance"]
  96. interval: 5s
  97. timeout: 5s
  98. retries: 20
  99. networks:
  100. - dataops-test-net
  101. source-mysql:
  102. image: mysql:8.4
  103. environment:
  104. MYSQL_DATABASE: acceptance
  105. MYSQL_USER: source_reader
  106. MYSQL_PASSWORD: source-test-password
  107. MYSQL_ROOT_PASSWORD: source-root-test-password
  108. ports:
  109. - "${SOURCE_MYSQL_PORT:-23306}:3306"
  110. volumes:
  111. - dataops-test-source-mysql:/var/lib/mysql
  112. - ./datasources/mysql/init.sql:/docker-entrypoint-initdb.d/010-acceptance.sql:ro
  113. healthcheck:
  114. test:
  115. - CMD-SHELL
  116. - mysqladmin ping -h 127.0.0.1 -u source_reader -psource-test-password --silent
  117. interval: 5s
  118. timeout: 5s
  119. retries: 30
  120. start_period: 20s
  121. networks:
  122. - dataops-test-net
  123. neo4j:
  124. image: neo4j:5.26-community
  125. environment:
  126. NEO4J_AUTH: neo4j/Passw0rd
  127. NEO4J_server_memory_heap_initial__size: 256m
  128. NEO4J_server_memory_heap_max__size: 512m
  129. NEO4J_server_memory_pagecache_size: 256m
  130. ports:
  131. - "${NEO4J_HTTP_PORT:-17474}:7474"
  132. - "${NEO4J_BOLT_PORT:-17687}:7687"
  133. volumes:
  134. - dataops-test-neo4j:/data
  135. healthcheck:
  136. test: ["CMD-SHELL", "cypher-shell -u neo4j -p Passw0rd 'RETURN 1' >/dev/null 2>&1"]
  137. interval: 10s
  138. timeout: 10s
  139. retries: 30
  140. start_period: 20s
  141. networks:
  142. - dataops-test-net
  143. minio:
  144. image: minio/minio:RELEASE.2025-04-22T22-12-26Z
  145. command: server /data --console-address ":9001"
  146. environment:
  147. MINIO_ROOT_USER: dataops-test
  148. MINIO_ROOT_PASSWORD: dataops-test-password
  149. ports:
  150. - "${MINIO_API_PORT:-19000}:9000"
  151. - "${MINIO_CONSOLE_PORT:-19001}:9001"
  152. volumes:
  153. - dataops-test-minio:/data
  154. healthcheck:
  155. test: ["CMD", "curl", "-f", "http://localhost:9000/minio/health/live"]
  156. interval: 5s
  157. timeout: 5s
  158. retries: 20
  159. networks:
  160. - dataops-test-net
  161. minio-init:
  162. image: minio/mc:RELEASE.2025-04-16T18-13-26Z
  163. depends_on:
  164. minio:
  165. condition: service_healthy
  166. entrypoint:
  167. - /bin/sh
  168. - -c
  169. - >-
  170. mc alias set local http://minio:9000 dataops-test dataops-test-password &&
  171. mc mb --ignore-existing local/dataops-bucket
  172. restart: "no"
  173. networks:
  174. - dataops-test-net
  175. n8n:
  176. image: n8nio/n8n:1.100.1
  177. environment:
  178. DB_TYPE: postgresdb
  179. DB_POSTGRESDB_HOST: postgres
  180. DB_POSTGRESDB_PORT: 5432
  181. DB_POSTGRESDB_DATABASE: n8n
  182. DB_POSTGRESDB_USER: dataops
  183. DB_POSTGRESDB_PASSWORD: dataops-test-password
  184. N8N_HOST: localhost
  185. N8N_PORT: 5678
  186. N8N_PROTOCOL: http
  187. N8N_SECURE_COOKIE: "false"
  188. N8N_ENCRYPTION_KEY: dataops-local-test-encryption-key
  189. N8N_ENFORCE_SETTINGS_FILE_PERMISSIONS: "true"
  190. WEBHOOK_URL: http://localhost:15678/
  191. GENERIC_TIMEZONE: Asia/Shanghai
  192. TZ: Asia/Shanghai
  193. ports:
  194. - "${N8N_PORT:-15678}:5678"
  195. volumes:
  196. - dataops-test-n8n:/home/node/.n8n
  197. depends_on:
  198. postgres:
  199. condition: service_healthy
  200. healthcheck:
  201. test: ["CMD-SHELL", "wget --spider -q http://127.0.0.1:5678/healthz"]
  202. interval: 10s
  203. timeout: 5s
  204. retries: 30
  205. start_period: 30s
  206. networks:
  207. - dataops-test-net
  208. kestra:
  209. image: kestra/kestra:v1.3.20
  210. command:
  211. - server
  212. - standalone
  213. - --worker-thread=16
  214. - --config
  215. - /etc/kestra/application.yml
  216. stop_grace_period: 6m
  217. environment:
  218. KESTRA_DB_HOST: postgres
  219. KESTRA_DB_NAME: kestra
  220. KESTRA_DB_USERNAME: kestra_runtime
  221. KESTRA_DB_PASSWORD: kestra-local-test-password
  222. KESTRA_USERNAME: ${KESTRA_USERNAME:-admin@dataops.local}
  223. KESTRA_PASSWORD: ${KESTRA_PASSWORD:-DataOpsKestra1!}
  224. ports:
  225. - "127.0.0.1:${KESTRA_PORT:-18080}:8080"
  226. volumes:
  227. - dataops-test-kestra:/app/storage
  228. - ./kestra/application.yml:/etc/kestra/application.yml:ro
  229. depends_on:
  230. kestra-db-init:
  231. condition: service_completed_successfully
  232. healthcheck:
  233. test: ["CMD-SHELL", "curl -fsS http://127.0.0.1:8081/health"]
  234. interval: 10s
  235. timeout: 5s
  236. retries: 60
  237. start_period: 60s
  238. restart: unless-stopped
  239. networks:
  240. - dataops-test-net
  241. kestra-mcp:
  242. image: ghcr.io/kestra-io/mcp-server-python@sha256:1fd62028f60914af31e244ddb0086ed5017420313e2c8547ea9c01b8d24dfc1d
  243. profiles:
  244. - kestra-mcp
  245. stdin_open: true
  246. environment:
  247. KESTRA_BASE_URL: http://kestra:8080/api/v1
  248. KESTRA_TENANT_ID: main
  249. KESTRA_USERNAME: ${KESTRA_USERNAME:-admin@dataops.local}
  250. KESTRA_PASSWORD: ${KESTRA_PASSWORD:-DataOpsKestra1!}
  251. KESTRA_MCP_DISABLED_TOOLS: ee,files,kv,namespace
  252. KESTRA_MCP_LOG_LEVEL: ERROR
  253. depends_on:
  254. kestra:
  255. condition: service_healthy
  256. networks:
  257. - dataops-test-net
  258. dataops-scheduling-mcp:
  259. image: dataops-platform-mcp:local
  260. build:
  261. context: ../..
  262. dockerfile: deploy/docker/mcp.Dockerfile
  263. profiles:
  264. - dataops-mcp
  265. stdin_open: true
  266. read_only: true
  267. tmpfs:
  268. - /tmp:size=32m,mode=1777
  269. pids_limit: 64
  270. environment:
  271. DATAOPS_MCP_SUBJECT: ${DATAOPS_MCP_SUBJECT:-}
  272. DATAOPS_MCP_ROLES: ${DATAOPS_MCP_ROLES:-}
  273. DATAOPS_MCP_BUSINESS_DOMAINS: ${DATAOPS_MCP_BUSINESS_DOMAINS:-}
  274. DATAOPS_MCP_ENVIRONMENTS: ${DATAOPS_MCP_ENVIRONMENTS:-}
  275. DATAOPS_MCP_CORRELATION_ID: ${DATAOPS_MCP_CORRELATION_ID:-}
  276. DATAOPS_MCP_DATABASE_URL: postgresql://dataops_app:${DATAOPS_RUNTIME_PASSWORD:-dataops-app-test-password}@postgres:5432/dataops
  277. KESTRA_BASE_URL: http://kestra:8080/api/v1
  278. KESTRA_TENANT_ID: main
  279. KESTRA_USERNAME: ${KESTRA_USERNAME:-admin@dataops.local}
  280. KESTRA_PASSWORD: ${KESTRA_PASSWORD:-DataOpsKestra1!}
  281. RUNNER_TASK_TOKEN_SECRET: ${RUNNER_TASK_TOKEN_SECRET:-dataops-local-runner-task-token-secret-change-me}
  282. RUNNER_TASK_TOKEN_TTL_SECONDS: 60
  283. command:
  284. - --kind
  285. - scheduling
  286. - --factory
  287. - app.core.mcp.bootstrap:build_scheduling_gateway
  288. depends_on:
  289. postgres:
  290. condition: service_healthy
  291. db-migrate:
  292. condition: service_completed_successfully
  293. kestra:
  294. condition: service_healthy
  295. runner:
  296. condition: service_healthy
  297. networks:
  298. - dataops-test-net
  299. dataops-context-mcp:
  300. image: dataops-platform-mcp:local
  301. build:
  302. context: ../..
  303. dockerfile: deploy/docker/mcp.Dockerfile
  304. profiles:
  305. - dataops-mcp
  306. stdin_open: true
  307. read_only: true
  308. tmpfs:
  309. - /tmp:size=32m,mode=1777
  310. pids_limit: 64
  311. environment:
  312. DATAOPS_MCP_SUBJECT: ${DATAOPS_MCP_SUBJECT:-}
  313. DATAOPS_MCP_ROLES: ${DATAOPS_MCP_ROLES:-}
  314. DATAOPS_MCP_BUSINESS_DOMAINS: ${DATAOPS_MCP_BUSINESS_DOMAINS:-}
  315. DATAOPS_MCP_ENVIRONMENTS: ${DATAOPS_MCP_ENVIRONMENTS:-}
  316. DATAOPS_MCP_CORRELATION_ID: ${DATAOPS_MCP_CORRELATION_ID:-}
  317. DATAOPS_MCP_DATABASE_URL: postgresql://dataops_app:${DATAOPS_RUNTIME_PASSWORD:-dataops-app-test-password}@postgres:5432/dataops
  318. DATAOPS_MCP_CONTEXT_MAX_CONCURRENCY: 10
  319. command:
  320. - --kind
  321. - context
  322. - --factory
  323. - app.core.mcp.bootstrap:build_context_service
  324. depends_on:
  325. postgres:
  326. condition: service_healthy
  327. db-migrate:
  328. condition: service_completed_successfully
  329. networks:
  330. - dataops-test-net
  331. runner:
  332. image: ${DATAOPS_RUNNER_IMAGE:-dataops-platform-runner:local}
  333. build:
  334. context: ../..
  335. dockerfile: deploy/docker/runner.Dockerfile
  336. target: runtime
  337. environment:
  338. RUNNER_LISTEN_HOST: 0.0.0.0
  339. RUNNER_LISTEN_PORT: 5600
  340. RUNNER_WORKERS: 2
  341. RUNNER_THREADS: 2
  342. RUNNER_TASK_TOKEN_SECRET: ${RUNNER_TASK_TOKEN_SECRET:-dataops-local-runner-task-token-secret-change-me}
  343. RUNNER_TASK_TOKEN_TTL_SECONDS: 60
  344. RUNNER_DATASOURCE_POOL_SIZE: 1
  345. RUNNER_DATASOURCE_MAX_OVERFLOW: 1
  346. RUNNER_DATASOURCE_MAX_IDLE_POOLS: 4
  347. RUNNER_DATASOURCE_CONNECTION_BUDGET: 32
  348. RUNNER_HTTP_ALLOWED_HOSTS: ${RUNNER_HTTP_ALLOWED_HOSTS:-}
  349. RUNNER_MINIO_HOST: minio:9000
  350. RUNNER_MINIO_USER: dataops-test
  351. RUNNER_MINIO_PASSWORD: dataops-test-password
  352. RUNNER_MINIO_BUCKET: dataops-bucket
  353. RUNNER_MINIO_SECURE: "false"
  354. RUNNER_ARTIFACT_MAX_BYTES: 33554432
  355. RUNNER_ARTIFACT_MAX_ROWS: 100000
  356. RUNNER_ARTIFACT_MEMORY_LIMIT_BYTES: 268435456
  357. RUNNER_ARTIFACT_TTL_SECONDS: 3600
  358. DATABASE_URL: postgresql://dataops_app:${DATAOPS_RUNTIME_PASSWORD:-dataops-app-test-password}@postgres:5432/dataops
  359. NEO4J_URI: bolt://neo4j:7687
  360. NEO4J_USER: neo4j
  361. NEO4J_PASSWORD: Passw0rd
  362. DATASOURCE_CREDENTIAL_MASTER_KEY: ${DATASOURCE_CREDENTIAL_MASTER_KEY:-MDEyMzQ1Njc4OWFiY2RlZjAxMjM0NTY3ODlhYmNkZWY=}
  363. DATASOURCE_CREDENTIAL_KEY_VERSION: ${DATASOURCE_CREDENTIAL_KEY_VERSION:-v1}
  364. ports:
  365. - "127.0.0.1:${RUNNER_PORT:-15600}:5600"
  366. command: ["gunicorn", "--config", "app/runner/gunicorn_config.py", "app.runner.wsgi:application"]
  367. read_only: true
  368. tmpfs:
  369. - /tmp:size=64m,mode=1777
  370. pids_limit: 128
  371. deploy:
  372. resources:
  373. limits:
  374. cpus: "1.0"
  375. memory: 512M
  376. pids: 128
  377. depends_on:
  378. postgres:
  379. condition: service_healthy
  380. db-migrate:
  381. condition: service_completed_successfully
  382. neo4j:
  383. condition: service_healthy
  384. minio-init:
  385. condition: service_completed_successfully
  386. healthcheck:
  387. test:
  388. - CMD
  389. - python
  390. - -c
  391. - import urllib.request; urllib.request.urlopen('http://127.0.0.1:5600/health', timeout=5)
  392. interval: 10s
  393. timeout: 5s
  394. retries: 20
  395. start_period: 20s
  396. networks:
  397. dataops-test-net:
  398. aliases:
  399. - dataops-runner
  400. backend:
  401. image: ${DATAOPS_BACKEND_IMAGE:-dataops-platform-backend:local}
  402. build:
  403. context: ../..
  404. dockerfile: deploy/docker/backend.Dockerfile
  405. target: runtime
  406. environment:
  407. FLASK_ENV: production
  408. LISTEN_HOST: 0.0.0.0
  409. LISTEN_PORT: 5500
  410. GUNICORN_WORKERS: 2
  411. DATABASE_URL: postgresql://dataops_app:${DATAOPS_RUNTIME_PASSWORD:-dataops-app-test-password}@postgres:5432/dataops
  412. NEO4J_URI: bolt://neo4j:7687
  413. NEO4J_HTTP_URI: http://neo4j:7474
  414. NEO4J_USER: neo4j
  415. NEO4J_PASSWORD: Passw0rd
  416. NEO4J_ENCRYPTED: "false"
  417. MINIO_HOST: minio:9000
  418. MINIO_USER: dataops-test
  419. MINIO_PASSWORD: dataops-test-password
  420. MINIO_BUCKET: dataops-bucket
  421. MINIO_SECURE: "false"
  422. DATAFLOW_DEFAULT_DB_HOST: postgres
  423. DATAFLOW_DEFAULT_DB_PORT: 5432
  424. DATAFLOW_DEFAULT_DB_NAME: dataops
  425. DATAFLOW_SCHEMA: dags
  426. N8N_API_URL: http://n8n:5678
  427. N8N_API_KEY: ${N8N_API_KEY:-}
  428. KESTRA_BASE_URL: http://kestra:8080/api/v1
  429. KESTRA_TENANT_ID: main
  430. KESTRA_USERNAME: ${KESTRA_USERNAME:-admin@dataops.local}
  431. KESTRA_PASSWORD: ${KESTRA_PASSWORD:-DataOpsKestra1!}
  432. RUNNER_TASK_TOKEN_SECRET: ${RUNNER_TASK_TOKEN_SECRET:-dataops-local-runner-task-token-secret-change-me}
  433. RUNNER_TASK_TOKEN_TTL_SECONDS: 60
  434. DATA_FACTORY_ACTIVATION_ENABLED: ${DATA_FACTORY_ACTIVATION_ENABLED:-false}
  435. EDGE_MTLS_TRUSTED_PROXY_IPS: 172.31.0.10
  436. EDGE_GATEWAY_SIGNING_PRIVATE_KEY_FILE: /run/secrets/edge_gateway_signing_private_key
  437. EDGE_GATEWAY_SIGNING_PUBLIC_KEY: ${EDGE_GATEWAY_SIGNING_PUBLIC_KEY:-}
  438. EDGE_GATEWAY_SIGNING_KEY_ID: ${EDGE_GATEWAY_SIGNING_KEY_ID:-}
  439. API_BASE_URL: http://backend:5500/api
  440. DEEPSEEK_API_KEY: ${DEEPSEEK_API_KEY:-}
  441. LLM_BASE_URL: https://api.deepseek.com
  442. LLM_MODEL_NAME: deepseek-chat
  443. KNOWLEDGE_ENABLED: "true"
  444. KNOWLEDGE_LIGHTRAG_ENABLED: ${KNOWLEDGE_LIGHTRAG_ENABLED:-false}
  445. KNOWLEDGE_LIGHTRAG_SHADOW_ONLY: "true"
  446. KNOWLEDGE_LIGHTRAG_BASE_URL: http://lightrag:9621
  447. KNOWLEDGE_LIGHTRAG_API_KEY: ${LIGHTRAG_API_KEY:-local-shadow-only-key}
  448. QWEN_EMBEDDING_BASE_URL: ${QWEN_EMBEDDING_BASE_URL:-}
  449. QWEN_EMBEDDING_API_KEY: ${QWEN_EMBEDDING_API_KEY:-}
  450. QWEN_EMBEDDING_MODEL: ${QWEN_EMBEDDING_MODEL:-text-embedding-v3}
  451. SECRET_KEY: dataops-local-test-secret-key
  452. AUDIT_EVIDENCE_SECRET: ${AUDIT_EVIDENCE_SECRET:-dataops-local-audit-evidence-secret-change-me}
  453. AUDIT_EVIDENCE_KEY_VERSION: ${AUDIT_EVIDENCE_KEY_VERSION:-local-v1}
  454. SECURITY_SIEM_HOST_ALLOWLIST: ${SECURITY_SIEM_HOST_ALLOWLIST:-}
  455. RULE_GENERATION_RECEIPT_SECRET: ${RULE_GENERATION_RECEIPT_SECRET:-}
  456. DATASOURCE_CREDENTIAL_MASTER_KEY: ${DATASOURCE_CREDENTIAL_MASTER_KEY:-MDEyMzQ1Njc4OWFiY2RlZjAxMjM0NTY3ODlhYmNkZWY=}
  457. DATASOURCE_CREDENTIAL_KEY_VERSION: ${DATASOURCE_CREDENTIAL_KEY_VERSION:-v1}
  458. LOG_DIR: /app/logs
  459. LOG_TO_CONSOLE: "true"
  460. ports:
  461. - "${BACKEND_PORT:-15500}:5500"
  462. volumes:
  463. - dataops-test-backend-logs:/app/logs
  464. - dataops-test-upload:/data/upload
  465. - dataops-test-archive:/data/archive
  466. secrets:
  467. - edge_gateway_signing_private_key
  468. depends_on:
  469. postgres:
  470. condition: service_healthy
  471. db-migrate:
  472. condition: service_completed_successfully
  473. neo4j:
  474. condition: service_healthy
  475. minio-init:
  476. condition: service_completed_successfully
  477. kestra:
  478. condition: service_healthy
  479. runner:
  480. condition: service_healthy
  481. healthcheck:
  482. test:
  483. - CMD
  484. - python
  485. - -c
  486. - import urllib.request; urllib.request.urlopen('http://127.0.0.1:5500/api/system/health', timeout=5)
  487. interval: 10s
  488. timeout: 10s
  489. retries: 20
  490. start_period: 20s
  491. networks:
  492. dataops-test-net:
  493. edge-control-net:
  494. ipv4_address: 172.31.0.20
  495. edge-mtls-proxy:
  496. image: nginx:1.27-alpine
  497. profiles:
  498. - enterprise-edge
  499. ports:
  500. - "${DATAOPS_EDGE_MTLS_PORT:-18443}:8443"
  501. volumes:
  502. - ./edge-mtls-nginx.conf:/etc/nginx/conf.d/default.conf:ro
  503. - ${DATAOPS_EDGE_MTLS_CERT_DIR:-./edge-mtls-certs}:/etc/nginx/edge-mtls:ro
  504. read_only: true
  505. tmpfs:
  506. - /var/cache/nginx:size=16m
  507. - /var/run:size=1m
  508. - /tmp:size=8m
  509. depends_on:
  510. backend:
  511. condition: service_healthy
  512. networks:
  513. edge-control-net:
  514. ipv4_address: 172.31.0.10
  515. lightrag-neo4j:
  516. image: neo4j:5.26-community
  517. profiles:
  518. - knowledge-shadow
  519. environment:
  520. NEO4J_AUTH: neo4j/lightrag-test-password
  521. NEO4J_server_memory_heap_initial__size: 256m
  522. NEO4J_server_memory_heap_max__size: 512m
  523. NEO4J_server_memory_pagecache_size: 256m
  524. volumes:
  525. - dataops-test-lightrag-neo4j:/data
  526. healthcheck:
  527. test: ["CMD-SHELL", "cypher-shell -u neo4j -p lightrag-test-password 'RETURN 1' >/dev/null 2>&1"]
  528. interval: 10s
  529. timeout: 10s
  530. retries: 30
  531. start_period: 20s
  532. networks:
  533. - dataops-test-net
  534. lightrag:
  535. image: ghcr.io/hkuds/lightrag@sha256:67ccf8d9f74eb29da872bf8b3e6513605f5ac601fb0509c5b0ca16d98d2d307d
  536. profiles:
  537. - knowledge-shadow
  538. environment:
  539. HOST: 0.0.0.0
  540. PORT: 9621
  541. WORKSPACE: ${LIGHTRAG_SHADOW_WORKSPACE:-dataops-global-shadow-g1}
  542. LIGHTRAG_API_KEY: ${LIGHTRAG_API_KEY:-local-shadow-only-key}
  543. LIGHTRAG_KV_STORAGE: PGKVStorage
  544. LIGHTRAG_DOC_STATUS_STORAGE: PGDocStatusStorage
  545. LIGHTRAG_VECTOR_STORAGE: PGVectorStorage
  546. LIGHTRAG_GRAPH_STORAGE: Neo4JStorage
  547. POSTGRES_HOST: postgres
  548. POSTGRES_PORT: 5432
  549. POSTGRES_USER: lightrag
  550. POSTGRES_PASSWORD: lightrag-test-password
  551. POSTGRES_DATABASE: dataops_lightrag
  552. POSTGRES_ENABLE_VECTOR: "true"
  553. NEO4J_URI: bolt://lightrag-neo4j:7687
  554. NEO4J_USERNAME: neo4j
  555. NEO4J_PASSWORD: lightrag-test-password
  556. NEO4J_DATABASE: neo4j
  557. LLM_BINDING: openai
  558. LLM_BINDING_HOST: ${LIGHTRAG_LLM_BASE_URL:-https://api.deepseek.com/v1}
  559. LLM_BINDING_API_KEY: ${LIGHTRAG_LLM_API_KEY:-}
  560. LLM_MODEL: ${LIGHTRAG_LLM_MODEL:-deepseek-chat}
  561. EMBEDDING_BINDING: openai
  562. EMBEDDING_BINDING_HOST: ${QWEN_EMBEDDING_BASE_URL:-}
  563. EMBEDDING_BINDING_API_KEY: ${QWEN_EMBEDDING_API_KEY:-}
  564. EMBEDDING_MODEL: ${QWEN_EMBEDDING_MODEL:-text-embedding-v3}
  565. EMBEDDING_DIM: 1024
  566. LIGHTRAG_PARSER: "*:legacy-F"
  567. depends_on:
  568. postgres:
  569. condition: service_healthy
  570. lightrag-neo4j:
  571. condition: service_healthy
  572. healthcheck:
  573. test: ["CMD-SHELL", "curl -fsS http://127.0.0.1:9621/health >/dev/null"]
  574. interval: 10s
  575. timeout: 5s
  576. retries: 30
  577. start_period: 30s
  578. networks:
  579. - dataops-test-net
  580. lightrag-projector:
  581. image: ${DATAOPS_LIGHTRAG_PROJECTOR_IMAGE:-dataops-platform-lightrag-projector:local}
  582. build:
  583. context: ../..
  584. dockerfile: deploy/docker/backend.Dockerfile
  585. target: runtime
  586. profiles:
  587. - knowledge-shadow
  588. command: ["python", "-m", "app.core.knowledge.lightrag.worker"]
  589. environment:
  590. DATABASE_URL: postgresql://dataops_app:${DATAOPS_RUNTIME_PASSWORD:-dataops-app-test-password}@postgres:5432/dataops
  591. KNOWLEDGE_LIGHTRAG_BASE_URL: http://lightrag:9621
  592. KNOWLEDGE_LIGHTRAG_API_KEY: ${LIGHTRAG_API_KEY:-local-shadow-only-key}
  593. KNOWLEDGE_LIGHTRAG_TIMEOUT_SECONDS: 15
  594. LIGHTRAG_SHADOW_WORKSPACE: ${LIGHTRAG_SHADOW_WORKSPACE:-dataops-global-shadow-g1}
  595. depends_on:
  596. postgres:
  597. condition: service_healthy
  598. db-migrate:
  599. condition: service_completed_successfully
  600. lightrag:
  601. condition: service_healthy
  602. restart: unless-stopped
  603. networks:
  604. - dataops-test-net
  605. frontend:
  606. image: ${DATAOPS_FRONTEND_IMAGE:-dataops-platform-frontend:local}
  607. build:
  608. context: ../..
  609. dockerfile: deploy/docker/frontend.Dockerfile
  610. args:
  611. VUE_APP_N8N_URL: http://localhost:15678
  612. VUE_APP_N8N_CHAT_URL: ""
  613. VUE_APP_MINIO_PUBLIC_URL: http://localhost:19000/dataops-bucket
  614. VUE_APP_PREVIEW_URL: ""
  615. ports:
  616. - "${FRONTEND_PORT:-18183}:80"
  617. depends_on:
  618. backend:
  619. condition: service_healthy
  620. healthcheck:
  621. test: ["CMD-SHELL", "wget --spider -q http://127.0.0.1/"]
  622. interval: 10s
  623. timeout: 5s
  624. retries: 20
  625. networks:
  626. - dataops-test-net
  627. networks:
  628. dataops-test-net:
  629. name: ${DATAOPS_NETWORK_NAME:-dataops-test-net}
  630. edge-control-net:
  631. name: ${DATAOPS_EDGE_NETWORK_NAME:-dataops-edge-control-net}
  632. internal: true
  633. ipam:
  634. config:
  635. - subnet: 172.31.0.0/24
  636. secrets:
  637. edge_gateway_signing_private_key:
  638. file: ${EDGE_GATEWAY_SIGNING_PRIVATE_KEY_FILE:-./edge-secrets/edge-gateway-signing.key}
  639. volumes:
  640. dataops-test-postgres:
  641. dataops-test-source-postgres:
  642. dataops-test-source-mysql:
  643. dataops-test-neo4j:
  644. dataops-test-minio:
  645. dataops-test-n8n:
  646. dataops-test-kestra:
  647. dataops-test-backend-logs:
  648. dataops-test-upload:
  649. dataops-test-archive:
  650. dataops-test-lightrag-neo4j: