-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathdocker-compose-connect.yml
88 lines (87 loc) · 3.15 KB
/
docker-compose-connect.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
services:
kafka-connect:
profiles:
- all
- kafka_connect
- kafka_connect_standalone
image: jpo-kafka-connect-mongo
build:
context: kafka-connect
dockerfile: Dockerfile
restart: ${RESTART_POLICY}
deploy:
resources:
limits:
cpus: '1'
memory: 4G
ports:
- "8083:8083"
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8083/connectors"]
interval: 30s
timeout: 10s
retries: 4
depends_on:
mongo:
condition: service_healthy
required: false
kafka:
condition: service_healthy
required: false
environment:
CONNECT_BOOTSTRAP_SERVERS: ${KAFKA_BOOTSTRAP_SERVERS}
CONNECT_REST_ADVERTISED_HOST_NAME: connect
CONNECT_REST_PORT: 8083
CONNECT_GROUP_ID: kafka-connect-group
# Topics are created with jikkou in the kafka-setup service
CONNECT_CONFIG_STORAGE_TOPIC: topic.KafkaConnectConfigs
CONNECT_CONFIG_STORAGE_REPLICATION_FACTOR: -1
CONNECT_OFFSET_FLUSH_INTERVAL_MS: 10000
CONNECT_OFFSET_STORAGE_TOPIC: topic.KafkaConnectOffsets
CONNECT_OFFSET_STORAGE_REPLICATION_FACTOR: -1
CONNECT_OFFSET_STORAGE_CLEANUP_POLICY: compact
CONNECT_STATUS_STORAGE_TOPIC: topic.KafkaConnectStatus
CONNECT_STATUS_STORAGE_CLEANUP_POLICY: compact
CONNECT_STATUS_STORAGE_REPLICATION_FACTOR: -1
CONNECT_KEY_CONVERTER: "org.apache.kafka.connect.json.JsonConverter"
CONNECT_VALUE_CONVERTER: "org.apache.kafka.connect.json.JsonConverter"
CONNECT_INTERNAL_KEY_CONVERTER: "org.apache.kafka.connect.json.JsonConverter"
CONNECT_INTERNAL_VALUE_CONVERTER: "org.apache.kafka.connect.json.JsonConverter"
CONNECT_LOG4J_ROOT_LOGLEVEL: ${CONNECT_LOG_LEVEL}
CONNECT_LOG4J_LOGGERS: "org.apache.kafka.connect.runtime.rest=${CONNECT_LOG_LEVEL},org.reflections=${CONNECT_LOG_LEVEL},com.mongodb.kafka=${CONNECT_LOG_LEVEL}"
CONNECT_PLUGIN_PATH: /usr/share/confluent-hub-components
kafka-connect-setup:
profiles:
- all
- kafka_connect
- kafka_connect_standalone
- kafka_connect_setup
image: jpo-jikkou
build:
context: jikkou
dockerfile: Dockerfile.jikkou
entrypoint: ./kafka_connector_init.sh
restart: on-failure
deploy:
resources:
limits:
cpus: '0.5'
memory: 1G
depends_on:
kafka-connect:
condition: service_healthy
required: false
environment:
CONNECT_URL: ${CONNECT_URL}
CONNECT_TASKS_MAX: ${CONNECT_TASKS_MAX}
CONNECT_CREATE_ODE: ${CONNECT_CREATE_ODE}
CONNECT_CREATE_GEOJSONCONVERTER: ${CONNECT_CREATE_GEOJSONCONVERTER}
CONNECT_CREATE_CONFLICTMONITOR: ${CONNECT_CREATE_CONFLICTMONITOR}
CONNECT_CREATE_DEDUPLICATOR: ${CONNECT_CREATE_DEDUPLICATOR}
CONNECT_CREATE_MECDEPOSIT: ${CONNECT_CREATE_MECDEPOSIT}
MONGO_CONNECTOR_USERNAME: ${MONGO_ADMIN_DB_USER}
MONGO_CONNECTOR_PASSWORD: ${MONGO_ADMIN_DB_PASS:?}
MONGO_DB_IP: ${MONGO_IP}
MONGO_DB_NAME: ${MONGO_DB_NAME}
volumes:
- ${CONNECT_CONFIG_RELATIVE_PATH-./jikkou/kafka-connectors-values.yaml}:/app/kafka-connectors-values.yaml