docker-compose.yml 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  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. version: "2.3"
  5. services:
  6. test_unit:
  7. image: node:16.16.0
  8. volumes:
  9. - .:/overleaf/services/docstore
  10. - ../../node_modules:/overleaf/node_modules
  11. - ../../libraries:/overleaf/libraries
  12. working_dir: /overleaf/services/docstore
  13. environment:
  14. MOCHA_GREP: ${MOCHA_GREP}
  15. NODE_ENV: test
  16. NODE_OPTIONS: "--unhandled-rejections=strict"
  17. command: npm run --silent test:unit
  18. user: node
  19. test_acceptance:
  20. image: node:16.16.0
  21. volumes:
  22. - .:/overleaf/services/docstore
  23. - ../../node_modules:/overleaf/node_modules
  24. - ../../libraries:/overleaf/libraries
  25. working_dir: /overleaf/services/docstore
  26. extends:
  27. file: docker-compose-config.yml
  28. service: dev
  29. environment:
  30. ELASTIC_SEARCH_DSN: es:9200
  31. REDIS_HOST: redis
  32. QUEUES_REDIS_HOST: redis
  33. ANALYTICS_QUEUES_REDIS_HOST: redis
  34. MONGO_HOST: mongo
  35. POSTGRES_HOST: postgres
  36. GCS_API_ENDPOINT: gcs:9090
  37. GCS_API_SCHEME: http
  38. GCS_PROJECT_ID: fake
  39. STORAGE_EMULATOR_HOST: http://gcs:9090/storage/v1
  40. MOCHA_GREP: ${MOCHA_GREP}
  41. LOG_LEVEL: ERROR
  42. NODE_ENV: test
  43. NODE_OPTIONS: "--unhandled-rejections=strict"
  44. user: node
  45. depends_on:
  46. mongo:
  47. condition: service_healthy
  48. gcs:
  49. condition: service_healthy
  50. command: npm run --silent test:acceptance
  51. mongo:
  52. image: mongo:4.4.16
  53. healthcheck:
  54. test: "mongo --quiet localhost/test --eval 'quit(db.runCommand({ ping: 1 }).ok ? 0 : 1)'"
  55. interval: 1s
  56. retries: 20
  57. gcs:
  58. image: fsouza/fake-gcs-server:v1.21.2
  59. command: ["--port=9090", "--scheme=http"]
  60. healthcheck:
  61. test: wget --quiet --output-document=/dev/null http://localhost:9090/storage/v1/b
  62. interval: 1s
  63. retries: 20