docker-compose.yml 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110
  1. services:
  2. # -- Orchestration workflow engine -----------------------------------------
  3. orchestrator:
  4. build:
  5. context: ./services/orchestrator
  6. dockerfile: Dockerfile
  7. image: lf-orchestrator:${ORCHESTRATOR_VERSION:-dev}
  8. container_name: lf-orchestrator
  9. ports:
  10. - "${ORCHESTRATOR_PORT:-1717}:1717"
  11. environment:
  12. MODE: ${ORCHESTRATOR_MODE:-plug}
  13. SPECTROMETER_URL: http://spectrometer:8000
  14. RECONSTRUCTOR_URL: http://reconstructor:8000
  15. SEQ_INTERP_URL: http://seq-interp:7475
  16. restart: unless-stopped
  17. healthcheck:
  18. test: ["CMD", "curl", "-f", "http://localhost:1717/health"]
  19. interval: 10s
  20. timeout: 5s
  21. retries: 5
  22. start_period: 15s
  23. # -- MRI sequence interpreter -----------------------------------------------
  24. # Build context is the monorepo root so Dockerfile can access both
  25. # services/seq-interp/ and libs/lf-scanner/
  26. seq-interp:
  27. build:
  28. context: .
  29. dockerfile: services/seq-interp/Dockerfile
  30. image: lf-seq-interp:${SEQ_INTERP_VERSION:-dev}
  31. container_name: lf-seq-interp
  32. ports:
  33. - "${SEQ_INTERP_PORT:-7475}:7475"
  34. volumes:
  35. - seq_interp_input:/app/seq_interp/data/input
  36. - seq_interp_output:/app/seq_interp/data/output
  37. - seq_interp_logs:/app/seq_interp/log
  38. restart: unless-stopped
  39. healthcheck:
  40. test: ["CMD", "curl", "-f", "http://localhost:7475/health"]
  41. interval: 10s
  42. timeout: 5s
  43. retries: 5
  44. start_period: 15s
  45. # -- Spectrometer hardware controller (DRF) --------------------------------
  46. spectrometer:
  47. build:
  48. context: ./services/spectrometer
  49. dockerfile: Dockerfile
  50. image: lf-spectrometer:${SPECTROMETER_VERSION:-dev}
  51. container_name: lf-spectrometer
  52. ports:
  53. - "${SPECTROMETER_PORT:-8000}:8000"
  54. volumes:
  55. - spectrometer_db:/app/db
  56. restart: unless-stopped
  57. healthcheck:
  58. test: ["CMD", "curl", "-f", "http://localhost:8000/api/"]
  59. interval: 15s
  60. timeout: 5s
  61. retries: 5
  62. start_period: 30s
  63. # -- MRI image reconstructor ------------------------------------------------
  64. reconstructor:
  65. build:
  66. context: ./services/reconstructor
  67. dockerfile: Dockerfile
  68. image: lf-reconstructor:${RECONSTRUCTOR_VERSION:-dev}
  69. container_name: lf-reconstructor
  70. ports:
  71. - "${RECONSTRUCTOR_PORT:-8081}:8000"
  72. volumes:
  73. - reconstructor_sessions:/app/sessions
  74. restart: unless-stopped
  75. healthcheck:
  76. test: ["CMD", "curl", "-f", "http://localhost:8000/health"]
  77. interval: 10s
  78. timeout: 5s
  79. retries: 5
  80. start_period: 20s
  81. # -- Spectroscopy signal processor -----------------------------------------
  82. spectroscopy:
  83. build:
  84. context: ./services/spectroscopy
  85. dockerfile: Dockerfile
  86. image: lf-spectroscopy:${SPECTROSCOPY_VERSION:-dev}
  87. container_name: lf-spectroscopy
  88. ports:
  89. - "${SPECTROSCOPY_PORT:-8002}:8002"
  90. environment:
  91. SERVICE_PORT: "8002"
  92. restart: unless-stopped
  93. healthcheck:
  94. test: ["CMD", "curl", "-f", "http://localhost:8002/health"]
  95. interval: 10s
  96. timeout: 5s
  97. retries: 5
  98. start_period: 15s
  99. volumes:
  100. seq_interp_input:
  101. seq_interp_output:
  102. seq_interp_logs:
  103. reconstructor_sessions:
  104. spectrometer_db: