-
Notifications
You must be signed in to change notification settings - Fork 32
/
docker-compose-step9.yml
155 lines (155 loc) · 4.1 KB
/
docker-compose-step9.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
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
version: "3"
services:
example:
image: ubuntu
command: bash -c 'echo $${RANDOM} ; sleep 1'
restart: always
elasticsearch:
image: docker.elastic.co/elasticsearch/elasticsearch:5.6.0
restart: on-failure
ports:
- "9200:9200"
- "9300:9300"
environment:
xpack.security.enabled: "false"
kibana:
image: docker.elastic.co/kibana/kibana:5.5.2
restart: on-failure
ports:
- "5601:5601"
environment:
xpack.security.enabled: "false"
depends_on:
- elasticsearch
kibana_index_pattern:
image: tutum/curl
command: |
bash -c "sleep 30 ; curl 'http://kibana:5601/es_admin/.kibana/index-pattern/logstash-*/_create' -H 'kbn-version: 5.5.2' -H 'content-type: application/json' --data-binary '{\"title\":\"logstash-*\",\"timeFieldName\":\"@timestamp\",\"notExpandable\":true}'"
depends_on:
- kibana
logstash:
image: logstash:5
restart: on-failure
command: -e "input { udp { port => 5000 codec => json } } filter { if [docker][image] =~ /^logstash/ { drop { } } } output { elasticsearch { hosts => "elasticsearch" } }"
depends_on:
- elasticsearch
logspout:
image: bekt/logspout-logstash
restart: on-failure
volumes:
- /var/run/docker.sock:/tmp/docker.sock
environment:
ROUTE_URIS: logstash://logstash:5000
depends_on:
- logstash
metricbeat:
image: docker.elastic.co/beats/metricbeat:5.6.3
volumes:
- /var/run/docker.sock:/tmp/docker.sock
depends_on:
- elasticsearch
metricbeat-dashboard-setup:
image: docker.elastic.co/beats/metricbeat:5.6.3
command: bash -c 'sleep 30; ./scripts/import_dashboards -es http://elasticsearch:9200'
depends_on:
- elasticsearch
influxdb:
image: influxdb:1.3.7
ports:
- "8086:8086"
telegraf:
image: telegraf:1.4.3
restart: on-failure
volumes:
- /var/run/docker.sock:/tmp/docker.sock
- ./telegraf/telegraf-with-kafka-output-and-jolokia-and-listener.conf:/etc/telegraf/telegraf.conf:ro
links:
- influxdb
- elasticsearch
- kafka
kapacitor:
image: kapacitor:1.3.3
hostname: kapacitor
environment:
KAPACITOR_HOSTNAME: kapacitor
KAPACITOR_INFLUXDB_0_URLS_0: http://influxdb:8086
depends_on:
- influxdb
chronograf:
image: chronograf:1.3.10
environment:
KAPACITOR_URL: http://kapacitor:9092
INFLUXDB_URL: http://influxdb:8086
ports:
- "8888:8888"
depends_on:
- influxdb
- kapacitor
grafana:
image: grafana/grafana:4.6.1
ports:
- "3000:3000"
depends_on:
- influxdb
- elasticsearch
grafana-setup:
build: grafana-setup/
depends_on:
- grafana
zookeeper:
image: wurstmeister/zookeeper:3.4.6
ports:
- "2181:2181"
kafka:
build: kafka-with-jolokia/
ports:
- "9092"
environment:
JOLOKIA_VERSION: 1.3.5
KAFKA_ZOOKEEPER_CONNECT: zookeeper:2181
KAFKA_OPTS: -javaagent:/usr/jolokia-1.3.5/agents/jolokia-jvm.jar=host=0.0.0.0
depends_on:
- zookeeper
slow-kafka-consumer:
image: framiere/slow-kafka-consumer
restart: on-failure
environment:
BOOTSTRAP_SERVERS: kafka:9092
TOPIC: telegraf
GROUP_ID: slow-consumer
depends_on:
- kafka
logging:
driver: none
fast-kafka-consumer:
image: wurstmeister/kafka:1.0.0
restart: on-failure
command: "kafka-console-consumer.sh --bootstrap-server kafka:9092 --topic telegraf --consumer-property group.id=fast-consumer"
depends_on:
- kafka
logging:
driver: none
slow-consumer-kafka-lag:
build: group-kafka-lag/
restart: on-failure
environment:
GROUP: slow-consumer
KAFKA_HOST: kafka
KAFKA_PORT: 9092
TELEGRAF_HOST: telegraf
TELEGRAF_PORT: 8094
depends_on:
- kafka
- telegraf
fast-consumer-kafka-lag:
build: group-kafka-lag/
restart: on-failure
environment:
GROUP: fast-consumer
KAFKA_HOST: kafka
KAFKA_PORT: 9092
TELEGRAF_HOST: telegraf
TELEGRAF_PORT: 8094
depends_on:
- kafka
- telegraf