# Cant run elasticsearch on mastodon

**URL:** <https://discuss.elastic.co/t/cant-run-elasticsearch-on-mastodon/373717>\
**Category:** Elasticsearch\
**Created:** [January 27, 2025, 1:11pm UTC](https://discuss.elastic.co/t/cant-run-elasticsearch-on-mastodon/373717 "2025-01-27T13:11:17Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![rasitha](https://avatars.discourse-cdn.com/v4/letter/r/47e85d/32.png) [@rasitha](https://discuss.elastic.co/u/rasitha)\
**Post date:** [January 27, 2025, 1:11pm UTC](https://discuss.elastic.co/t/cant-run-elasticsearch-on-mastodon/373717/1 "2025-01-27T13:11:17Z")

</div>

hi im having trouble connecting elasticsearch to mastodon

i can connect with curl without problem

when i run RAILS\_ENV=production bin/tootctl search deploy i get this error

```auto
INFO -- : [dotenv] Loaded .env.production
There was an issue connecting to the search server. Make sure the--=---=---=---=---=---=---=-| ETA: ??:??:?? (0 docs/s)
server is configured and running correctly, and that the environment
variable settings match what the server is expecting.

[500] {"error":{"root_cause":[{"type":"class_cast_exception","reason":"class java.lang.Boolean cannot be cast to class j
ava.util.Map (java.lang.Boolean and java.util.Map are in module java.base of loader 'bootstrap')"}],"type":"class_cast_e
xception","reason":"class java.lang.Boolean cannot be cast to class java.util.Map (java.lang.Boolean and java.util.Map a
re in module java.base of loader 'bootstrap')"},"status":500}

```

howto resolve this

---

<div class="post-metadata">

**Author:** ![carly.richmond](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/carly.richmond/32/104935_2.png) [@carly.richmond](https://discuss.elastic.co/u/carly.richmond)\
**Post date:** [January 27, 2025, 5:08pm UTC](https://discuss.elastic.co/t/cant-run-elasticsearch-on-mastodon/373717/2 "2025-01-27T17:08:21Z")

</div>

Hi @rasitha,

Welcome! Can you confirm which version of Elasticsearch you are connecting to, and which repo/ project you are trying to run?
