# Documentation for docker environment variables

**URL:** <https://discuss.elastic.co/t/documentation-for-docker-environment-variables/112907>\
**Category:** APM\
**Created:** [December 21, 2017, 10:55pm UTC](https://discuss.elastic.co/t/documentation-for-docker-environment-variables/112907 "2017-12-21T22:55:23Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ryan\_Grannell1](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ryan_grannell1/32/25903_2.png) [@Ryan\_Grannell1](https://discuss.elastic.co/u/Ryan_Grannell1)\
**Post date:** [December 21, 2017, 10:55pm UTC](https://discuss.elastic.co/t/documentation-for-docker-environment-variables/112907/1 "2017-12-21T22:55:23Z")

</div>

Hi,

Is there any documentation available for environment parameters than can be used when setting up APM through docker-compose? For example, when configuring ElasticSearch you can use the following yaml in place of a dedicated configuration file:

```
image: docker.elastic.co/elasticsearch/elasticsearch:6.1.1
environment:
  - "ES_JAVA_OPTS=-Xms512m -Xmx512m"
  - discovery.zen.minimum_master_nodes=1 

```

Is there a similar method for configuring APM?

---

<div class="post-metadata">

**Author:** ![roncohen](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/roncohen/32/22881_2.png) [@roncohen](https://discuss.elastic.co/u/roncohen)\
**Post date:** [December 23, 2017, 9:08pm UTC](https://discuss.elastic.co/t/documentation-for-docker-environment-variables/112907/2 "2017-12-23T21:08:40Z")

</div>

Hi Ryan,

Thank you for your interest in Elastic APM!

APM Server doesn't read environment variables directly, but you can use environment variables to configure APM Server by specifying them on the command line. I agree we need to document how to do that. I've created [this issue](https://github.com/elastic/apm-server/issues/440) to that effect

The issue includes an example of how to set configuration options through environment variables when using docker-compose.

Hope that helps!

---

<div class="post-metadata">

**Author:** ![Ryan\_Grannell1](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ryan_grannell1/32/25903_2.png) [@Ryan\_Grannell1](https://discuss.elastic.co/u/Ryan_Grannell1)\
**Post date:** [December 24, 2017, 1:54pm UTC](https://discuss.elastic.co/t/documentation-for-docker-environment-variables/112907/3 "2017-12-24T13:54:10Z")

</div>

Hi Ron, that helps a lot. Thanks, and happy holidays

---

<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:** [January 14, 2018, 9:54am UTC](https://discuss.elastic.co/t/documentation-for-docker-environment-variables/112907/4 "2018-01-14T09:54:13Z")

</div>

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