docker-compose.yaml 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103
  1. volumes:
  2. mysqldata: ~
  3. elasticsearchdata: ~
  4. # On rajoute un volume (de données non accessibles en dehors)
  5. appdata: ~
  6. version: '3.3'
  7. services:
  8. front:
  9. container_name: front
  10. build:
  11. context: .
  12. dockerfile: docker/node/Dockerfile
  13. volumes:
  14. - ./apps/opentalent-admin-2.0:/home/workspace:rw,cached
  15. ports:
  16. - '3000:3000'
  17. - '3001:3001'
  18. tty: true
  19. es:
  20. container_name: es
  21. image: elasticsearch:2.4.6
  22. restart: always
  23. volumes:
  24. - ./elasticsearchdata:/usr/share/elasticsearch/data:cached
  25. - ./docker/elasticsearch/conf/elasticsearch.yml:/usr/share/elasticsearch/config/elasticsearch.yml:cached
  26. environment:
  27. - cluster.name=docker-cluster
  28. - bootstrap.memory_lock=true
  29. - "ES_JAVA_OPTS=-Xms512m -Xmx512m"
  30. ulimits:
  31. memlock:
  32. soft: -1
  33. hard: -1
  34. ports:
  35. - '9200:9200'
  36. db:
  37. container_name: mariaDb
  38. build:
  39. context: .
  40. dockerfile: docker/mariaDb/Dockerfile
  41. restart: always
  42. volumes:
  43. - ./mysqldata:/var/lib/mysql:cached
  44. - ./apps/env:/env:cached
  45. environment:
  46. MYSQL_ROOT_PASSWORD: mysql660
  47. ports:
  48. - '3306:3306'
  49. web:
  50. container_name: nginx
  51. image: nginx:latest
  52. volumes:
  53. - ./apps/opentalent-platform:/var/www/html:rw,cached
  54. - ./docker/nginx/site.conf:/etc/nginx/conf.d/site.conf:cached
  55. ports:
  56. - '8080:80'
  57. depends_on:
  58. - php
  59. php:
  60. container_name: php
  61. build:
  62. context: .
  63. dockerfile: docker/php/Dockerfile
  64. restart: always
  65. volumes:
  66. - ./apps/.bash_history:/root/.bash_history:cached
  67. - ./apps/opentalent-platform:/var/www/html:rw,cached
  68. # Version Symfony 2
  69. - appdata:/var/www/html/app/cache/
  70. - appdata:/var/www/html/app/logs/
  71. # Le code sera surtout modifié en dehors du container, donc la consistence est prioritairement dans ce sens
  72. - ./apps/opentalent-platform:/var/www/html/:cached
  73. # A l'inverse, les vendors seront surtout modifiés dans le container
  74. - ./apps/opentalent-platform/vendor:/var/www/html/vendor:delegated
  75. depends_on:
  76. - db
  77. - es
  78. # adminassos:
  79. # container_name: adminassos
  80. # build:
  81. # context: .
  82. # dockerfile: docker/adminassos/Dockerfile
  83. # restart: always
  84. # volumes:
  85. # - ./apps/opentalent:/var/source/opentalent:rw,cached
  86. # - ./apps/vendor:/var/source/vendor:rw,cached
  87. # - ./apps/opentalent-config:/var/source/config:rw,cached
  88. # -
  89. phpmyadmin:
  90. container_name: phpMyAdmin
  91. image: phpmyadmin/phpmyadmin
  92. restart: always
  93. ports:
  94. - '8081:80'
  95. depends_on:
  96. - db