docker-compose.yml 2.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. # This file was auto-generated, do not edit it directly.
  2. # Instead run bin/update_build_scripts from
  3. # https://github.com/overleaf/internal/
  4. services:
  5. test_unit:
  6. build:
  7. context: ../..
  8. dockerfile: services/real-time/Dockerfile
  9. target: base
  10. volumes:
  11. - .:/overleaf/services/real-time
  12. - ../../node_modules:/overleaf/node_modules
  13. - ../../libraries:/overleaf/libraries
  14. - ../../package.json:/overleaf/package.json
  15. - ../../.yarnrc.yml:/overleaf/.yarnrc.yml
  16. - ../../yarn.lock:/overleaf/yarn.lock
  17. - ../../.yarn:/overleaf/.yarn
  18. - ../../tsconfig.backend.json:/overleaf/tsconfig.backend.json
  19. working_dir: /overleaf/services/real-time
  20. environment:
  21. MOCHA_GREP: ${MOCHA_GREP}
  22. LOG_LEVEL: ${LOG_LEVEL:-}
  23. MONGO_CONNECTION_STRING: mongodb://mongo/test-overleaf
  24. NODE_ENV: test
  25. NODE_OPTIONS: "--unhandled-rejections=strict"
  26. REDIS_HOST: redis_test
  27. HISTORY_REDIS_HOST: redis_test
  28. QUEUES_REDIS_HOST: redis_test
  29. ANALYTICS_QUEUES_REDIS_HOST: redis_test
  30. ANALYTICS_QUEUES_BQ_SINK_REDIS_HOST: redis_test
  31. command: yarn run --silent test:unit
  32. user: node
  33. depends_on:
  34. redis_test:
  35. condition: service_healthy
  36. test_acceptance:
  37. build:
  38. context: ../..
  39. dockerfile: services/real-time/Dockerfile
  40. target: base
  41. volumes:
  42. - .:/overleaf/services/real-time
  43. - ../../node_modules:/overleaf/node_modules
  44. - ../../libraries:/overleaf/libraries
  45. - ../../package.json:/overleaf/package.json
  46. - ../../.yarnrc.yml:/overleaf/.yarnrc.yml
  47. - ../../yarn.lock:/overleaf/yarn.lock
  48. - ../../.yarn:/overleaf/.yarn
  49. working_dir: /overleaf/services/real-time
  50. environment:
  51. RETRIES:
  52. REDIS_HOST: redis_test
  53. HISTORY_REDIS_HOST: redis_test
  54. QUEUES_REDIS_HOST: redis_test
  55. ANALYTICS_QUEUES_REDIS_HOST: redis_test
  56. ANALYTICS_QUEUES_BQ_SINK_REDIS_HOST: redis_test
  57. MONGO_CONNECTION_STRING: mongodb://mongo/test-overleaf
  58. POSTGRES_HOST: postgres
  59. MOCHA_GREP: ${MOCHA_GREP}
  60. LOG_LEVEL: ${LOG_LEVEL:-}
  61. NODE_ENV: test
  62. NODE_OPTIONS: "--unhandled-rejections=strict"
  63. user: node
  64. depends_on:
  65. redis_test:
  66. condition: service_healthy
  67. command: yarn run --silent test:acceptance
  68. redis_test:
  69. image: redis:7.4.8
  70. healthcheck:
  71. test: ping=$$(redis-cli ping) && [ "$$ping" = 'PONG' ]
  72. interval: 1s
  73. retries: 20