# \[ES 2.4\] cluster ignores docker-compose variables

**URL:** <https://discuss.elastic.co/t/es-2-4-cluster-ignores-docker-compose-variables/288530>\
**Category:** Elasticsearch\
**Tags:** docker\
**Created:** [November 5, 2021, 10:02pm UTC](https://discuss.elastic.co/t/es-2-4-cluster-ignores-docker-compose-variables/288530 "2021-11-05T22:02:52Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![rschirin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/rschirin/32/45283_2.png) [@rschirin](https://discuss.elastic.co/u/rschirin)\
**Post date:** [November 5, 2021, 10:02pm UTC](https://discuss.elastic.co/t/es-2-4-cluster-ignores-docker-compose-variables/288530/1 "2021-11-05T22:02:52Z")

</div>

Hey there,  
Is it possible to set environment variables using docker-compose on Elasticsearch 2.4.4?  
I am trying to set cluster-name with classic method

```auto
environment:
   - cluster-name=test

```

but the cluster is ignoring it.  
I tried also to set the ES\_JAVA\_HEAP and it seems to be only appended to executed command.

This method is is obviously working with ES 6.x or ES 7.x.  
I am not understanding if there is any limit on ES 2.4 usage.

---

<div class="post-metadata">

**Author:** ![stephenb](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/stephenb/32/40856_2.png) [@stephenb](https://discuss.elastic.co/u/stephenb)\
**Post date:** [November 6, 2021, 1:18am UTC](https://discuss.elastic.co/t/es-2-4-cluster-ignores-docker-compose-variables/288530/2 "2021-11-06T01:18:24Z")

</div>

> [@rschirin](#):
>
> I am not understanding if there is any limit on ES 2.4 usage.

Hi @rschirin can you help us understand what you mean by usage limits?

---

<div class="post-metadata">

**Author:** ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)\
**Post date:** [November 6, 2021, 3:42am UTC](https://discuss.elastic.co/t/es-2-4-cluster-ignores-docker-compose-variables/288530/3 "2021-11-06T03:42:24Z")

</div>

2.4 is very well past [EOL](https://www.elastic.co/support/eol) and is no longer supported. Is there a reason you are using it?

---

<div class="post-metadata">

**Author:** ![rschirin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/rschirin/32/45283_2.png) [@rschirin](https://discuss.elastic.co/u/rschirin)\
**Post date:** [November 6, 2021, 6:59am UTC](https://discuss.elastic.co/t/es-2-4-cluster-ignores-docker-compose-variables/288530/4 "2021-11-06T06:59:27Z")

</div>

Oh yes, I mean is there any limit regards the docker-compose usage for that ES version.

---

<div class="post-metadata">

**Author:** ![rschirin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/rschirin/32/45283_2.png) [@rschirin](https://discuss.elastic.co/u/rschirin)\
**Post date:** [November 6, 2021, 7:00am UTC](https://discuss.elastic.co/t/es-2-4-cluster-ignores-docker-compose-variables/288530/5 "2021-11-06T07:00:50Z")

</div>

Yes, I am trying to migrate (ES mechanism not ES data ) to a newer version so I need to do some tests

---

<div class="post-metadata">

**Author:** ![rschirin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/rschirin/32/45283_2.png) [@rschirin](https://discuss.elastic.co/u/rschirin)\
**Post date:** [November 8, 2021, 11:16pm UTC](https://discuss.elastic.co/t/es-2-4-cluster-ignores-docker-compose-variables/288530/6 "2021-11-08T23:16:19Z")

</div>

Is it possible to find all the variables that could be usable?

---

<div class="post-metadata">

**Author:** ![stephenb](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/stephenb/32/40856_2.png) [@stephenb](https://discuss.elastic.co/u/stephenb)\
**Post date:** [November 8, 2021, 11:44pm UTC](https://discuss.elastic.co/t/es-2-4-cluster-ignores-docker-compose-variables/288530/7 "2021-11-08T23:44:45Z")

</div>

Hi @rschirin

Really I think you are just going to need to plow through the docs and download the distribution, frankly we don't focus on releases that old.

A quick look at the `elasticsearch.yml` ... looks like there is only about 15 settings total...

> **[Configuration | Elasticsearch Guide \[2.4\] | Elastic](https://www.elastic.co/guide/en/elasticsearch/reference/2.4/setup-configuration.html)**

---

<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:** [December 6, 2021, 11:44pm UTC](https://discuss.elastic.co/t/es-2-4-cluster-ignores-docker-compose-variables/288530/8 "2021-12-06T23:44:56Z")

</div>

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