I am trying to create a local kibana/elastic stack while developing a spring-boot application. I can successfully connect my application to elastic when I launch it as a single container:
docker run -p 9200:9200 -p 9300:9300 -e "discovery.type=single-node" docker.elastic.co/elasticsearch/elasticsearch:6.2.3
My application can connect on 9300, and my web browser can see that it's up on localhost:9200
So... I tried launching the provided stack-docker docker-compose file found here: https://github.com/elastic/stack-docker
Everything seems to setup fine, and I can connect to kibana on localhost:5601, but neither my browser or my application can connect to elastic on 9200 and 9300 respectively.
The only modification from what's checked into github and what I ran is that I added 9300 to the elastic definition.
Any idea what changes I can make to make elastic accessible to my app/browser when running in docker-compose?