compose.yaml 4.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150
  1. ## Mark Shust's Docker Configuration for Magento
  2. ## (https://github.com/markshust/docker-magento)
  3. ##
  4. ## Version 51.0.0
  5. ## To use SSH, see https://github.com/markshust/docker-magento#ssh
  6. ## Linux users, see https://github.com/markshust/docker-magento#linux
  7. ## If you changed the default Docker network, you may need to replace
  8. ## 172.17.0.1 in this file with the result of:
  9. ## docker network inspect bridge --format='{{(index .IPAM.Config 0).Gateway}}'
  10. services:
  11. app:
  12. image: markoshust/magento-nginx:1.24-0
  13. ports:
  14. - "80:8000"
  15. - "443:8443"
  16. volumes: &appvolumes
  17. - ~/.composer:/var/www/.composer:cached
  18. - ~/.ssh/id_rsa:/var/www/.ssh/id_rsa:cached
  19. - ~/.ssh/known_hosts:/var/www/.ssh/known_hosts:cached
  20. - appdata:/var/www/html
  21. - sockdata:/sock
  22. - ssldata:/etc/nginx/certs
  23. #extra_hosts: &appextrahosts
  24. ## Selenium support, replace "magento.test" with URL of your site
  25. #- "magento.test:172.17.0.1"
  26. ## Linux, uncomment for Xdebug capabilities:
  27. #- "host.docker.internal:host-gateway"
  28. phpfpm:
  29. image: markoshust/magento-php:8.3-fpm-4
  30. volumes: *appvolumes
  31. env_file: env/phpfpm.env
  32. #extra_hosts: *appextrahosts
  33. db:
  34. image: mariadb:11.4
  35. command:
  36. --max_allowed_packet=64M
  37. --optimizer_use_condition_selectivity=1
  38. --optimizer_switch="rowid_filter=off"
  39. ports:
  40. - "3306:3306"
  41. env_file: env/db.env
  42. volumes:
  43. - dbdata:/var/lib/mysql
  44. ## If you wish to use MySQL, comment out the mariadb db image above and
  45. ## uncomment this block.
  46. #db:
  47. # image: mysql:8.4
  48. # command:
  49. # --max_allowed_packet=64M
  50. # --optimizer_use_condition_selectivity=1
  51. # --optimizer_switch="rowid_filter=off"
  52. # ports:
  53. # - "3306:3306"
  54. # env_file: env/db.env
  55. # volumes:
  56. # - dbdata:/var/lib/mysql
  57. redis:
  58. image: valkey/valkey:8.1-alpine
  59. ports:
  60. - "6379:6379"
  61. ## If you wish to use Redis, comment out the redis image above and
  62. ## uncomment this block.
  63. #redis:
  64. # image: redis:7.2-alpine
  65. # ports:
  66. # - "6379:6379"
  67. opensearch:
  68. image: markoshust/magento-opensearch:2.12-0
  69. ports:
  70. - "9200:9200"
  71. - "9300:9300"
  72. env_file: env/opensearch.env
  73. environment:
  74. - "discovery.type=single-node"
  75. ## Avoid test failures due to small disks
  76. ## More info at https://github.com/markshust/docker-magento/issues/488
  77. - "cluster.routing.allocation.disk.threshold_enabled=false"
  78. - "index.blocks.read_only_allow_delete"
  79. ## Uncomment to set custom heap size to avoid memory errors
  80. #- "OPENSEARCH_JAVA_OPTS=-Xms1g -Xmx1g"
  81. ## Uncomment to increase the virtual memory map count
  82. #- "max_map_count=262144"
  83. ## If you wish to use Elasticsearch, comment out opensearch image above and
  84. ## uncomment this block. Do the same in the composer.healthcheck.yaml file.
  85. # Additionally, if you are performing the manual setup, you will need to
  86. # update the bin/setup command to use the $ES_HOST variable as the value for
  87. # the --elasticsearch-host argument passed to bin/magento setup:install.
  88. #elasticsearch:
  89. # image: markoshust/magento-elasticsearch:8.13-0
  90. # ports:
  91. # - "9200:9200"
  92. # - "9300:9300"
  93. # env_file: env/elasticsearch.env
  94. # environment:
  95. # - "discovery.type=single-node"
  96. # ## Avoid test failures due to small disks
  97. # ## More info at https://github.com/markshust/docker-magento/issues/488
  98. # - "cluster.routing.allocation.disk.threshold_enabled=false"
  99. # - "index.blocks.read_only_allow_delete"
  100. # ## Uncomment to set custom heap size to avoid memory errors
  101. # #- "ES_JAVA_OPTS=-Xms1g -Xmx1g"
  102. # ## Uncomment to increase the virtual memory map count
  103. # #- "max_map_count=262144"
  104. # ## Uncomment the line below if ElasticSearch fails to start and stops after ~150 seconds with the error "container for service "elasticsearch" is unhealthy".
  105. # #- "xpack.security.enabled=false"
  106. rabbitmq:
  107. image: markoshust/magento-rabbitmq:4.1-0
  108. ports:
  109. - "15672:15672"
  110. - "5672:5672"
  111. volumes:
  112. - rabbitmqdata:/var/lib/rabbitmq
  113. env_file: env/rabbitmq.env
  114. mailcatcher:
  115. image: sj26/mailcatcher:v0.10.0
  116. ports:
  117. - "1080:1080"
  118. ## Cloudflare tunnel support, uncomment to enable
  119. #tunnel:
  120. # container_name: cloudflared-tunnel
  121. # image: cloudflare/cloudflared:latest
  122. # command: tunnel run
  123. # env_file: env/cloudflare.env
  124. ## Blackfire support, uncomment to enable
  125. #blackfire:
  126. # image: blackfire/blackfire:2
  127. # ports:
  128. # - "8307"
  129. # env_file: env/blackfire.env
  130. volumes:
  131. appdata:
  132. dbdata:
  133. rabbitmqdata:
  134. sockdata:
  135. ssldata: