# Some questions from a newbie on Docker Elasticsearch image

**URL:** <https://discuss.elastic.co/t/some-questions-from-a-newbie-on-docker-elasticsearch-image/90452>\
**Category:** Elasticsearch\
**Created:** [June 22, 2017, 12:46pm UTC](https://discuss.elastic.co/t/some-questions-from-a-newbie-on-docker-elasticsearch-image/90452 "2017-06-22T12:46:48Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![ea1987](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ea1987/32/51356_2.png) [@ea1987](https://discuss.elastic.co/u/ea1987)\
**Post date:** [June 22, 2017, 12:46pm UTC](https://discuss.elastic.co/t/some-questions-from-a-newbie-on-docker-elasticsearch-image/90452/1 "2017-06-22T12:46:48Z")

</div>

Hi all,  
I'm new on both Elasticsearch and Docker and I have some questions about them. I retrieved docker/elastic image via the following command:

docker pull [docker.elastic.co/elasticsearch/elasticsearch:5.4.2](http://docker.elastic.co/elasticsearch/elasticsearch:5.4.2)

And I started it in this way:

docker run -p 9200:9200 -e "http.host=0.0.0.0" -e "transport.host=127.0.0.1" [docker.elastic.co/elasticsearch/elasticsearch:5.4.2](http://docker.elastic.co/elasticsearch/elasticsearch:5.4.2)

Here are my questions:  
1 I know from docker documentation that "docker run" commands is used to run a specific command inside a container. So according to the previous one, what's the unix command?

docker run -p 9200:9200 (Publish all exposed ports to random ports) -e "http.host=0.0.0.0" -e "transport.host=127.0.0.1" (Set environment variables) [docker.elastic.co/elasticsearch/elasticsearch:5.4.2](http://docker.elastic.co/elasticsearch/elasticsearch:5.4.2) (image name)

So where is the command? I suspect it's like elasticsearch starts together with the container. If so, how image's creator did that?

2 What's the best way of running the container without elastic's stdout?

3 I tried to build a custom docker image based on CentOS in which I would like to install elasticsearch like a service (via rpm). Installation works fine but when I try to run elasticsearch.service via systemctl I get the following error:

Failed to get D-Bus connection: Operation not permitted

How can I solve this?

Thanks,

Andrea

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 20, 2017, 12:46pm UTC](https://discuss.elastic.co/t/some-questions-from-a-newbie-on-docker-elasticsearch-image/90452/2 "2017-07-20T12:46:51Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
