-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
49 lines (45 loc) · 1004 Bytes
/
docker-compose.yml
File metadata and controls
49 lines (45 loc) · 1004 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
46
47
48
49
version: '3.8'
services:
mailbox:
build:
context: .
dockerfile: Dockerfile
ports:
- "8080:8080"
- "25:25"
environment:
- DB_HOST=mysql
- DB_PORT=3306
- DB_USER=mailbox
- DB_PASSWORD=mailbox123
- DB_NAME=mailbox
- ADMIN_USERNAME=admin
- ADMIN_PASSWORD=admin123
- JWT_SECRET=${JWT_SECRET:?JWT_SECRET is required}
depends_on:
mysql:
condition: service_healthy
restart: unless-stopped
networks:
- mailbox-network
mysql:
image: mysql:8.0
environment:
- MYSQL_ROOT_PASSWORD=root123
- MYSQL_DATABASE=mailbox
- MYSQL_USER=mailbox
- MYSQL_PASSWORD=mailbox123
volumes:
- mysql_data:/var/lib/mysql
restart: unless-stopped
healthcheck:
test: ["CMD", "mysqladmin", "ping", "-h", "localhost"]
timeout: 5s
retries: 10
networks:
- mailbox-network
networks:
mailbox-network:
driver: bridge
volumes:
mysql_data: