forked from open-telemetry/opentelemetry-demo
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[kafka] build kafka image (open-telemetry#617)
* build kafka image Signed-off-by: Pierre Tessier <pierre@pierretessier.com> * build kafka image Signed-off-by: Pierre Tessier <pierre@pierretessier.com> * build kafka image Signed-off-by: Pierre Tessier <pierre@pierretessier.com> * build kafka image Signed-off-by: Pierre Tessier <pierre@pierretessier.com> * build kafka image Signed-off-by: Pierre Tessier <pierre@pierretessier.com> Signed-off-by: Pierre Tessier <pierre@pierretessier.com>
- Loading branch information
Showing
5 changed files
with
46 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
FROM confluentinc/cp-kafka:latest-ubi8 | ||
|
||
USER appuser | ||
WORKDIR /tmp | ||
COPY ./src/kafka/clusterID clusterID | ||
COPY ./src/kafka/update_run.sh update_run.sh | ||
|
||
ENV KAFKA_LISTENERS=PLAINTEXT://0.0.0.0:9092,CONTROLLER://0.0.0.0:9093 | ||
ENV KAFKA_CONTROLLER_QUORUM_VOTERS='1@0.0.0.0:9093' | ||
ENV KAFKA_CONTROLLER_LISTENER_NAMES=CONTROLLER | ||
ENV KAFKA_LISTENER_SECURITY_PROTOCOL_MAP=CONTROLLER:PLAINTEXT,PLAINTEXT:PLAINTEXT | ||
ENV KAFKA_GROUP_INITIAL_REBALANCE_DELAY_MS=0 | ||
ENV KAFKA_PROCESS_ROLES=controller,broker | ||
ENV KAFKA_NODE_ID=1 | ||
ENV KAFKA_METADATA_LOG_SEGMENT_MS=15000 | ||
ENV KAFKA_METADATA_MAX_RETENTION_MS=1200000 | ||
ENV KAFKA_METADATA_LOG_MAX_RECORD_BYTES_BETWEEN_SNAPSHOTS=2800 | ||
ENV KAFKA_AUTO_CREATE_TOPICS_ENABLE=true | ||
ENV KAFKA_OFFSETS_TOPIC_REPLICATION_FACTOR=1 | ||
ENV KAFKA_TRANSACTION_STATE_LOG_REPLICATION_FACTOR=1 | ||
|
||
ENTRYPOINT ["/bin/sh", "-c", "ls -lh /tmp && /tmp/update_run.sh && /etc/confluent/docker/run"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
# Kafka | ||
|
||
This is used as a message queue service to connect the checkout service with | ||
the accounting and fraud detection services. | ||
|
||
## KRaft: Kafka without ZooKeeper | ||
|
||
Kafka is run in KRaft mode. The `update_run.sh` script is used to configure | ||
the system to run Kafka in this mode. Environment variables are substituted at | ||
deploy-time. |