Install Elasticsearch plugins with docker

By | 2021년 11월 6일
Table of Content

Install Elasticsearch plugins with docker

참조

도커 컨테이너로 운영되는 Elasticsearch 에 플러그인을 설치하는 방법을 설명합니다.

파라미터로 전달하는 방식은 없는 듯 하고, 도커 이미지를 생성해야 하는 듯 합니다.

Dockerfile 생성

vi Dockerfile
----------------------------
FROM docker.elastic.co/elasticsearch/elasticsearch:7.15.0

RUN /usr/share/elasticsearch/bin/elasticsearch-plugin install --batch https://github.com/skyer9/elasticsearch-jaso-analyzer/releases/download/v7.15.0/jaso-analyzer-plugin-7.15.0-plugin.zip
----------------------------

이미지 생성

docker build -t skyer9/elasticsearch-jaso-analyzer:7.15.0 .

도커 서버에 푸시

docker login
docker push skyer9/elasticsearch-jaso-analyzer:7.15.0

analysis-icu, analysis-nori 추가

analysis-icu, analysis-nori 를 추가합니다.

vi Dockerfile
----------------------------
FROM docker.elastic.co/elasticsearch/elasticsearch:7.15.1

RUN /usr/share/elasticsearch/bin/elasticsearch-plugin install --batch https://github.com/skyer9/elasticsearch-jaso-analyzer/releases/download/v7.15.1/jaso-analyzer-plugin-7.15.1-plugin.zip
RUN /usr/share/elasticsearch/bin/elasticsearch-plugin install --batch analysis-icu
RUN /usr/share/elasticsearch/bin/elasticsearch-plugin install --batch analysis-nori
----------------------------

docker build -t skyer9/elasticsearch-jaso-analyzer:7.15.1.1 .
docker login
docker push skyer9/elasticsearch-jaso-analyzer:7.15.1.1

답글 남기기