DEV Community

Discussion on: How To Build Autocomplete search with Nestjs, Elasticsearch and Vue

Collapse
 
harrisking profile image
HARRISKING

how to get the docker IP?

Collapse
 
kop7 profile image
mkop
Collapse
 
crazyoptimist profile image
crazyoptimist

Service name (nest-elasticsearch in above case) is used when you use docker-compose for ochestrating everything. Otherwise, bind the port to the host and use localhost. For example:

ports:
  - 9200:9200
  - 9300:9300
Enter fullscreen mode Exit fullscreen mode

Then you can access the elasticsearch node using http://localhost:9200