How does the use of efk in docker make data persistent -v mounted

  docker, question

I run efk in docker and then I don’t know how to mount it with -v for data persistence. I read the official introduction,

$ docker run -d -v "$PWD/esdata":/usr/share/elasticsearch/data elasticsearch

This is how they did it, but I have tried to find out that there is no Node folder that has been initialized and I don’t know how to solve the problem. Ask for advice

And I imagine the great gods will learn from the experience. if the production environment is used, in addition to data persistence, then I need to pay attention to what to write, or I need to optimize those parameters for startup configuration. thank you, big brother ~

YesELK? There is nothing wrong with the official documents. This is how I mount them. I have also added a log mount here.

- /elasticsearch/data:/usr/share/elasticsearch/data
 - /elasticsearch/logs:/usr/share/elasticsearch/logs

Also refer todocker-elk