geonetwork / docker-geonetwork

Official Docker image repository for GeoNetwork
38 stars 39 forks source link

Connect image to elastic #31

Closed pvgenuchten closed 9 months ago

pvgenuchten commented 5 years ago

From next major update Elastic will be essential component of GN, currently is optional, although offers nice extra capabilities. Would be interesting to add environment variables that connect geonetwork to an external (or orchestrated) elastic instance.

juanluisrp commented 9 months ago

You can use these variables to set up the Elasticsearch connection:

      ES_HOST: elasticsearch
      ES_PROTOCOL: http
      ES_PORT: 9200
      ES_USERNAME: es_user
      ES_PASSWORD: es_password

      KB_URL: http://kibana:5601
digorgonzola commented 8 months ago

I just want to note here that since 4.4 the above environment variables are no longer valid according to the docs and you must use the sub-properties of GN_CONFIG_PROPERTIES e.g.

      GN_CONFIG_PROPERTIES: >-
        -Des.host=elasticsearch
        -Des.protocol=http
        -Des.port=9200
        -Des.url=http://elasticsearch:9200
        -Des.username=my_es_username
        -Des.password=my_es_password
        -Dkb.url=http://kibana:5601

This is a bit annoying for deployments to ECS where we don't want to store the ES_PASSWORD value in code but retrieve it instead from a secrets manager.

Any reason why the old individual environment variables have been deprecated?