-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yml
97 lines (90 loc) · 3.11 KB
/
docker-compose.yml
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
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
version: "3.7"
services:
worker:
image: riot/murdock-worker:latest
init: true
tmpfs:
- /tmp:exec,size=${MURDOCK_BUILD_TMPFS_GIGS}g,rw
volumes:
- cache:/cache
- redis-ccache:/cache/redis
- ./scripts/murdock-worker.sh:/murdock-worker.sh
environment:
- CCACHE="ccache"
- CCACHE_DIR=/cache/.ccache
- CCACHE_REMOTE_ONLY=1
- CCACHE_REMOTE_STORAGE=redis+unix:/cache/redis/redis-ccache.sock
- GIT_CACHE_DIR=/cache/.gitcache
- MURDOCK_HOSTNAME=${MURDOCK_HOSTNAME}
- MURDOCK_REDIS_HOST=ssh_bridge
- JOBS=${MURDOCK_JOBS:-4}
- DWQ_DISQUE_URL=ssh_bridge:7711
user: "999"
entrypoint:
- /murdock-worker.sh
command: dwqw --name ${MURDOCK_HOSTNAME} --queues ${MURDOCK_HOSTNAME} ${MURDOCK_QUEUES:-defaultx} --jobs 1 --verbose
restart: unless-stopped
labels:
- com.centurylinklabs.watchtower.scope=murdock-worker-${MURDOCK_HOSTNAME}
redis-ccache:
image: redis
environment:
- MURDOCK_CCACHE_MAXSIZE_GIGS=${MURDOCK_CCACHE_MAXSIZE_GIGS:-8}
command: redis-server --save "" --maxmemory ${MURDOCK_CCACHE_MAXSIZE_GIGS}G --maxmemory-policy allkeys-lru --unixsocket /data/redis-ccache.sock
restart: unless-stopped
volumes:
- redis-ccache:/data
labels:
- com.centurylinklabs.watchtower.scope=murdock-worker-${MURDOCK_HOSTNAME}
ssh_bridge:
# any image that has autossh+ssh would do, but we're pulling
# `murdock-worker:latest` anyways.
image: riot/murdock-worker:latest
volumes:
- ./ssh:/ssh:ro
- ./scripts/ssh_bridge.sh:/ssh_bridge.sh
environment:
- MURDOCK_REMOTE_DISQUE_HOST_PORT=${MURDOCK_REMOTE_DISQUE_HOST_PORT:-disque:7711}
- MURDOCK_REMOTE_REDIS_HOST_PORT=${MURDOCK_REMOTE_REDIS_HOST_PORT:-redis:6379}
- MURDOCK_REMOTE_VECTOR_HOST_PORT=${MURDOCK_REMOTE_VECTOR_HOST_PORT:-vector:8687}
- MURDOCK_SSH_HOST=${MURDOCK_SSH_HOST:-ci-staging}
entrypoint: /ssh_bridge.sh
restart: unless-stopped
labels:
- com.centurylinklabs.watchtower.scope=murdock-worker-${MURDOCK_HOSTNAME}
watchtower:
image: containrrr/watchtower
volumes:
- /var/run/docker.sock:/var/run/docker.sock
environment:
- WATCHTOWER_SCOPE=murdock-worker-${MURDOCK_HOSTNAME}
- WATCHTOWER_POLL_INTERVAL=${WATCHTOWER_POLL_INTERVAL:-60}
- WATCHTOWER_CLEANUP=true
restart: unless-stopped
vector:
hostname: ${MURDOCK_HOSTNAME}
image: timberio/vector:0.28.0-alpine
restart: unless-stopped
environment:
- MURDOCK_HOSTNAME=${MURDOCK_HOSTNAME}
- MURDOCK_SSH_HOST=${MURDOCK_SSH_HOST:-ci-staging}
volumes:
- ./vector.toml:/etc/vector/vector.toml:ro
ports:
- "8686:8686"
labels:
- com.centurylinklabs.watchtower.scope=murdock-worker-${MURDOCK_HOSTNAME}
redis_exporter:
image: oliver006/redis_exporter
restart: unless-stopped
volumes:
- redis-ccache:/redis-ccache
ports:
- "9121:9121"
environment:
- REDIS_ADDR=redis://redis-ccache:6379
labels:
- com.centurylinklabs.watchtower.scope=murdock-worker-${MURDOCK_HOSTNAME}
volumes:
cache:
redis-ccache: