-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.2clouds.yaml
More file actions
50 lines (46 loc) · 1.36 KB
/
docker-compose.2clouds.yaml
File metadata and controls
50 lines (46 loc) · 1.36 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
# Test: 1 Enigma node + 2 RustFS backends (simulating 2 clouds)
# Usage:
# docker compose -f docker-compose.2clouds.yaml up --build
# # Upload a 4GB file via S3:
# aws --endpoint-url http://localhost:8333 s3 mb s3://test-bucket
# dd if=/dev/urandom of=/tmp/test-4g.bin bs=1M count=4096
# aws --endpoint-url http://localhost:8333 s3 cp /tmp/test-4g.bin s3://test-bucket/bigfile.bin
services:
# ── 2 RustFS backends (simulating 2 different clouds) ──
rustfs-1:
image: rustfs/rustfs:latest
command: ["/data"]
environment:
RUSTFS_ACCESS_KEY: enigma-key-1
RUSTFS_SECRET_KEY: enigma-secret-1
volumes:
- rustfs1-data:/data
ports:
- "19001:9000"
rustfs-2:
image: rustfs/rustfs:latest
command: ["/data"]
environment:
RUSTFS_ACCESS_KEY: enigma-key-2
RUSTFS_SECRET_KEY: enigma-secret-2
volumes:
- rustfs2-data:/data
ports:
- "19002:9000"
# ── Single Enigma node with replication_factor=2 ──
enigma:
build: .
depends_on: [rustfs-1, rustfs-2]
environment:
ENIGMA_PASSPHRASE: dev-passphrase
RUST_LOG: enigma=info
command: ["--config", "/etc/enigma/config.toml"]
volumes:
- enigma-data:/data
- ./dev/config-2clouds.toml:/etc/enigma/config.toml:ro
ports:
- "8333:8333"
volumes:
rustfs1-data:
rustfs2-data:
enigma-data: