docker-compose.yml 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. # Mark Shust's Docker Configuration for Magento
  2. # (https://github.com/markshust/docker-magento)
  3. #
  4. # Version 39.0.1
  5. version: "3"
  6. services:
  7. app:
  8. image: markoshust/magento-nginx:1.18-4
  9. ports:
  10. - "80:8000"
  11. - "443:8443"
  12. links:
  13. - db
  14. - phpfpm
  15. volumes: &appvolumes
  16. - ~/.composer:/var/www/.composer:cached
  17. - appdata:/var/www/html
  18. - sockdata:/sock
  19. - ssldata:/etc/nginx/certs
  20. phpfpm:
  21. image: markoshust/magento-php:7.4-fpm-8
  22. links:
  23. - db
  24. volumes: *appvolumes
  25. db:
  26. image: mariadb:10.4
  27. command: --max_allowed_packet=64M
  28. ports:
  29. - "3306:3306"
  30. env_file: env/db.env
  31. volumes:
  32. - dbdata:/var/lib/mysql
  33. redis:
  34. image: redis:5.0-alpine
  35. elasticsearch:
  36. image: markoshust/magento-elasticsearch:7.9.3-0
  37. ports:
  38. - "9200:9200"
  39. - "9300:9300"
  40. environment:
  41. - "discovery.type=single-node"
  42. # Set custom heap size to avoid memory errors
  43. - "ES_JAVA_OPTS=-Xms1g -Xmx1g"
  44. # Avoid test failures due to small disks
  45. # More info at https://github.com/markshust/docker-magento/issues/488
  46. - "cluster.routing.allocation.disk.threshold_enabled=false"
  47. - "index.blocks.read_only_allow_delete"
  48. rabbitmq:
  49. image: rabbitmq:3.8.22-management-alpine
  50. ports:
  51. - "15672:15672"
  52. - "5672:5672"
  53. volumes:
  54. - rabbitmqdata:/var/lib/rabbitmq
  55. ## Disabling cron by default as it uses higher CPU, enable if needed
  56. #cron:
  57. # image: markoshust/magento-php:7.4-fpm-8
  58. # user: root
  59. # command: /usr/local/bin/cronstart
  60. # tty: true
  61. # links:
  62. # - db
  63. # volumes: *appvolumes
  64. volumes:
  65. appdata:
  66. dbdata:
  67. rabbitmqdata:
  68. sockdata:
  69. ssldata: