-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yml
45 lines (42 loc) · 889 Bytes
/
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
version: "3.8"
services:
backend:
build: ./backend
ports:
- "8000:8000"
depends_on:
- mysql-db
environment:
- PORT=8000
- DB_HOST=mysql-db
- DB_USERNAME=root1
- DB_DBNAME=mydatabase
- DB_PASSWORD=1234
frontend:
build: ./frontend
ports:
- "3001:3000"
depends_on:
- backend
mysql-db:
image: mysql:latest
container_name: mysql-db
environment:
MYSQL_ROOT_PASSWORD: your_root_password
MYSQL_DATABASE: mydatabase
MYSQL_USER: root1
MYSQL_PASSWORD: 1234
ports:
- "33011:3306"
volumes:
- ./mysql-data:/var/lib/mysql
phpmyadmin:
image: phpmyadmin/phpmyadmin:latest
container_name: phpmyadmin
ports:
- "33012:80"
environment:
PMA_HOST: mysql-db
MYSQL_ROOT_PASSWORD: your_root_password
depends_on:
- mysql-db