Last active
March 30, 2016 20:11
-
-
Save bladedoyle/74253aa6b80d4eb02530ccc985648dcc to your computer and use it in GitHub Desktop.
Dockerfile for Elasticsearch 2.3.0 on ARM
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
FROM armv7/armhf-debian | |
# setup debian sources | |
ENV DEBIAN_FRONTEND noninteractive | |
RUN apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 9165938D90FDDD2E && \ | |
apt-get -y update && \ | |
apt-get -y upgrade && \ | |
apt-get -y --force-yes install sudo wget | |
ADD ejdk-8u77-linux-armv6-vfp-hflt.tar.gz / | |
RUN ln -s /ejdk1.8.0_77/linux_armv6_vfp_hflt/jre/bin /usr/bin/java | |
# Install elasticsearch package | |
RUN wget --quiet https://download.elasticsearch.org/elasticsearch/release/org/elasticsearch/distribution/deb/elasticsearch/2.3.0/elasticsearch-2.3.0.deb && \ | |
dpkg -i /elasticsearch-2.3.0.deb && \ | |
rm elasticsearch-2.3.0.deb | |
ENV PATH /usr/share/elasticsearch/bin:/ejdk1.8.0_77/linux_armv6_vfp_hflt/compact3/bin:$PATH | |
WORKDIR /usr/share/elasticsearch | |
# Config es | |
RUN mkdir -p /usr/share/elasticsearch/config && \ | |
mkdir -p /usr/share/elasticsearch/config/scripts && \ | |
mkdir -p /usr/share/elasticsearch/data && \ | |
mkdir -p /usr/share/elasticsearch/logs && \ | |
chown -R elasticsearch.elasticsearch /usr/share/elasticsearch | |
ADD elasticsearch.yaml /usr/share/elasticsearch/config/elasticsearch.yaml | |
ADD logging.yaml /usr/share/elasticsearch/config/logging.yaml | |
ENV ES_HEAP_SIZE 256m | |
ENV JAVA_HOME /ejdk1.8.0_77/linux_armv6_vfp_hflt/compact3 | |
# startup | |
CMD ["/usr/bin/sudo", "-E", "-u", "elasticsearch", "/usr/share/elasticsearch/bin/elasticsearch"] | |
EXPOSE 9200/tcp 9300/tcp |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
ejdk-8u77-linux-armv6-vfp-hflt.tgz comes from Oracle:
http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html
elasticsearch.yaml and logging.yaml are included within the elasticsearch package, and only need to be added if customized.