Skip to content
This repository has been archived by the owner on Oct 1, 2020. It is now read-only.

Updated to kafka version 2.2.0 #97

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions kafka/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# Kafka and Zookeeper

FROM java:openjdk-8-jre
FROM openjdk:8-jre-stretch

ENV DEBIAN_FRONTEND noninteractive
ENV SCALA_VERSION 2.11
ENV KAFKA_VERSION 0.10.1.0
ENV KAFKA_VERSION 2.2.0
ENV KAFKA_HOME /opt/kafka_"$SCALA_VERSION"-"$KAFKA_VERSION"

# Install Kafka, Zookeeper and other needed things
Expand All @@ -17,6 +17,7 @@ RUN apt-get update && \
rm /tmp/kafka_"$SCALA_VERSION"-"$KAFKA_VERSION".tgz

ADD scripts/start-kafka.sh /usr/bin/start-kafka.sh
RUN chmod +x /usr/bin/start-kafka.sh

# Supervisor config
ADD supervisor/kafka.conf supervisor/zookeeper.conf /etc/supervisor/conf.d/
Expand Down
4 changes: 2 additions & 2 deletions kafka/scripts/start-kafka.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,15 @@ if [ ! -z "$ADVERTISED_HOST" ]; then
if grep -q "^advertised.host.name" $KAFKA_HOME/config/server.properties; then
sed -r -i "s/#(advertised.host.name)=(.*)/\1=$ADVERTISED_HOST/g" $KAFKA_HOME/config/server.properties
else
echo "advertised.host.name=$ADVERTISED_HOST" >> $KAFKA_HOME/config/server.properties
echo "\n advertised.host.name=$ADVERTISED_HOST" >> $KAFKA_HOME/config/server.properties
fi
fi
if [ ! -z "$ADVERTISED_PORT" ]; then
echo "advertised port: $ADVERTISED_PORT"
if grep -q "^advertised.port" $KAFKA_HOME/config/server.properties; then
sed -r -i "s/#(advertised.port)=(.*)/\1=$ADVERTISED_PORT/g" $KAFKA_HOME/config/server.properties
else
echo "advertised.port=$ADVERTISED_PORT" >> $KAFKA_HOME/config/server.properties
echo "\n advertised.port=$ADVERTISED_PORT" >> $KAFKA_HOME/config/server.properties
fi
fi

Expand Down