docker-compose-multi-local.yml 3.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. version: "2"
  2. services:
  3. mongodb:
  4. restart: always
  5. container_name: crowd_service_mongo
  6. image: "crowd-service-mongo:${CROWD_TAG}"
  7. environment:
  8. - MONGO_INITDB_DATABASE=test
  9. - MONGO_INITDB_ROOT_USERNAME=mooctest
  10. - MONGO_INITDB_ROOT_PASSWORD=mooctest
  11. ports:
  12. - 27217:27017
  13. volumes:
  14. #- ${FILE_STORE_BASE_PATH}/${MONGO_FILE_PATH}:/data/db
  15. - ./init-mongo.js:/docker-entrypoint-initdb.d/init-mongo.js:ro
  16. command: --bind_ip_all
  17. tty: true
  18. # 众测服务后端
  19. crowd_service_backend:
  20. restart: always
  21. container_name: crowd_service_backend
  22. image: "crowd-service-backend:${CROWD_TAG}"
  23. depends_on:
  24. - mongodb
  25. ports:
  26. - 8091:8091
  27. volumes:
  28. - ${FILE_STORE_BASE_PATH}/${BACKEND_STORE_DIR}:/var/www
  29. # - /home/xcc/crowd-service/TestFileSystem/RequirementDoc:/var/www/RequirementDoc
  30. - /Users/guochao/Desktop/crowd-service/TestFileSystem/RequirementDoc:/var/www/RequirementDoc
  31. command: java -jar --spring.profiles.active=private-cloud --spring.data.mongodb.uri=mongodb://mooctest:mooctest@172.16.100.98:27217/test --server.ip=172.16.100.98 --main.site=http://172.16.100.98:8200 --server.port=8091 bug-0.0.1-SNAPSHOT.jar
  32. ##--host需要根据实际地址修改;主站配置(信创、慕测)
  33. # 众测服务前端
  34. crowd_service_frontend:
  35. restart: always
  36. container_name: crowd_service_frontend
  37. image: "crowd-service-frontend:${CROWD_TAG}"
  38. depends_on:
  39. - crowd_service_backend
  40. ports:
  41. - 81:80
  42. volumes:
  43. - ${FILE_STORE_BASE_PATH}/${FRONTEND_STORE_DIR}:/var/www
  44. - ${FILE_STORE_BASE_PATH}/nginx:/etc/nginx
  45. # 报告融合前后端
  46. crowd_service_review:
  47. restart: always
  48. container_name: crowd_service_review
  49. image: "crowd-service-review:${CROWD_TAG}"
  50. depends_on:
  51. - mongodb
  52. - crowd_service_export
  53. ports:
  54. - 9004:9004
  55. volumes:
  56. - ${FILE_STORE_BASE_PATH}/${BACKEND_STORE_DIR}/sgns.wiki.word:/project/sgns.wiki.word
  57. command: java -jar --spring.profiles.active=private-cloud --mongodb.host=172.16.100.98 --mongodb.port=27217 --baseurl.report.host=172.16.100.98:81 --baseurl.report.excel=http://172.16.100.98:9003/generateReport --server.port=9004 crowd_review-1.0-SNAPSHOT.jar
  58. ##--host需要根据实际地址修改;此处有众测后端端口配置和报告导出地址配置
  59. # 报告导出工具
  60. crowd_service_export:
  61. restart: always
  62. container_name: crowd_service_export
  63. image: "crowd-service-export:${CROWD_TAG}"
  64. ports:
  65. - 9003:9003
  66. volumes:
  67. - ${FILE_STORE_BASE_PATH}/${FRONTEND_STORE_DIR}:/var/www
  68. command: java -jar --spring.profiles.active=private-cloud --crowd.frontend=http://172.16.100.98:81 --server.port=9003 export-excel.jar
  69. ##--host需要根据实际地址修改;如果前端端口修改了此处也要修改
  70. ## 注意crowd_service_backend volumes /home/xc-community/crowd-service/TestFileSystem/RequirementDoc:/var/www/RequirementDoc 需要根据实际路径修改/home/xc-community/crowd-service