docker-compose.ci.yml 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081
  1. version: "2"
  2. volumes:
  3. data:
  4. services:
  5. test_unit:
  6. build: .
  7. image: ci/$PROJECT_NAME:$BRANCH_NAME-$BUILD_NUMBER
  8. user: node
  9. command: npm run test:unit:app
  10. environment:
  11. BASE_CONFIG:
  12. SHARELATEX_CONFIG:
  13. NODE_OPTIONS: "--unhandled-rejections=strict"
  14. test_acceptance:
  15. build: .
  16. image: ci/$PROJECT_NAME:$BRANCH_NAME-$BUILD_NUMBER
  17. working_dir: /app
  18. environment:
  19. BCRYPT_ROUNDS: 1
  20. REDIS_HOST: redis
  21. QUEUES_REDIS_HOST: redis
  22. MONGO_URL: "mongodb://mongo/sharelatex"
  23. SHARELATEX_ALLOW_PUBLIC_ACCESS: 'true'
  24. PROJECT_HISTORY_ENABLED: 'true'
  25. ENABLED_LINKED_FILE_TYPES: 'url,project_file,project_output_file,mendeley,zotero'
  26. LINKED_URL_PROXY: 'http://localhost:6543'
  27. LOCK_MANAGER_MAX_LOCK_WAIT_TIME: 30000
  28. NODE_ENV: test
  29. NODE_OPTIONS: "--unhandled-rejections=strict"
  30. BASE_CONFIG:
  31. SHARELATEX_CONFIG:
  32. COOKIE_DOMAIN: .overleaf.test
  33. PUBLIC_URL: 'http://www.overleaf.test:3000'
  34. HTTP_TEST_HOST: www.overleaf.test
  35. OT_JWT_AUTH_KEY: "very secret key"
  36. extra_hosts:
  37. - 'www.overleaf.test:127.0.0.1'
  38. command: npm run test:acceptance:app
  39. user: root
  40. depends_on:
  41. - redis
  42. - mongo
  43. test_karma:
  44. build:
  45. context: .
  46. dockerfile: Dockerfile.frontend.ci
  47. args:
  48. PROJECT_NAME: $PROJECT_NAME
  49. BRANCH_NAME: $BRANCH_NAME
  50. BUILD_NUMBER: $BUILD_NUMBER
  51. working_dir: /app
  52. command: npm run test:karma:single
  53. user: node
  54. environment:
  55. NODE_OPTIONS: "--unhandled-rejections=strict"
  56. test_frontend:
  57. build: .
  58. image: ci/$PROJECT_NAME:$BRANCH_NAME-$BUILD_NUMBER
  59. user: node
  60. command: npm run test:frontend
  61. environment:
  62. NODE_OPTIONS: "--unhandled-rejections=strict"
  63. tar:
  64. image: ci/$PROJECT_NAME:$BRANCH_NAME-$BUILD_NUMBER-webpack
  65. volumes:
  66. - ./:/tmp/build/
  67. command: tar -cf /tmp/build/build.tar public/
  68. user: root
  69. redis:
  70. image: redis
  71. mongo:
  72. image: mongo:4.0.19