zalando-incubator / es-operator

Kubernetes Operator for Elasticsearch
353 stars 47 forks source link

Unable to enable basic authentication #102

Open Dearraj25 opened 4 years ago

Dearraj25 commented 4 years ago

Unable to enable basic authentication for elastic search with username and password.

Is there is any other way to enable authentication for elastic search with username and password?

I am trying to enable xpack.security I am facing errors.

I have just added xpack.security.enabled: true in es-config.

apiVersion: v1

kind: ConfigMap

metadata:

  name: es-config

  namespace: es-operator-demo

data:

  elasticsearch.yml: |

    cluster.name: es-cluster

    network.host: "0.0.0.0"

    bootstrap.memory_lock: false

    discovery.seed_hosts: [es-master]

    cluster.initial_master_nodes: [es-master-0]

    xpack.security.enabled: true

I have tried different versions of elastic search dockers and also by changing the version of ES_JAVA_OPTS.

Used all the configuration given in https://github.com/zalando-incubator/es-operator/tree/master/docs.

mikkeloscar commented 4 years ago

What errors are you facing? The operator should not have any influence on this configuration afaik.

Dearraj25 commented 4 years ago

@mikkeloscar Please check the screenshot below for the errors image

otrosien commented 4 years ago

First disclaimer: we haven't tested the es-operator with xpack security, so we're probably not adding the necessary credentials to the API calls. Despite that the problem you're facing is unrelated to that, you're probably trying to run Elasticsearch OSS which doesn't contain xpack features. Switch to Elasticsearch Basic license.