-
Notifications
You must be signed in to change notification settings - Fork 5
/
docker-compose.yml
96 lines (88 loc) · 2.08 KB
/
docker-compose.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
88
89
90
91
92
93
94
95
96
version: "3.6"
services:
nginx:
container_name: ${APP_COMPOSE_PROJECT_NAME}_nginx
image: nginx
working_dir: '/app'
volumes:
- ./.docker/nginx/default.conf:/etc/nginx/conf.d/default.conf:ro
- ./:/app:ro
- nginx_logs:/var/log/nginx:rw
depends_on:
- php
ports:
- ${NGINX_PORT}:80
php:
container_name: ${APP_COMPOSE_PROJECT_NAME}_php
image: docker.local/${CI_PROJECT_PATH}/php${PHP_VER}-dev:${CI_COMMIT_REF_SLUG}
user: 1000:${UID}
volumes:
- ~/.composer/cache/:/.composer_cache/:rw
- ./:/app:rw
# ms sql specific
#- /etc/passwd:/etc/passwd:ro
#- /etc/group:/etc/group:ro
working_dir: /app
depends_on:
- mysql
- rabbitmq
env_file:
- .env
mysql:
container_name: ${APP_COMPOSE_PROJECT_NAME}_mysql
image: percona:5.7
volumes:
- ./.docker/mysql/config/my.cfg:/etc/my.cnf:ro
- ./.docker/mysql/initdb:/docker-entrypoint-initdb.d/:ro
- db_data:/var/lib/mysql/
- db_logs:/var/log/mysql/
ports:
- 3306:3306
healthcheck:
test: ["CMD", "mysqladmin" ,"ping", "-h", "localhost"]
timeout: 20s
retries: 10
env_file:
- .env
rabbitmq:
container_name: ${APP_COMPOSE_PROJECT_NAME}_rabbitmq
image: rabbitmq:3-management
volumes:
- rabbitmq_data:/var/lib/rabbitmq
ports:
- 15672:15672
healthcheck:
test: [ "CMD", "nc", "-z", "localhost", "5672" ]
interval: 10s
timeout: 10s
retries: 5
env_file:
- .env
memcached:
container_name: ${APP_COMPOSE_PROJECT_NAME}_memcached
image: memcached
ports:
- 11211:11211
healthcheck:
test: [ "CMD", "nc", "-z", "localhost", "11211" ]
interval: 10s
timeout: 10s
retries: 5
env_file:
- .env
phpmyadmin:
container_name: ${APP_COMPOSE_PROJECT_NAME}_phpmyadmin
image: phpmyadmin/phpmyadmin
links:
- mysql:db
ports:
- 9110:80
depends_on:
- mysql
env_file:
- .env
volumes:
db_data:
db_logs:
rabbitmq_data:
nginx_logs: