-
Notifications
You must be signed in to change notification settings - Fork 3
/
docker-compose.yml
98 lines (91 loc) · 2.31 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
services:
webserver:
container_name: webserver
image: nginx:latest
ports:
- "80:80"
- "8000:8000"
volumes:
- ./nginx/conf.d/default.conf:/etc/nginx/conf.d/default.conf:ro
- ./:/var/www/html
build:
context: .
target: nginx-stage
depends_on:
- php
- node
networks:
- app-network
php:
container_name: php
image: php:8.1-fpm
restart: unless-stopped
tty: true
working_dir: /var/www/html
build:
context: .
target: php-stage
depends_on:
- mariadb
- redis
volumes:
- ./:/var/www/html
- ./entrypoint.sh:/root/entrypoint.sh
networks:
- app-network
command: ["/root/entrypoint.sh"]
node:
container_name: node
image: node:22.2.0
build:
context: .
target: node-stage
entrypoint:
- /var/www/html/entrypoint_node.sh
volumes:
- ./:/var/www/html
expose:
- "80"
networks:
- app-network
environment:
- NODE_ENV=development
mariadb:
container_name: mariadb
image: mariadb:10.5
ports:
- "3306:3306"
environment:
- MARIADB_ROOT_PASSWORD=root
- MARIADB_DATABASE=laravel
- MARIADB_USER=user
- MARIADB_PASSWORD=password
volumes:
- mariadb-data:/var/lib/mariadb
- ./mysql/healthcheck.sh:/root/healthcheck-mysql.sh
networks:
- app-network
phpmyadmin:
container_name: phpmyadmin
image: phpmyadmin:latest
ports:
- 9015:80
environment:
- PMA_ARBITRARY=1
networks:
- app-network
redis:
container_name: redis
image: redis:latest
command: ["redis-server", "/etc/redis/redis.conf"]
ports:
- "6379:6379"
volumes:
- ./docker/redis/.conf/redis.conf:/etc/redis/redis.conf
- ./docker/redis/data:/var/lib/redis/
networks:
- app-network
volumes:
mariadb-data:
networks:
app-network: