-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathcompose.dev.yaml
More file actions
71 lines (67 loc) · 1.96 KB
/
Copy pathcompose.dev.yaml
File metadata and controls
71 lines (67 loc) · 1.96 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
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
services:
postgres:
image: postgres:18.2-bookworm
environment:
POSTGRES_DB: ${DB_NAME}
POSTGRES_USER: ${DB_USER}
POSTGRES_PASSWORD: ${DB_PASSWORD}
volumes:
- postgres_data:/var/lib/postgresql
restart: unless-stopped
ports:
- '127.0.0.1:${FORWARD_DB_PORT:-5432}:5432'
healthcheck:
test: ['CMD-SHELL', 'pg_isready -U ${DB_USER} -d ${DB_NAME}']
interval: 10s
timeout: 5s
retries: 5
redis:
image: valkey/valkey:9.0.2-alpine
command: ['valkey-server', '--appendonly', 'yes', '--requirepass', '${REDIS_PASSWORD}']
volumes:
- redis_data:/data
ports:
- '127.0.0.1:${FORWARD_REDIS_PORT:-6379}:6379'
restart: unless-stopped
healthcheck:
test: ['CMD', 'valkey-cli', '-a', '${REDIS_PASSWORD}', 'ping']
interval: 10s
timeout: 5s
retries: 5
minio:
image: minio/minio:latest
command: server /data --console-address ":9001"
environment:
MINIO_ROOT_USER: ${AWS_ACCESS_KEY_ID}
MINIO_ROOT_PASSWORD: ${AWS_SECRET_ACCESS_KEY}
volumes:
- minio_data:/data
ports:
- '127.0.0.1:${FORWARD_MINIO_PORT:-9000}:9000'
- '127.0.0.1:${FORWARD_MINIO_CONSOLE_PORT:-9001}:9001'
restart: unless-stopped
healthcheck:
test: ['CMD', 'mc', 'ready', 'local']
interval: 10s
timeout: 5s
retries: 5
createbuckets:
image: minio/mc:latest
depends_on:
minio:
condition: service_healthy
entrypoint: >
/bin/sh -c "
mc alias set myminio http://minio:9000 $${AWS_ACCESS_KEY_ID} $${AWS_SECRET_ACCESS_KEY};
mc mb myminio/$${AWS_STORAGE_BUCKET_NAME} --ignore-existing;
mc anonymous set download myminio/$${AWS_STORAGE_BUCKET_NAME};
exit 0;
"
environment:
AWS_ACCESS_KEY_ID: ${AWS_ACCESS_KEY_ID}
AWS_SECRET_ACCESS_KEY: ${AWS_SECRET_ACCESS_KEY}
AWS_STORAGE_BUCKET_NAME: ${AWS_STORAGE_BUCKET_NAME}
volumes:
postgres_data:
redis_data:
minio_data: