forked from distribworks/dkron
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
47 lines (44 loc) · 1.18 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
---
version: '2'
services:
# Uncomment to use etcd
etcd:
image: microbox/etcd
ports:
- "4001"
volumes:
- ./etcd.data:/data
command: -name=dkron1
consul:
image: consul
ports:
- "8500"
- "8300"
hostname: node1
command: agent -server -bootstrap -ui-dir=/ui -client=0.0.0.0
zk:
image: zookeeper
ports:
- "2181"
hostname: node1
dkron:
depends_on:
# Uncomment to use consul
#- consul
# Uncommend to use etcd
#- etcd
# Uncommend to use zk
- zk
ports:
- "8080"
build: .
volumes:
- ./:/gopath/src/github.com/victorcoder/dkron
environment:
- GODEBUG=netdns=go
# Uncomment to use consul
command: bash -c "go build *.go && ./main agent -server -backend=consul -backend-machine=consul:8500 -join=dkron:8946 -log-level=debug"
# Uncomment to use etcd
# command: bash -c "go build *.go && ./main agent -server -backend=etcd -backend-machine=etcd:4001 -join=dkron:8946 -log-level=debug"
# Uncomment to use zk
# command: bash -c "go build *.go && ./main agent -server -backend=zk -backend-machine=zk:2181 -join=dkron:8946 -log-level=debug"