Yes, thanks for replying. I tried doing that but it assumes the ignite binary is present in the local directory somewhere. " COPY apache-ignite* apache-ignite " Could you please explain 1. where is it reading ignite binaries from and 2. ignite binaries zip doesn't have run.sh. If I copy run.sh as well along with Dockerfile from github, does it have any other dependency.
On Wed, Nov 17, 2021 at 4:51 PM Stephen Darlington < [email protected]> wrote: > I’d just take the original Dockerfile (Dockerfile > <https://github.com/apache/ignite/blob/master/deliveries/docker/apache-ignite/x86_64/Dockerfile>) > and replace the reference to Java 8 with Java 11 > > On 17 Nov 2021, at 10:50, Surinder Mehra <[email protected]> wrote: > > Hi, > I tried to build one with two approaches. I was thinking the 1st one is > simple and should work but it didn't so I tried the 2nd approach which > seems to be missing something. Can you point out the missing piece please. > > 1. Extend base image and update java home as below > FROM apacheignite/ignite > > ENV JAVA_HOME /usr/lib/jvm/java-11-openjdk-amd64 > # Install OpenJDK-11 > RUN apt-get update && \ > apt-get install -y openjdk-11-jdk && \ > export JAVA_HOME && \ > apt-get clean; > RUN export JAVA_HOME="$(dirname $(dirname $(readlink -f $(which java))))" > > This throws an error "apt-get not found". I tried with yum as well, but it > throws the same error. Not sure why it doesn't have package manager > > 2. On the 2nd approach I tried to use jdk11 as base image and install > ignite on it and run /bin/ignite.sh. It throws an error saying it cant find > executable on path. > > FROM adoptopenjdk/openjdk11 > > # Set Apache Ignite configuration file name. > ARG IGNITE_CFG_XML="node-configuration.xml" > > # Set Apache Ignite version. > ARG IGNITE_VERSION="2.11.0" > > # Set IGNITE_HOME variable. > ENV IGNITE_HOME /opt/ignite/apache-ignite-${IGNITE_VERSION}-bin > > # Set a path to the Apache Ignite configuration file. Use the run.sh script > below: > ENV CONFIG_URI ${IGNITE_HOME}/config/$IGNITE_CFG_XML > > # Make sure the Kubernetes lib is copied to the 'libs' folder. > #ENV OPTION_LIBS ignite-kubernetes > > # Disabling quiet mode. > ENV IGNITE_QUIET=false > WORKDIR /opt/ignite > # Install or update needed tools. > #RUN apt-get update && apt-get install -y --no-install-recommends unzip > RUN apt-get update && \ > apt-get install -y wget && \ > apt-get install unzip && \ > wget > https://dlcdn.apache.org//ignite/${IGNITE_VERSION}/apache-ignite-${IGNITE_VERSION}-bin.zip > # Creating and setting a working directory for following commands. > > # Copying local Apache Ignite build to the docker image. > #COPY ./apache-ignite-${IGNITE_VERSION}-bin.zip > apache-ignite-${IGNITE_VERSION}-bin.zip > > # Unpacking the build. > RUN unzip apache-ignite-${IGNITE_VERSION}-bin.zip > RUN rm apache-ignite-${IGNITE_VERSION}-bin.zip > > # Copying the executable file and setting permissions. > > RUN chmod +x $IGNITE_HOME/bin/ignite.sh > > # Copy the configuration. > #COPY ./$IGNITE_CFG_XML $IGNITE_HOME/config > > #RUN $IGNITE_HOME/bin/ignite.sh > # Start an Apache Ignite node. > CMD $IGNITE_HOME/bin/ignite.sh > #$IGNITE_HOME/config/$IGNITE_CFG_XML > > # Exposing the ports. > #EXPOSE 11211 47100 47500 49112 > EXPOSE 10800 11211 47100 11211 47100 47500 49112 > > > > On Tue, Nov 16, 2021 at 3:51 PM Stephen Darlington < > [email protected]> wrote: > >> I don’t see an image with Java 11. I think you’d have to build your own. >> >> There are tickets for this: >> https://issues.apache.org/jira/browse/IGNITE-14031 and >> https://issues.apache.org/jira/browse/IGNITE-15209 >> >> On 16 Nov 2021, at 09:55, Surinder Mehra <[email protected]> wrote: >> >> Hi, >> I followed below link to deploy ignite pod on kubernetes. It uses apache >> ignite 2.11 docker image which has java openjdk 8. Is there a way to >> configure java 11 on this pod or ignite image with jdk11 ? >> >> >> https://ignite.apache.org/docs/latest/installation/kubernetes/amazon-eks-deployment >> >> >> >> > >
