dockerfile / elasticsearch

ElasticSearch Dockerfile for trusted automated Docker builds.
http://dockerfile.github.io/#/elasticsearch
MIT License
483 stars 314 forks source link

data and config mounts not working - container immediately terminates #58

Open abell25 opened 8 years ago

abell25 commented 8 years ago

Hi, I am on mac. The container immediately exits when I try to map to the data or config volumes as the instructions above suggest. I can map an arbitrary volume anywhere but these two locations. I tried copying the exact config files into my local config directory but it still fails. I also tried adding the -Des.config pointing to the location of the config file on the container but that fails too.

Fails

docker run --name es -d -p 9200:9200 -p 9300:9300 -v "$PWD"/config:/usr/share/elasticsearch/config elasticsearch

Fails

docker run --name es -d -p 9200:9200 -p 9300:9300 -v "$PWD"/data:/usr/share/elasticsearch/data elasticsearch

Runs but doesn't use correct config dir

docker run --name es -d -p 9200:9200 -p 9300:9300 -v "$PWD"/config:/config elasticsearch

I am not sure what the issue is.