From 5aafed586be0aade83a20928d0d45bb508521478 Mon Sep 17 00:00:00 2001 From: Nathanael Date: Wed, 22 Jan 2020 15:37:04 -0300 Subject: [PATCH] upgraded elasticsearch, logstash and kibana images and provided an environment variable to specify a version for the entire ELK stack. --- docker-compose.yml | 15 ++++++++++++--- elasticsearch/Dockerfile | 3 ++- env-example | 3 +++ kibana/Dockerfile | 3 ++- logstash/Dockerfile | 3 ++- 5 files changed, 21 insertions(+), 6 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index fdab1416..26bd2043 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -770,7 +770,10 @@ services: ### ElasticSearch ######################################## elasticsearch: - build: ./elasticsearch + build: + context: ./elasticsearch + args: + - ELK_VERSION=${ELK_VERSION} volumes: - elasticsearch:/usr/share/elasticsearch/data environment: @@ -794,7 +797,10 @@ services: ### Logstash ############################################## logstash: - build: ./logstash + build: + context: ./logstash + args: + - ELK_VERSION=${ELK_VERSION} volumes: - './logstash/config/logstash.yml:/usr/share/logstash/config/logstash.yml' - './logstash/pipeline:/usr/share/logstash/pipeline' @@ -812,7 +818,10 @@ services: ### Kibana ############################################## kibana: - build: ./kibana + build: + context: ./kibana + args: + - ELK_VERSION=${ELK_VERSION} ports: - "${KIBANA_HTTP_PORT}:5601" depends_on: diff --git a/elasticsearch/Dockerfile b/elasticsearch/Dockerfile index dcc28741..7d77e070 100644 --- a/elasticsearch/Dockerfile +++ b/elasticsearch/Dockerfile @@ -1,3 +1,4 @@ -FROM docker.elastic.co/elasticsearch/elasticsearch:7.1.1 +ARG ELK_VERSION=7.5.1 +FROM docker.elastic.co/elasticsearch/elasticsearch:${ELK_VERSION} EXPOSE 9200 9300 diff --git a/env-example b/env-example index c521fd04..46ad0047 100644 --- a/env-example +++ b/env-example @@ -848,3 +848,6 @@ GEARMAN_MYSQL_PASSWORD_FILE= GEARMAN_MYSQL_DB=Gearmand # Table to use by Gearman (Default: gearman_queue) GEARMAN_MYSQL_TABLE=gearman_queue + +### ELK Stack ################################################## +ELK_VERSION=7.5.1 diff --git a/kibana/Dockerfile b/kibana/Dockerfile index b831d6d0..46ef6539 100644 --- a/kibana/Dockerfile +++ b/kibana/Dockerfile @@ -1,3 +1,4 @@ -FROM docker.elastic.co/kibana/kibana:7.1.1 +ARG ELK_VERSION=7.5.1 +FROM docker.elastic.co/kibana/kibana:${ELK_VERSION} EXPOSE 5601 diff --git a/logstash/Dockerfile b/logstash/Dockerfile index a8c54527..161d381e 100644 --- a/logstash/Dockerfile +++ b/logstash/Dockerfile @@ -1,4 +1,5 @@ -FROM docker.elastic.co/logstash/logstash:6.4.2 +ARG ELK_VERSION=7.5.1 +FROM docker.elastic.co/logstash/logstash:${ELK_VERSION} USER root RUN rm -f /usr/share/logstash/pipeline/logstash.conf