Skip to content
This repository has been archived by the owner on Jan 21, 2023. It is now read-only.

Cannot install core ES plugin because of bad Java JDK path #54

Open
Scoottykun opened this issue Jan 6, 2023 · 0 comments
Open

Cannot install core ES plugin because of bad Java JDK path #54

Scoottykun opened this issue Jan 6, 2023 · 0 comments

Comments

@Scoottykun
Copy link

Hello,

I'm trying to add the "analysis-icu" plugin to the "blacktop/elasticsearch:8.1.2" image, below my dockerfile

FROM blacktop/elasticsearch:8.1.2
RUN elasticsearch-plugin install analysis-icu

But on image build i'm having this error :

#5 [2/2] RUN bin/elasticsearch-plugin install analysis-icu
#5 sha256:8e7998a4caf95a423a2aca933e63c0eeb6e0dd54a2e1e9f1e334b7a4416bf8c2
#5 0.318 could not find java in bundled JDK at /usr/share/elasticsearch/jdk/bin/java
#5 ERROR: executor failed running [/bin/sh -c bin/elasticsearch-plugin install analysis-icu]: exit code: 1

After checking within the base image container it seems the right possible paths are :

  • /usr/lib/jvm/java-17-openjdk/bin/java
  • /usr/lib/jvm/default-jvm/bin/java

I tried to force the JAVA_HOME as below, but it doesn't seems to fix my error 👍

FROM blacktop/elasticsearch:8.1.2
ENV JAVA_HOME=/usr/lib/jvm/java-17-openjdk/bin/java
RUN elasticsearch-plugin install analysis-icu

What would be the right way to add an ES plugin to this docker image ?

Thanks in advance for your help !

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant