-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yml
140 lines (129 loc) · 3.45 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
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
version: '3.7'
services:
zookeeper:
image: 'confluentinc/cp-zookeeper:6.2.4'
hostname: zookeeper
environment:
ZOOKEEPER_CLIENT_PORT: 2181
ZOOKEEPER_SERVER_ID: '1'
ZOOKEEPER_HEAP_OPTS: '-Xms1g -Xms1g'
networks:
- kapnet
kafkaserver:
image: 'confluentinc/cp-kafka:6.2.4'
hostname: kafkaserver
depends_on:
- zookeeper
environment:
KAFKA_BROKER_ID: 0
KAFKA_ZOOKEEPER_CONNECT: 'zookeeper:2181'
KAFKA_ADVERTISED_LISTENERS: 'PLAINTEXT://kafkaserver:9092'
KAFKA_DEFAULT_REPLICATION_FACTOR: 1
KAFKA_OFFSETS_TOPIC_REPLICATION_FACTOR: 1
KAFKA_TRANSACTION_STATE_LOG_REPLICATION_FACTOR: 1
KAFKA_CONFLUENT_BALANCER_TOPIC_REPLICATION_FACTOR: 1
KAFKA_CONFLUENT_METADATA_TOPIC_REPLICATION_FACTOR: 1
KAFKA_HEAP_OPTS: '-Xms1g -Xms1g'
networks:
- kapnet
fluentd:
build: ./fluentd
environment:
- FLUENTD_CONF=fluent.conf
volumes:
- './fluentd:/fluentd/etc'
ports:
- '9880:9880'
networks:
- kapnet
depends_on:
- kafkaserver
spark:
build: spark
environment:
- MAX_PROCESS=8
- TOKEN
- HTTPD_HOST
- KAFKA_HOSTS
- ELASTIC_HOST
- ELASTIC_PORT
- ELASTIC_PASSWORD
depends_on:
- kafkaserver
networks:
- kapnet
es_certs_setup:
image: 'elasticsearch:8.2.2'
user: '0'
command: bash -c "chmod 777 ./bootstrap/es-init.sh && ./bootstrap/es-init.sh"
environment:
- ELASTIC_PASSWORD
networks:
- kapnet
volumes:
- 'certs:/usr/share/elasticsearch/config/certs'
- './es-init.sh:/usr/share/elasticsearch/bootstrap/es-init.sh'
elasticsearch:
image: 'elasticsearch:8.2.2'
hostname: elasticsearch
ports:
- '9200:9200'
environment:
- node.name=es
- discovery.type=single-node
- ELASTIC_PASSWORD
- xpack.security.enabled=true
- xpack.security.http.ssl.enabled=true
- xpack.security.http.ssl.key=certs/es/es.key
- xpack.security.http.ssl.certificate=certs/es/es.crt
- xpack.security.http.ssl.certificate_authorities=certs/ca/ca.crt
- xpack.security.http.ssl.verification_mode=certificate
- xpack.security.transport.ssl.enabled=true
- xpack.security.transport.ssl.key=certs/es/es.key
- xpack.security.transport.ssl.certificate=certs/es/es.crt
- xpack.security.transport.ssl.certificate_authorities=certs/ca/ca.crt
- xpack.security.transport.ssl.verification_mode=certificate
- 'xpack.license.self_generated.type=${LICENSE}'
networks:
- kapnet
volumes:
- 'certs:/usr/share/elasticsearch/config/certs'
- 'esdata:/usr/share/elasticsearch/data'
bot:
build: bot
environment:
- FLUENTD_ADDRESS
- FLUENTD_PORT
- TOKEN
volumes:
- './storage:/frontend/storage'
httpd:
image: 'httpd:latest'
ports:
- '80:80'
volumes:
- './storage:/usr/local/apache2/htdocs'
grafana:
image: grafana/grafana
hostname: grafana
ports:
- '3000:3000'
environment:
- GF_SECURITY_ADMIN_PASSWORD
volumes:
- 'gfdata:/var/lib/grafana'
- 'certs:/etc/grafana/certs'
- './grafana/grafana.ini:/etc/grafana/grafana.ini'
networks:
- kapnet
volumes:
certs:
driver: local
esdata:
driver: local
gfdata:
driver: local
networks:
kapnet:
name: kapnet
driver: bridge