-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathdocker-compose.test.yml
More file actions
64 lines (61 loc) · 1.48 KB
/
docker-compose.test.yml
File metadata and controls
64 lines (61 loc) · 1.48 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
services:
postgres-test:
image: postgres:17-alpine
container_name: voidrunner-test-db
environment:
POSTGRES_DB: voidrunner_test
POSTGRES_USER: testuser
POSTGRES_PASSWORD: testpassword
POSTGRES_INITDB_ARGS: ${POSTGRES_INITDB_ARGS:---encoding=UTF8 --lc-collate=C --lc-ctype=C}
ports:
- "5432:5432"
volumes:
- postgres_test_data:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U testuser -d voidrunner_test"]
interval: 10s
timeout: 5s
retries: 5
restart: unless-stopped
networks:
- voidrunner-test
deploy:
resources:
limits:
memory: 512M
cpus: '0.5'
reservations:
memory: 128M
cpus: '0.1'
redis-test:
image: redis:7-alpine
container_name: voidrunner-test-redis
ports:
- "6379:6379"
command: redis-server --appendonly yes --maxmemory ${REDIS_MAX_MEMORY:-256mb} --maxmemory-policy allkeys-lru
volumes:
- redis_test_data:/data
healthcheck:
test: ["CMD", "redis-cli", "ping"]
interval: 10s
timeout: 3s
retries: 5
restart: unless-stopped
networks:
- voidrunner-test
deploy:
resources:
limits:
memory: 256M
cpus: '0.25'
reservations:
memory: 64M
cpus: '0.05'
volumes:
postgres_test_data:
driver: local
redis_test_data:
driver: local
networks:
voidrunner-test:
driver: bridge