blob: 55063da79bacb178adce6760f9becabc1be67a48 [file] [log] [blame]
schowdhury33763f42017-06-09 02:05:42 -07001version: '2'
2services:
3 #
4 # Single-node zookeeper service
5 #
6 zookeeper:
7 image: wurstmeister/zookeeper
8 ports:
9 - 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
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:
schowdhury40739212017-06-12 07:40:31 -070033 image: voltha/consul
schowdhurya260f5b2017-06-14 15:54:25 -070034 command: agent -server -bootstrap -client 0.0.0.0 -ui
schowdhury33763f42017-06-09 02:05:42 -070035 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"
schowdhury33763f42017-06-09 02:05:42 -070045 #
46 # Registrator
47 #
48 registrator:
schowdhury40739212017-06-12 07:40:31 -070049 image: voltha/registrator
schowdhury33763f42017-06-09 02:05:42 -070050 command: [
51 "-ip=${DOCKER_HOST_IP}",
52 "-retry-attempts", "100",
53 # "-internal",
schowdhurya260f5b2017-06-14 15:54:25 -070054 "consul-tls://consul:8501"
schowdhury33763f42017-06-09 02:05:42 -070055 ]
56 links:
57 - consul
58 volumes:
59 - "/var/run/docker.sock:/tmp/docker.sock"
schowdhury33763f42017-06-09 02:05:42 -070060 environment:
61 CONSUL_CACERT: "/reg/config/voltha-CA-template.pem"
schowdhurya260f5b2017-06-14 15:54:25 -070062 CONSUL_CLIENT_CERT: "/reg/config/voltha-cert-template.crt"
63 CONSUL_CLIENT_KEY: "/reg/config/voltha-pvt-template.key"
schowdhury33763f42017-06-09 02:05:42 -070064
65 #
66 # Fluentd log server
67 #
68 fluentd:
69 image: fluent/fluentd
70 ports:
71 - "24224:24224"
72 volumes:
73 - "/tmp/fluentd:/fluentd/log"
74 environment:
75 SERVICE_24224_NAME: "fluentd-intake"
76
77 #
78 # Graphite-Grafana-statsd service instance
79 # (demo place-holder for external KPI system)
80 #
81 grafana:
82 image: voltha/grafana
83 ports:
84 - "8882:80"
85 - "2003:2003"
86 - "2004:2004"
87 - "8126:8126"
88 - "8125:8125/udp"
89 environment:
90 SERVICE_80_NAME: "grafana-web-ui"
91 SERVICE_2003_NAME: "carbon-plain-text-intake"
92 SERVICE_2004_NAME: "carbon-pickle-intake"
93 SERVICE_8126_NAME: "statsd-tcp-intake"
94 SERVICE_8125_NAME: "statsd-udp-intake"
95 GR_SERVER_ROOT_URL: "http://localhost:80/grafana/"
96
97 #
98 # Shovel (Kafka-graphite-gateway)
99 #
100 shovel:
101 image: cord/shovel
102 command: [
103 "/shovel/shovel/main.py",
104 "--kafka=@kafka",
105 "--consul=${DOCKER_HOST_IP}:8500",
106 "--topic=voltha.kpis",
107 "--host=${DOCKER_HOST_IP}"
108 ]
109 depends_on:
110 - consul
111 - kafka
112 - grafana
113 restart: unless-stopped
114
115 #
116 # Voltha server instance(s)
117 #
118 voltha:
119 image: cord/voltha
120 command: [
121 "/voltha/voltha/main.py",
122 "-v",
123 "--consul=${DOCKER_HOST_IP}:8500",
124 "--fluentd=fluentd:24224",
125 "--rest-port=8880",
126 "--grpc-port=50555",
127 "--kafka=@kafka",
128 "--instance-id-is-container-name",
129 "--interface=eth1",
130 "-v"
131 ]
132 ports:
133 - 8880
134 - 50555
135 - 18880
136 depends_on:
137 - consul
138 links:
139 - consul
140 - fluentd
141 environment:
142 SERVICE_8880_NAME: "voltha-health"
143 SERVICE_8880_CHECK_HTTP: "/health"
144 SERVICE_8880_CHECK_INTERVAL: "5s"
145 SERVICE_8880_CHECK_TIMEOUT: "1s"
146 SERVICE_50555_NAME: "voltha-grpc"
147 SERVICE_18880_NAME: "voltha-sim-rest"
148 volumes:
149 - "/var/run/docker.sock:/tmp/docker.sock"
150 networks:
151 - default
152 - ponmgmt
153
154 #
155 # Voltha cli container
156 #
157 vcli:
158 image: cord/vcli
Richard Jankowski29dd1982017-06-28 13:30:18 -0400159 command: [
160 "/cli/cli/setup.sh",
161 "-L"
162 ]
schowdhury33763f42017-06-09 02:05:42 -0700163 environment:
164 DOCKER_HOST_IP: "${DOCKER_HOST_IP}"
165 ports:
166 - "5022:22"
167 depends_on:
168 - voltha
169
170#############################################
171# Item below this line will soon be removed.#
172#############################################
173
174 #
175 # Chameleon server instance(s)
176 #
177 chameleon:
178 image: cord/chameleon
179 command: [
180 "/chameleon/chameleon/main.py",
181 "-v",
182 "--consul=consul:8500",
183 "--fluentd=fluentd:24224",
184 "--rest-port=8881",
185 "--grpc-endpoint=@voltha-grpc",
186 "--instance-id-is-container-name",
187 "-v"
188 ]
189 ports:
190 - 8881
191 depends_on:
192 - consul
193 - voltha
194 links:
195 - consul
196 - fluentd
197 environment:
198 SERVICE_8881_NAME: "chameleon-rest"
199 volumes:
200 - "/var/run/docker.sock:/tmp/docker.sock"
201 #
202 # ofagent server instance
203 #
204 ofagent:
205 image: cord/ofagent
206 command: [
207 "/ofagent/ofagent/main.py",
208 "-v",
209 "--consul=${DOCKER_HOST_IP}:8500",
210 "--fluentd=fluentd:24224",
211 "--controller=${DOCKER_HOST_IP}:6653",
212 "--grpc-endpoint=@voltha-grpc",
213 "--instance-id-is-container-name",
214 "-v"
215 ]
216 depends_on:
217 - consul
218 - voltha
219 links:
220 - consul
221 - fluentd
222 volumes:
223 - "/var/run/docker.sock:/tmp/docker.sock"
224 restart: unless-stopped
225
226 #
227 # Netconf server instance(s)
228 #
229 netconf:
230 image: cord/netconf
231 privileged: true
232 command: [
233 "/netconf/netconf/main.py",
234 "-v",
235 "--consul=${DOCKER_HOST_IP}:8500",
236 "--fluentd=fluentd:24224",
237 "--grpc-endpoint=@voltha-grpc",
238 "--instance-id-is-container-name",
239 "-v"
240 ]
241 ports:
242 - "830:1830"
243 depends_on:
244 - consul
245 - voltha
246 links:
247 - consul
248 - fluentd
249 environment:
250 SERVICE_1830_NAME: "netconf-server"
251 volumes:
252 - "/var/run/docker.sock:/tmp/docker.sock"
253
254 #
255 # Dashboard daemon
256 #
257 dashd:
258 image: cord/dashd
259 command: [
260 "/dashd/dashd/main.py",
261 "--kafka=@kafka",
262 "--consul=${DOCKER_HOST_IP}:8500",
263 "--grafana_url=http://admin:admin@${DOCKER_HOST_IP}:8882/api",
264 "--topic=voltha.kpis",
265 "--docker_host=${DOCKER_HOST_IP}"
266 ]
267 depends_on:
268 - consul
269 - kafka
270 - grafana
271 restart: unless-stopped
272
273 #
274 # Nginx service consolidation
275 #
276 nginx:
277 image: voltha/nginx
278 ports:
279 - "80:80"
280 environment:
281 CONSUL_ADDR: "${DOCKER_HOST_IP}:8500"
282 command: [
283 "/nginx_config/start_service.sh"
284 ]
285 depends_on:
286 - consul
287 - grafana
288 - chameleon
289 - portainer
290 restart: unless-stopped
291 volumes:
schowdhurya260f5b2017-06-14 15:54:25 -0700292 - "/home/cord/cord/incubator/voltha/nginx_config:/nginx_config"
schowdhury33763f42017-06-09 02:05:42 -0700293
294 #
295 # Docker ui
296 #
297 portainer:
298 image: voltha/portainer
299 ports:
300 - "9000:9000"
301 environment:
302 CONSUL_ADDR: "${DOCKER_HOST_IP}:8500"
303 restart: unless-stopped
304 entrypoint: ["/portainer", "--logo", "/docker/images/logo_alt.png"]
305 volumes:
306 - "/var/run/docker.sock:/var/run/docker.sock"
307
308networks:
309 default:
310 driver: bridge
311 ponmgmt:
312 driver: bridge
313 driver_opts:
314 com.docker.network.bridge.name: "ponmgmt"