# Elasticsearch in docker container keeps enabling xpack even if explicitely disabled

**URL:** <https://discuss.elastic.co/t/elasticsearch-in-docker-container-keeps-enabling-xpack-even-if-explicitely-disabled/108465>\
**Category:** Elasticsearch\
**Created:** [November 20, 2017, 9:26pm UTC](https://discuss.elastic.co/t/elasticsearch-in-docker-container-keeps-enabling-xpack-even-if-explicitely-disabled/108465 "2017-11-20T21:26:08Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![perrohunter](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/perrohunter/32/16819_2.png) [@perrohunter](https://discuss.elastic.co/u/perrohunter)\
**Post date:** [November 20, 2017, 9:26pm UTC](https://discuss.elastic.co/t/elasticsearch-in-docker-container-keeps-enabling-xpack-even-if-explicitely-disabled/108465/1 "2017-11-20T21:26:09Z")

</div>

I'm running elasticsearch for local development in a docker container and disabling `xpack` explicitely, yet, every x days the container locks itself because the xpack license exprires, elastic stops working

I'm disabling xpack through environment variables in my `docker-compose.yml` as such

```auto
elasticsearch:
  image: docker.elastic.co/elasticsearch/elasticsearch:5.5.2
  # image: elasticsearch:5.2.2
  environment:
    - http.host=0.0.0.0
    - transport.host=127.0.0.1
    - XPACK_SECURITY_ENABLED=false
    - xpack.security.enabled=false
  volumes:
    - "$DATADIR/data:/usr/share/elasticsearch/data"
  ports:
    - "9200:9200"
    - "9300:9300"

```

still, xpack license kills my container

![51 PM](https://us1.discourse-cdn.com/elastic/original/3X/c/5/c5cd9454145c6a1fb4fdc0e8a00ca939f3f768f5.png)

this is super annoying, how can I get rid of xpack all together?

---

<div class="post-metadata">

**Author:** ![TimV](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/timv/32/13162_2.png) [@TimV](https://discuss.elastic.co/u/TimV)\
**Post date:** [November 24, 2017, 9:26am UTC](https://discuss.elastic.co/t/elasticsearch-in-docker-container-keeps-enabling-xpack-even-if-explicitely-disabled/108465/2 "2017-11-24T09:26:40Z")

</div>

I have moved your question to the x-pack forum.

---

<div class="post-metadata">

**Author:** ![TimV](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/timv/32/13162_2.png) [@TimV](https://discuss.elastic.co/u/TimV)\
**Post date:** [November 24, 2017, 9:34am UTC](https://discuss.elastic.co/t/elasticsearch-in-docker-container-keeps-enabling-xpack-even-if-explicitely-disabled/108465/3 "2017-11-24T09:34:11Z")

</div>

Turning off security is not the same as disabling X-Pack. If you have the x-pack plugin installed, then you need to have some form of licence.  
The 5.5 docker image ships with X-Pack.

The easiest option is to go to [https://register.elastic.co/](https://register.elastic.co/) and obtain a 12 month licence for X-Pack basic (which is free).

Alternatively you can uninstall X-Pack with the`elasticsearch-plugin` command, although modifying the container might not be something that you want to do.

---

<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 22, 2017, 9:34am UTC](https://discuss.elastic.co/t/elasticsearch-in-docker-container-keeps-enabling-xpack-even-if-explicitely-disabled/108465/4 "2017-12-22T09:34:17Z")

</div>

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