Teten Nugraha



Connecting Elasticsearch with ElasticHQ and Cerebro — Docker Based

Connecting Elasticsearch with ElasticHQ and Cerebro — Docker Based

Teten Nugraha's photo
Teten Nugraha
·Jun 2, 2021·

2 min read

In this article I will show you how to connecting elasticsearch with elasticHQ and Cerebro.

Make sure that you installed docker on your local, in this article Im using these image:

  • lmenezes/cerebro:latest

  • elastichq/elasticsearch-hq:latest

  • elasticsearch:7.12.1

Running elasticsearch container using this command

docker run -d --name elasticsearch -p 9200:9200 -p 9300:9300 -e "discovery.type=single-node" elasticsearch:7.12.1

and then access localhost:9200 in your browser and make sure you get the response like this

and the important thing is get the ip address from the elasticsearch container with this command

docker inspect elasticsearch

and look into “NetworkSettings” part you’ll get the ip address

Run elasticHQ using this command

docker run -d --name elastichq -p 5000:5000 elastichq/elasticsearch-hq

elasticHQ running in port 5000 so you can access localhost:5000 on your browser. Default screen will be like this

and now, change the localhost:9200 using the ip address from elasticsearch container

and you will can access dashboard of elasticHQ

using that step also you can acces Cerebro, firstly run your cerebro image

docker run -d --name cerebro -p 9000:9000 lmenezes/cerebro

access localhost:9000 on your browser and connect with elasticsearch using ip address

If it was interesting or helpful to you, please do press the 👏 clap button and help others find this story too or if you wanna talk internally with me , reach me in [linktr.ee/teten_nugraha](https://linktr.ee/...

Did you find this article valuable?

Support Teten Nugraha by becoming a sponsor. Any amount is appreciated!

Learn more about Hashnode Sponsors
Share this