-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
45 lines (42 loc) · 990 Bytes
/
Copy pathdocker-compose.yml
File metadata and controls
45 lines (42 loc) · 990 Bytes
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
version: '3.8'
services:
main:
platform: linux/amd64
container_name: main
build:
context: .
target: development
volumes:
- .:/usr/src/app
- /usr/src/app/node_modules
ports:
- 3000:3000
command: npm run start:dev
env_file:
- ./app.env
depends_on:
- db
db:
platform: linux/amd64
container_name: football_ranking_mysql
command: --default-authentication-plugin=mysql_native_password
restart: always
image: mysql:8
environment:
- MYSQL_DATABASE=football_ranking
- MYSQL_ROOT_PASSWORD=example
- MYSQL_USER=demo
- MYSQL_PASSWORD=password
- MYSQL_ALLOW_EMPTY_PASSWORD=yes
ports:
- 3306:3306
expose:
- '3306'
healthcheck:
test: ["CMD", "mysqladmin" ,"ping", "-h", "localhost"]
timeout: 20s
retries: 10
volumes:
- football_ranking_mysql_data:/var/lib/mysql
volumes:
football_ranking_mysql_data: