This repository has been archived by the owner on Feb 9, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathdocker-compose.magento.yml
87 lines (81 loc) · 2.01 KB
/
docker-compose.magento.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
version: '3.7'
services:
db:
hostname: db.magento2.docker
container_name: ${COMPOSE_PROJECT_NAME}-db
image: '${DATABASE_IMAGE}'
shm_size: 2gb
environment:
- MYSQL_ROOT_PASSWORD=${COMPOSE_PROJECT_NAME}1234
- MYSQL_DATABASE=${COMPOSE_PROJECT_NAME}
- MYSQL_USER=${COMPOSE_PROJECT_NAME}
- MYSQL_PASSWORD=${COMPOSE_PROJECT_NAME}1234
ports:
- "${DATABASE_PORT:-3306}:3306"
volumes:
- 'magento-db:/var/lib/mysql'
healthcheck:
test: 'mysqladmin ping -h localhost -p${COMPOSE_PROJECT_NAME}1234'
interval: 30s
timeout: 30s
retries: 3
networks:
magento:
aliases:
- db.magento2.docker
redis:
hostname: redis.magento2.docker
container_name: ${COMPOSE_PROJECT_NAME}-redis
image: '${REDIS_IMAGE}'
ports:
- "${REDIS_PORT:-6379}:6379"
sysctls:
net.core.somaxconn: 1024
ulimits:
nproc: 65535
nofile:
soft: 20000
hard: 40000
healthcheck:
test: 'redis-cli ping || exit 1'
interval: 30s
timeout: 30s
retries: 3
networks:
magento:
aliases:
- redis.magento2.docker
elasticsearch:
hostname: elasticsearch.magento2.docker
container_name: ${COMPOSE_PROJECT_NAME}-elasticsearch
image: '${ELASTICSEARCH_IMAGE}'
ulimits:
memlock:
soft: -1
hard: -1
environment:
- cluster.name=docker-cluster
- bootstrap.memory_lock=true
ports:
- "${ELASTICSEARCH_PORT:-9200}:9200"
networks:
magento:
aliases:
- elasticsearch.magento2.docker
rabbitmq:
hostname: rabbitmq.magento2.docker
container_name: ${COMPOSE_PROJECT_NAME}-rabbitmq
image: '${RABBITMQ_IMAGE}'
ports:
- "${RABBITMQ_PORT:-15672}:15672"
- "${RABBITMQ_WEB_PORT:-5672}:5672"
networks:
magento:
aliases:
- rabbitmq.magento2.docker
volumes:
magento-db:
name: ${COMPOSE_PROJECT_NAME}-magento-db
networks:
magento:
driver: bridge