-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
51 lines (51 loc) · 2.07 KB
/
Copy pathdocker-compose.yml
File metadata and controls
51 lines (51 loc) · 2.07 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
services:
postgres:
image: postgres:18@sha256:06cad38a5d9f5d24b4d83d86def30795d5e4b757fedbf5281172b576dedcd941
restart: unless-stopped
container_name: postgres
environment:
POSTGRES_DB: vdoc
POSTGRES_USER: vdoc
POSTGRES_PASSWORD: ${VDOC_DOCKER_POSTGRES_PASSWORD:?set VDOC_DOCKER_POSTGRES_PASSWORD}
TZ: Asia/Shanghai
volumes:
- ./data/docker/postgres:/var/lib/postgresql
ports:
- "${VDOC_DOCKER_PUBLISH_ADDRESS:-127.0.0.1}:${VDOC_DOCKER_POSTGRES_HOST_PORT:-5432}:5432"
healthcheck:
test: ["CMD-SHELL", "pg_isready -U $$POSTGRES_USER -d $$POSTGRES_DB"]
interval: 10s
timeout: 5s
retries: 5
rustfs:
image: rustfs/rustfs:1.0.0-beta.10@sha256:60f4f2f41ce95216f8cac676e69f9d90c0bfec458a3bc7fd7fb9b7c2452ac57a
restart: unless-stopped
container_name: rustfs
ports:
- "${VDOC_DOCKER_PUBLISH_ADDRESS:-127.0.0.1}:${VDOC_DOCKER_RUSTFS_HOST_PORT:-9000}:9000" # S3 API port
- "${VDOC_DOCKER_PUBLISH_ADDRESS:-127.0.0.1}:${VDOC_DOCKER_RUSTFS_CONSOLE_HOST_PORT:-9001}:9001" # Console port
environment:
- RUSTFS_VOLUMES=/data
- RUSTFS_ADDRESS=0.0.0.0:9000
- RUSTFS_CONSOLE_ADDRESS=0.0.0.0:9001
- RUSTFS_CONSOLE_ENABLE=true
- RUSTFS_CORS_ALLOWED_ORIGINS=${VDOC_DOCKER_RUSTFS_CORS_ALLOWED_ORIGINS:-http://127.0.0.1:9001,http://localhost:9001}
- RUSTFS_CONSOLE_CORS_ALLOWED_ORIGINS=${VDOC_DOCKER_RUSTFS_CONSOLE_CORS_ALLOWED_ORIGINS:-http://127.0.0.1:9001,http://localhost:9001}
- RUSTFS_ACCESS_KEY=${VDOC_DOCKER_RUSTFS_ACCESS_KEY:?set VDOC_DOCKER_RUSTFS_ACCESS_KEY}
- RUSTFS_SECRET_KEY=${VDOC_DOCKER_RUSTFS_SECRET_KEY:?set VDOC_DOCKER_RUSTFS_SECRET_KEY}
- RUSTFS_OBS_LOGGER_LEVEL=info
volumes:
- ./data/docker/rustfs/data:/data
- ./data/docker/rustfs/logs:/app/logs
healthcheck:
test:
[
"CMD",
"sh",
"-c",
"curl -f http://127.0.0.1:9000/health && curl -f http://127.0.0.1:9001/rustfs/console/health",
]
interval: 30s
timeout: 10s
retries: 3
start_period: 40s