2017-01-05 02:37:20 +00:00
|
|
|
FROM openjdk:8u111-jre-alpine
|
2014-11-15 04:39:34 +00:00
|
|
|
|
|
|
|
MAINTAINER itzg
|
|
|
|
|
2016-11-05 01:18:43 +00:00
|
|
|
RUN apk -U add bash
|
2014-12-01 03:39:59 +00:00
|
|
|
|
2016-12-09 21:15:38 +00:00
|
|
|
ENV ES_VERSION=5.1.1
|
2016-11-05 01:18:43 +00:00
|
|
|
|
|
|
|
ADD https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-$ES_VERSION.tar.gz /tmp/es.tgz
|
2016-07-09 17:52:02 +00:00
|
|
|
RUN cd /usr/share && \
|
2014-11-15 04:39:34 +00:00
|
|
|
tar xf /tmp/es.tgz && \
|
|
|
|
rm /tmp/es.tgz
|
|
|
|
|
2016-07-09 17:52:02 +00:00
|
|
|
EXPOSE 9200 9300
|
2014-11-15 04:39:34 +00:00
|
|
|
|
2016-07-09 17:52:02 +00:00
|
|
|
ENV ES_HOME=/usr/share/elasticsearch-$ES_VERSION \
|
2016-11-05 01:18:43 +00:00
|
|
|
DEFAULT_ES_USER=elasticsearch \
|
|
|
|
DISCOVER_TRANSPORT_IP=eth0 \
|
2016-11-29 03:37:44 +00:00
|
|
|
DISCOVER_HTTP_IP=eth0 \
|
|
|
|
ES_JAVA_OPTS="-Xms1g -Xmx1g"
|
2014-11-15 04:39:34 +00:00
|
|
|
|
2016-07-09 17:52:02 +00:00
|
|
|
RUN adduser -S -s /bin/sh $DEFAULT_ES_USER
|
2014-11-15 04:39:34 +00:00
|
|
|
|
2016-07-09 17:52:02 +00:00
|
|
|
VOLUME ["/data","/conf"]
|
2014-11-15 04:39:34 +00:00
|
|
|
|
2016-07-09 17:52:02 +00:00
|
|
|
WORKDIR $ES_HOME
|
2015-10-30 00:58:28 +00:00
|
|
|
|
2017-01-05 02:37:20 +00:00
|
|
|
COPY java.policy /usr/lib/jvm/java-1.8-openjdk/jre/lib/security/
|
2016-11-05 01:18:43 +00:00
|
|
|
COPY start /start
|
|
|
|
COPY log4j2.properties $ES_HOME/config/
|
|
|
|
|
2014-11-15 04:39:34 +00:00
|
|
|
CMD ["/start"]
|