# Filebeat.autodiscover seems to cause terraform/kubernetes based deploy issues

**URL:** <https://discuss.elastic.co/t/filebeat-autodiscover-seems-to-cause-terraform-kubernetes-based-deploy-issues/214667>\
**Category:** Beats\
**Tags:** docker, filebeat\
**Created:** [January 10, 2020, 9:02pm UTC](https://discuss.elastic.co/t/filebeat-autodiscover-seems-to-cause-terraform-kubernetes-based-deploy-issues/214667 "2020-01-10T21:02:12Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![cgutshall](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/cgutshall/32/59809_2.png) [@cgutshall](https://discuss.elastic.co/u/cgutshall)\
**Post date:** [January 10, 2020, 9:02pm UTC](https://discuss.elastic.co/t/filebeat-autodiscover-seems-to-cause-terraform-kubernetes-based-deploy-issues/214667/1 "2020-01-10T21:02:12Z")

</div>

I wrote up a yml based deploy to handle added a filebeat pod to each node in our EKS Cluster. When deploying the following config the pods are up and running with logs getting sent to elasticsearch.

> <https://gist.github.com/cgutshall/7c233cc7f9e2ab560346545f6df3be1f>

However I went to re-implement this with Terraform, for which I have the following two files. One to deploy the configmap.

> <https://gist.github.com/cgutshall/fa44bfd98edc3e68a6669285dcad288c>

And a the contents of the config file is pointing to.

> <https://gist.github.com/cgutshall/ea322d018e481e8bf54f704189cdb23a>

Using the terraform deploy causes the pods to crash with the following error:

```
2020-01-10T18:20:49.260Z	ERROR	instance/beat.go:916	Exiting: error in autodiscover provider settings: error setting up kubernetes autodiscover provider: unable to build kube config due to error: invalid configuration: no configuration has been provided
Exiting: error in autodiscover provider settings: error setting up kubernetes autodiscover provider: unable to build kube config due to error: invalid configuration: no configuration has been provided

```

Are there any thoughts as to why this would occur? It only seems to be an issue when using the filebeat.autodiscover module.

Thanks

---

<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:** [February 7, 2020, 9:02pm UTC](https://discuss.elastic.co/t/filebeat-autodiscover-seems-to-cause-terraform-kubernetes-based-deploy-issues/214667/2 "2020-02-07T21:02:16Z")

</div>

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