docker-compose.yml 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  1. # This file was auto-generated, do not edit it directly.
  2. # Instead run bin/update_build_scripts from
  3. # https://github.com/sharelatex/sharelatex-dev-environment
  4. version: "2.3"
  5. services:
  6. test_unit:
  7. image: node:12.22.3
  8. volumes:
  9. - .:/app
  10. working_dir: /app
  11. environment:
  12. MOCHA_GREP: ${MOCHA_GREP}
  13. NODE_ENV: test
  14. NODE_OPTIONS: "--unhandled-rejections=strict"
  15. command: npm run --silent test:unit
  16. user: node
  17. test_acceptance:
  18. image: node:12.22.3
  19. volumes:
  20. - .:/app
  21. working_dir: /app
  22. environment:
  23. ELASTIC_SEARCH_DSN: es:9200
  24. REDIS_HOST: redis
  25. QUEUES_REDIS_HOST: redis
  26. MONGO_HOST: mongo
  27. POSTGRES_HOST: postgres
  28. AWS_S3_ENDPOINT: http://s3:9090
  29. AWS_S3_PATH_STYLE: 'true'
  30. AWS_ACCESS_KEY_ID: fake
  31. AWS_SECRET_ACCESS_KEY: fake
  32. MOCHA_GREP: ${MOCHA_GREP}
  33. LOG_LEVEL: ERROR
  34. NODE_ENV: test
  35. NODE_OPTIONS: "--unhandled-rejections=strict"
  36. AWS_BUCKET: bucket
  37. user: node
  38. depends_on:
  39. mongo:
  40. condition: service_healthy
  41. redis:
  42. condition: service_healthy
  43. s3:
  44. condition: service_healthy
  45. command: npm run --silent test:acceptance
  46. redis:
  47. image: redis
  48. healthcheck:
  49. test: ping=$$(redis-cli ping) && [ "$$ping" = 'PONG' ]
  50. interval: 1s
  51. retries: 20
  52. mongo:
  53. image: mongo:4.0
  54. healthcheck:
  55. test: "mongo --quiet localhost/test --eval 'quit(db.runCommand({ ping: 1 }).ok ? 0 : 1)'"
  56. interval: 1s
  57. retries: 20
  58. s3:
  59. image: adobe/s3mock
  60. environment:
  61. - initialBuckets=fake_user_files,fake_template_files,fake_public_files,bucket
  62. healthcheck:
  63. test: wget --quiet --output-document=/dev/null http://localhost:9090
  64. interval: 1s
  65. retries: 20