-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
101 lines (94 loc) · 2.25 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
97
98
99
100
101
networks:
SymfonyStore:
services:
# nginx
nginx-service:
image: nginx:stable-alpine
container_name: nginx-container
ports:
- "8011:80"
volumes:
- ./app:/var/www/project
- ./logs:/var/log/nginx
- ./config/nginx/nginx.conf:/etc/nginx/conf.d/default.conf
depends_on:
- php-service
- mysql-service
networks:
- SymfonyStore
# php
php-service:
build:
context: .
dockerfile: ./config/php/Dockerfile
args:
- "UID=${UID:-1000}"
- "GID=${GID:-1000}"
container_name: php-container
ports:
- "9000:9000"
volumes:
- ./app:/var/www/project
- ./config/php/xdebug.ini:/usr/local/etc/php/conf.d/docker-php-ext-xdebug.ini
networks:
- SymfonyStore
# mysql
mysql-service:
image: mysql:8.3.0
container_name: mysql-container
ports:
- "3306:3306"
volumes:
- ./mysql:/var/lib/mysql
command: --default-authentication-plugin=mysql_native_password --character-set-server=utf8mb4 --collation-server=utf8mb4_unicode_ci
restart: always # always restart unless stopped manually
environment:
MYSQL_DATABASE: '${DB_NAME}'
MYSQL_ROOT_PASSWORD: '${DB_ROOT_PSWD}'
MYSQL_USER: '${DB_USER_NAME}'
MYSQL_PASSWORD: '${DB_USER_PSWD}'
networks:
- SymfonyStore
# phpmyadmin
phpmyadmin:
image: phpmyadmin
depends_on:
- mysql-service
restart: always
ports:
- "8080:80"
environment:
PMA_HOST: mysql-service
MYSQL_ROOT_PASSWORD: '${DB_ROOT_PSWD}'
networks:
- SymfonyStore
# node
node-service:
build:
context: .
dockerfile: ./config/node/Dockerfile
args:
- "UID=${UID:-1000}"
- "GID=${GID:-1000}"
container_name: node-container
volumes:
- ./app:/code
networks:
- SymfonyStore
# mailpit (For testing email sending/receiving)
mailpit:
image: axllent/mailpit
container_name: mailpit
restart: unless-stopped
volumes:
- ./data:/data
ports:
- 8025:8025
- 1025:1025
environment:
MP_MAX_MESSAGES: 5000
MP_DATABASE: /data/mailpit.db
MP_SMTP_AUTH_ACCEPT_ANY: 1
MP_SMTP_AUTH_ALLOW_INSECURE: 1
networks:
- SymfonyStore