blob: 87e96ee0ad31c4b81801693852c7699e0ac064d8 [file] [log] [blame]
su622bf5b68992018-04-23 12:02:24 -04001FROM anapsix/alpine-java
2
3MAINTAINER Wurstmeister
4
5RUN apk add --update unzip wget curl docker jq coreutils
6
7ENV KAFKA_VERSION="0.8.1.1" SCALA_VERSION="2.9.2"
8ADD download-kafka.sh /tmp/download-kafka.sh
9RUN chmod a+x /tmp/download-kafka.sh && sync && /tmp/download-kafka.sh && tar xfz /tmp/kafka_${SCALA_VERSION}-${KAFKA_VERSION}.tgz -C /opt && rm /tmp/kafka_${SCALA_VERSION}-${KAFKA_VERSION}.tgz
10
11VOLUME ["/kafka"]
12
13ENV KAFKA_HOME /opt/kafka_${SCALA_VERSION}-${KAFKA_VERSION}
14ADD start-kafka.sh /usr/bin/start-kafka.sh
15ADD broker-list.sh /usr/bin/broker-list.sh
16ADD create-topics.sh /usr/bin/create-topics.sh
17# The scripts need to have executable permission
18RUN chmod a+x /usr/bin/start-kafka.sh && \
19 chmod a+x /usr/bin/broker-list.sh && \
20 chmod a+x /usr/bin/create-topics.sh
21# Use "exec" form so that it runs as PID 1 (useful for graceful shutdown)
22CMD ["start-kafka.sh"]