Using a custom docker image for Elastic Cloud on Kubernetes

Hi,

I'm looking into or doing some research on Elastic Cloud on Kubernetes and went through the Quickstart page but I couldn't find a way to use ECK with a custom ES docker image hosted on docker hub. Is there a way to do so?

Curious to know why you want to run a custom ES docker image. As we post all the updates keep the containers patched with latest security fixes.

Both the Elasticsearch and the Kibana CRDs have an image attribute that allow you specify a custom docker image.

I want to build a custom image based on the official ES docker image to add few things for my needs.

Thanks. I went through the CRD definition and saw this attribute, however, I'm not certain how to use it if I have a private docker repo. I tried with the following:

cat <<EOF | kubectl apply -f -
apiVersion: elasticsearch.k8s.elastic.co/v1alpha1
kind: Elasticsearch
metadata:
name: quickstart
spec:
image: rutomo/custom-es:6.8.0
nodes:

  • nodeCount: 1
    config:
    node.master: true
    node.data: true
    node.ingest: true
    EOF

I got an error saying that it couldn't parse Elasticsearch version so I assume version is required so I tried to the following:

cat <<EOF | kubectl apply -f -
apiVersion: elasticsearch.k8s.elastic.co/v1alpha1
kind: Elasticsearch
metadata:
name: quickstart
spec:
image: rutomo/custom-es
version: 6.8.0
nodes:

  • nodeCount: 1
    config:
    node.master: true
    node.data: true
    node.ingest: true
    EOF

I got Init:ImagePullBackOff which I assumed it's because it's a private repo so I have to pass docker hub secret, however, I'm not sure how to do this as it's not mentioned anywhere in the quickstart or documentation. Also, I'm not sure if I did it correctly because I have a specific tag for my custom ES image. I will go through into the CRD again and see if I can find anything for the secret.

EDIT: ignore the formatting since I'm not sure how to format it properly.

In principle what is written in the Kubernetes documenation applies also to ECK
https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/

For ECK 0.8.0 we don't support a full podTemplate yet which means you cannot unfortunately specify the necessary imagePullSecrets. We will fix that in the next release.

Thanks for confirming, Peter.