A few days ago at work, we moved on to using Postman, and as we use Elastic Search and Docker quite a lot it sounded fun to put them together to allow some easy sandboxing. So here we go: how to play with Elastic Search in a sandboxed environment using Postman and Docker.
Requirements
- Docker
- Postman
Before we go any further, check that the docker installation is happy,
- docker run hello-world
For a bit more detail about docker please visit my previous Quick Guide to Docker.
If you skipped firing up elastic in the previous steps, you need to pull down elastic with the following command,
- $ sudo docker pull docker.elastic.co/elasticsearch/elasticsearch:7.10.2
- $ sudo docker run -p 9200:9200 -p 9300:9300 -e "discovery.type=single-node" --name "es_demo_app" docker.elastic.co/elasticsearch/elasticsearch:7.10.2
The 'p' flag sets the port forwarding to the container, from local to container.
The 'e' flag sets elastic to a single node mode.
The --name flag is used to give it a handy name and it will ensure we start the same container with data persistency.
- #start and stop
- docker container run es_demo_app
- docker container stop es_demo_app
Elastic Search - ES
Elasticsearch was originally released as open-source by Shay Banon in 2010 under the standard Apache 2 open source license, as a search server built on the Lucene library. It can be seen as shard-based in-memory cache technology and operates by data separation and partitioning, this what gives its extremely low response.
First lets the health of the ES cluster/clusters
To check the health of our ES clusters we can do an HTTP GET request on http://localhost:9200/ and we will get the status of our elastic search cluster;








Join the conversation! Your thoughts help the community grow.