blob: 9f816ca94aedb7df70f61a5bd21014d1d27cf82c [file] [log] [blame]
Sergio Slobodrian61999e52017-04-03 19:09:11 -04001version: '2'
2services:
3 #
4 # Single-node zookeeper service
5 #
6 zookeeper:
7 image: wurstmeister/zookeeper
8 ports:
9 - "2181:2181"
10 environment:
11 SERVICE_2181_NAME: "zookeeper"
12 #
13 # Single-node kafka service
14 #
15 kafka:
16 image: wurstmeister/kafka
17 ports:
18 - "9092:9092"
19 environment:
20 KAFKA_ADVERTISED_HOST_NAME: ${DOCKER_HOST_IP}
21 KAFKA_ZOOKEEPER_CONNECT: zookeeper:2181
22 KAFKA_AUTO_CREATE_TOPICS_ENABLE: 'true'
23 KAFKA_HEAP_OPTS: "-Xmx256M -Xms128M"
24 SERVICE_9092_NAME: "kafka"
25 depends_on:
26 - consul
27 volumes:
28 - /var/run/docker.sock:/var/run/docker.sock
29 #
30 # Single-node consul agent
31 #
32 consul:
33 image: consul:latest
34 command: agent -server -bootstrap -client 0.0.0.0 -ui
35 ports:
36 - "8300:8300"
37 - "8400:8400"
38 - "8500:8500"
39 - "8600:8600/udp"
40 environment:
41 #SERVICE_53_IGNORE: "yes"
42 SERVICE_8300_IGNORE: "yes"
43 SERVICE_8400_IGNORE: "yes"
44 SERVICE_8500_NAME: "consul-rest"
45 #
46 # Registrator
47 #
48 registrator:
49 image: gliderlabs/registrator:latest
50 command: [
51 "-ip=${DOCKER_HOST_IP}",
52 "-retry-attempts", "100",
53 # "-internal",
54 "consul://consul:8500"
55 ]
56 links:
57 - consul
58 volumes:
59 - "/var/run/docker.sock:/tmp/docker.sock"
60
61 #
62 # Fluentd log server
63 #
64 fluentd:
65 image: fluent/fluentd
66 ports:
67 - "24224:24224"
68 volumes:
69 - "/tmp/fluentd:/fluentd/log"
70 environment:
71 SERVICE_24224_NAME: "fluentd-intake"
72
73 #
74 # Graphite-Grafana-statsd service instance
75 # (demo place-holder for external KPI system)
76 #
77 grafana:
78 image: kamon/grafana_graphite
79 ports:
80 - "8882:80"
81 - "2003:2003"
82 - "2004:2004"
83 - "8126:8126"
84 - "8125:8125/udp"
85 environment:
86 SERVICE_80_NAME: "grafana-web-ui"
87 SERVICE_2003_NAME: "carbon-plain-text-intake"
88 SERVICE_2004_NAME: "carbon-pickle-intake"
89 SERVICE_8126_NAME: "statsd-tcp-intake"
90 SERVICE_8125_NAME: "statsd-udp-intake"
91
92 #
93 # Shovel (Kafka-graphite-gateway)
94 #
95 shovel:
96 image: cord/shovel
97 command: [
98 "/shovel/shovel/main.py",
99 "--kafka=@kafka",
100 "--consul=${DOCKER_HOST_IP}:8500",
101 "--topic=voltha.kpis",
102 "--host=${DOCKER_HOST_IP}"
103 ]
104 depends_on:
105 - consul
106 - kafka
107 - grafana
108 restart: unless-stopped
109
110 #
111 # Voltha server instance(s)
112 #
113 voltha:
114 image: cord/voltha
115 command: [
116 "/voltha/voltha/main.py",
117 "-v",
118 "--consul=${DOCKER_HOST_IP}:8500",
119 "--fluentd=fluentd:24224",
120 "--rest-port=8880",
121 "--grpc-port=50555",
122 "--kafka=@kafka",
123 "--instance-id-is-container-name",
124 "--interface=eth1",
125 "-v"
126 ]
127 ports:
128 - 8880
129 - 50555
130 - 18880
131 depends_on:
132 - consul
133 links:
134 - consul
135 - fluentd
136 environment:
137 SERVICE_8880_NAME: "voltha-health"
138 SERVICE_8880_CHECK_HTTP: "/health"
139 SERVICE_8880_CHECK_INTERVAL: "5s"
140 SERVICE_8880_CHECK_TIMEOUT: "1s"
141 SERVICE_50555_NAME: "voltha-grpc"
142 SERVICE_18880_NAME: "voltha-sim-rest"
143 volumes:
144 - "/var/run/docker.sock:/tmp/docker.sock"
145 networks:
146 - default
147 - ponmgmt
148
149#############################################
150# Item below this line will soon be removed.#
151#############################################
152
153 #
154 # Chameleon server instance(s)
155 #
156 chameleon:
157 image: cord/chameleon
158 command: [
159 "/chameleon/chameleon/main.py",
160 "-v",
161 "--consul=consul:8500",
162 "--fluentd=fluentd:24224",
163 "--rest-port=8881",
164 "--grpc-endpoint=@voltha-grpc",
165 "--instance-id-is-container-name",
166 "-v"
167 ]
168 ports:
169 - "33533:8881"
170 depends_on:
171 - consul
172 - voltha
173 links:
174 - consul
175 - fluentd
176 environment:
177 SERVICE_8881_NAME: "chameleon-rest"
178 volumes:
179 - "/var/run/docker.sock:/tmp/docker.sock"
180 #
181 # ofagent server instance
182 #
183 ofagent:
184 image: cord/ofagent
185 command: [
186 "/ofagent/ofagent/main.py",
187 "-v",
188 "--consul=${DOCKER_HOST_IP}:8500",
189 "--fluentd=fluentd:24224",
190 "--controller=${DOCKER_HOST_IP}:6653",
191 "--grpc-endpoint=@voltha-grpc",
192 "--instance-id-is-container-name",
193 "-v"
194 ]
195 depends_on:
196 - consul
197 - voltha
198 links:
199 - consul
200 - fluentd
201 volumes:
202 - "/var/run/docker.sock:/tmp/docker.sock"
203 restart: unless-stopped
204
205 #
206 # Netconf server instance(s)
207 #
208 netconf:
209 image: cord/netconf
210 privileged: true
211 command: [
212 "/netconf/netconf/main.py",
213 "-v",
214 "--consul=${DOCKER_HOST_IP}:8500",
215 "--fluentd=fluentd:24224",
216 "--grpc-endpoint=@voltha-grpc",
217 "--instance-id-is-container-name",
218 "-v"
219 ]
220 ports:
221 - "830:1830"
222 depends_on:
223 - consul
224 - voltha
225 links:
226 - consul
227 - fluentd
228 environment:
229 SERVICE_1830_NAME: "netconf-server"
230 volumes:
231 - "/var/run/docker.sock:/tmp/docker.sock"
232
233 #
234 # Dashboard daemon
235 #
236 dashd:
237 image: cord/dashd
238 command: [
239 "/dashd/dashd/main.py",
240 "--kafka=@kafka",
241 "--consul=${DOCKER_HOST_IP}:8500",
242 "--grafana_url=http://admin:admin@${DOCKER_HOST_IP}:8882/api",
243 "--topic=voltha.kpis",
244 "--docker_host=${DOCKER_HOST_IP}"
245 ]
246 depends_on:
247 - consul
248 - kafka
249 - grafana
250 restart: unless-stopped
251
252networks:
253 default:
254 driver: bridge
255 ponmgmt:
256 driver: bridge
257 driver_opts:
258 com.docker.network.bridge.name: "ponmgmt"