-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
45 lines (43 loc) · 1.12 KB
/
docker-compose.yml
File metadata and controls
45 lines (43 loc) · 1.12 KB
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
services:
mysql:
image: mysql:8.4
container_name: starquery-mysql
restart: unless-stopped
ports:
- "3307:3306"
environment:
MYSQL_ROOT_PASSWORD: root
MYSQL_DATABASE: starquery
MYSQL_USER: starquery
MYSQL_PASSWORD: starquery
volumes:
- mysql-data:/var/lib/mysql
- ./docker/mysql/init:/docker-entrypoint-initdb.d:ro
healthcheck:
test: ["CMD", "mysqladmin", "ping", "-h", "127.0.0.1", "-uroot", "-proot"]
interval: 5s
timeout: 5s
retries: 20
start_period: 15s
postgres:
image: postgres:17
container_name: starquery-postgres
restart: unless-stopped
ports:
- "5433:5432"
environment:
POSTGRES_DB: starquery
POSTGRES_USER: starquery
POSTGRES_PASSWORD: starquery
volumes:
- postgres-data:/var/lib/postgresql/data
- ./docker/postgres/init:/docker-entrypoint-initdb.d:ro
healthcheck:
test: ["CMD-SHELL", "pg_isready -h 127.0.0.1 -U starquery -d starquery"]
interval: 5s
timeout: 5s
retries: 20
start_period: 15s
volumes:
mysql-data:
postgres-data: