blob: 1f9aeb45edab8a155599bb71ff1a385091654f11 [file] [log] [blame]
Sergio Slobodrian61999e52017-04-03 19:09:11 -04001version: '2'
2services:
3 #
4 # Single-node zookeeper service
5 #
6 zookeeper:
David K. Bainbridgebba65ff2018-01-19 09:26:09 -08007 image: "${REGISTRY}wurstmeister/zookeeper:${ZK_TAG:-latest}"
Sergio Slobodrian61999e52017-04-03 19:09:11 -04008 ports:
9 - "2181:2181"
10 environment:
11 SERVICE_2181_NAME: "zookeeper"
12 #
13 # Single-node kafka service
14 #
15 kafka:
David K. Bainbridgebba65ff2018-01-19 09:26:09 -080016 image: "${REGISTRY}wurstmeister/kafka:${KAFKA_TAG:-latest}"
Sergio Slobodrian61999e52017-04-03 19:09:11 -040017 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:
Jonathan Hart87314cd2018-02-12 17:15:35 -080026 - vconsul
Sergio Slobodrian61999e52017-04-03 19:09:11 -040027 volumes:
28 - /var/run/docker.sock:/var/run/docker.sock
29 #
30 # Single-node consul agent
31 #
Jonathan Hart87314cd2018-02-12 17:15:35 -080032 vconsul:
David K. Bainbridgebba65ff2018-01-19 09:26:09 -080033 image: "${REGISTRY}consul:${CONSUL_TAG:-0.9.2}"
Sergio Slobodrian61999e52017-04-03 19:09:11 -040034 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:
David K. Bainbridgebba65ff2018-01-19 09:26:09 -080049 image: "${REGISTRY}gliderlabs/registrator:${REGISTRATOR_TAG:-latest}"
Sergio Slobodrian61999e52017-04-03 19:09:11 -040050 command: [
51 "-ip=${DOCKER_HOST_IP}",
52 "-retry-attempts", "100",
53 # "-internal",
Jonathan Hart87314cd2018-02-12 17:15:35 -080054 "consul://vconsul:8500"
Sergio Slobodrian61999e52017-04-03 19:09:11 -040055 ]
56 links:
Jonathan Hart87314cd2018-02-12 17:15:35 -080057 - vconsul
Sergio Slobodrian61999e52017-04-03 19:09:11 -040058 volumes:
59 - "/var/run/docker.sock:/tmp/docker.sock"
60
61 #
62 # Fluentd log server
63 #
64 fluentd:
David K. Bainbridge737b74f2018-01-22 12:57:52 -080065 image: "${REGISTRY}${REPOSITORY}voltha-fluentd:${TAG:-latest}"
Sergio Slobodrian61999e52017-04-03 19:09:11 -040066 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:
David K. Bainbridgebba65ff2018-01-19 09:26:09 -080078 image: "${REGISTRY}kamon/grafana_graphite:${GRAPHITE_TAG:-latest}"
Sergio Slobodrian61999e52017-04-03 19:09:11 -040079 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:
David K. Bainbridge737b74f2018-01-22 12:57:52 -080096 image: "${REGISTRY}${REPOSITORY}voltha-shovel:${TAG:-latest}"
Sergio Slobodrian61999e52017-04-03 19:09:11 -040097 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:
Jonathan Hart87314cd2018-02-12 17:15:35 -0800105 - vconsul
Sergio Slobodrian61999e52017-04-03 19:09:11 -0400106 - kafka
107 - grafana
108 restart: unless-stopped
109
110 #
111 # Voltha server instance(s)
112 #
113 voltha:
David K. Bainbridge737b74f2018-01-22 12:57:52 -0800114 image: "${REGISTRY}${REPOSITORY}voltha-voltha:${TAG:-latest}"
Sergio Slobodrian61999e52017-04-03 19:09:11 -0400115 command: [
116 "/voltha/voltha/main.py",
117 "-v",
118 "--consul=${DOCKER_HOST_IP}:8500",
Sergio Slobodrian61999e52017-04-03 19:09:11 -0400119 "--rest-port=8880",
120 "--grpc-port=50555",
121 "--kafka=@kafka",
122 "--instance-id-is-container-name",
123 "--interface=eth1",
124 "-v"
125 ]
126 ports:
127 - 8880
128 - 50555
129 - 18880
130 depends_on:
Jonathan Hart87314cd2018-02-12 17:15:35 -0800131 - vconsul
Sergio Slobodrian61999e52017-04-03 19:09:11 -0400132 links:
Jonathan Hart87314cd2018-02-12 17:15:35 -0800133 - vconsul
Sergio Slobodrian61999e52017-04-03 19:09:11 -0400134 environment:
135 SERVICE_8880_NAME: "voltha-health"
136 SERVICE_8880_CHECK_HTTP: "/health"
137 SERVICE_8880_CHECK_INTERVAL: "5s"
138 SERVICE_8880_CHECK_TIMEOUT: "1s"
139 SERVICE_50555_NAME: "voltha-grpc"
140 SERVICE_18880_NAME: "voltha-sim-rest"
141 volumes:
142 - "/var/run/docker.sock:/tmp/docker.sock"
143 networks:
144 - default
145 - ponmgmt
146
147#############################################
148# Item below this line will soon be removed.#
149#############################################
150
151 #
Sergio Slobodrian61999e52017-04-03 19:09:11 -0400152 # ofagent server instance
153 #
154 ofagent:
David K. Bainbridge737b74f2018-01-22 12:57:52 -0800155 image: "${REGISTRY}${REPOSITORY}voltha-ofagent:${TAG:-latest}"
Sergio Slobodrian61999e52017-04-03 19:09:11 -0400156 command: [
157 "/ofagent/ofagent/main.py",
158 "-v",
159 "--consul=${DOCKER_HOST_IP}:8500",
Sergio Slobodrian61999e52017-04-03 19:09:11 -0400160 "--controller=${DOCKER_HOST_IP}:6653",
161 "--grpc-endpoint=@voltha-grpc",
162 "--instance-id-is-container-name",
163 "-v"
164 ]
165 depends_on:
Jonathan Hart87314cd2018-02-12 17:15:35 -0800166 - vconsul
Sergio Slobodrian61999e52017-04-03 19:09:11 -0400167 - voltha
168 links:
Jonathan Hart87314cd2018-02-12 17:15:35 -0800169 - vconsul
Sergio Slobodrian61999e52017-04-03 19:09:11 -0400170 volumes:
171 - "/var/run/docker.sock:/tmp/docker.sock"
172 restart: unless-stopped
173
174 #
175 # Netconf server instance(s)
176 #
177 netconf:
David K. Bainbridge737b74f2018-01-22 12:57:52 -0800178 image: "${REGISTRY}${REPOSITORY}voltha-netconf:${TAG:-latest}"
Sergio Slobodrian61999e52017-04-03 19:09:11 -0400179 privileged: true
180 command: [
181 "/netconf/netconf/main.py",
182 "-v",
183 "--consul=${DOCKER_HOST_IP}:8500",
Sergio Slobodrian61999e52017-04-03 19:09:11 -0400184 "--grpc-endpoint=@voltha-grpc",
185 "--instance-id-is-container-name",
186 "-v"
187 ]
188 ports:
189 - "830:1830"
190 depends_on:
Jonathan Hart87314cd2018-02-12 17:15:35 -0800191 - vconsul
Sergio Slobodrian61999e52017-04-03 19:09:11 -0400192 - voltha
193 links:
Jonathan Hart87314cd2018-02-12 17:15:35 -0800194 - vconsul
Sergio Slobodrian61999e52017-04-03 19:09:11 -0400195 environment:
196 SERVICE_1830_NAME: "netconf-server"
197 volumes:
198 - "/var/run/docker.sock:/tmp/docker.sock"
199
200 #
201 # Dashboard daemon
202 #
203 dashd:
David K. Bainbridge737b74f2018-01-22 12:57:52 -0800204 image: "${REGISTRY}${REPOSITORY}voltha-dashd:${TAG:-latest}"
Sergio Slobodrian61999e52017-04-03 19:09:11 -0400205 command: [
206 "/dashd/dashd/main.py",
207 "--kafka=@kafka",
208 "--consul=${DOCKER_HOST_IP}:8500",
209 "--grafana_url=http://admin:admin@${DOCKER_HOST_IP}:8882/api",
210 "--topic=voltha.kpis",
211 "--docker_host=${DOCKER_HOST_IP}"
212 ]
213 depends_on:
Jonathan Hart87314cd2018-02-12 17:15:35 -0800214 - vconsul
Sergio Slobodrian61999e52017-04-03 19:09:11 -0400215 - kafka
216 - grafana
217 restart: unless-stopped
218
219networks:
220 default:
221 driver: bridge
222 ponmgmt:
223 driver: bridge
224 driver_opts:
225 com.docker.network.bridge.name: "ponmgmt"