-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
69 lines (64 loc) · 1.57 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
version: "2.2"
services:
# Kafka Cluster
# kafka-topics.sh --bootstrap-server localhost:9092 --list
# kafka-console-consumer.sh --bootstrap-server localhost:9092 --topic test
kafka:
image: wurstmeister/kafka
ports:
- "9092"
hostname: kafka
environment:
KAFKA_CREATE_TOPICS: "test_in:1:1,behavior:1:1" # topic:partition:replicas
KAFKA_ADVERTISED_HOST_NAME: kafka # docker-machine ip
KAFKA_ZOOKEEPER_CONNECT: zookeeper:2181
KAFKA_ADVERTISED_PORT: 9092
volumes:
- /var/run/docker.sock:/var/run/docker.sock
depends_on:
- zookeeper
container_name: kafka
# ZooKeeper Cluster
zookeeper:
image: wurstmeister/zookeeper
ports:
- "2181:2181"
hostname: zookeeper
container_name: zookeeper
# Flink Cluster
# flink-job-manager:
# image: flink:1.12.0-scala_2.11
# expose:
# - "6123"
# ports:
# - "8081:8081"
# command: jobmanager
# environment:
# - JOB_MANAGER_RPC_ADDRESS=jobmanager
# container_name: flink_job_manager
#
# flink-task-manager:
# image: flink:1.12.0-scala_2.11
# expose:
# - "6121"
# - "6122"
# depends_on:
# - jobmanager
# command: taskmanager
# links:
# - "jobmanager:jobmanager"
# environment:
# - JOB_MANAGER_RPC_ADDRESS=jobmanager
# container_name: flink_task_manager
# Data generator
data-generator:
build: ./data-generator/
depends_on:
- kafka
container_name: data_generator
# Flink job
flink-job:
build: ./flink-job/
depends_on:
- kafka
container_name: flink_job