# Enroll filebeat in Kubernetes, monitor in Kibana when output is kafka possible?

**URL:** https://discuss.elastic.co/t/enroll-filebeat-in-kubernetes-monitor-in-kibana-when-output-is-kafka-possible/185892
**Category:** Beats
**Tags:** fleet
**Created:** [June 14, 2019, 4:40pm UTC](https://discuss.elastic.co/t/enroll-filebeat-in-kubernetes-monitor-in-kibana-when-output-is-kafka-possible/185892 "2019-06-14T16:40:26Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![alonchis](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/alonchis/32/52655_2.png) [@alonchis](https://discuss.elastic.co/u/alonchis)
#### Post date: [June 14, 2019, 4:40pm UTC](https://discuss.elastic.co/t/enroll-filebeat-in-kubernetes-monitor-in-kibana-when-output-is-kafka-possible/185892/1 "2019-06-14T16:40:26Z")

</div>

I want to enroll filebeat running in a kubernetes cluster outputting to kafka.  
In kibana it says to run that sudo filebeat enroll [API\_KEY] command but since this is running kubernetes, it gets kinda tricky.

Is there a way to specify how to enroll the beat to centralized management via the yaml config?

---

<div class="post-metadata">

### Author: ![Michael\_Madden](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/michael_madden/32/46640_2.png) [@Michael\_Madden](https://discuss.elastic.co/u/Michael_Madden)
#### Post date: [June 25, 2019, 8:57pm UTC](https://discuss.elastic.co/t/enroll-filebeat-in-kubernetes-monitor-in-kibana-when-output-is-kafka-possible/185892/2 "2019-06-25T20:57:53Z")

</div>

Hi, thanks for reaching out about kubernetes and enrolling a beat. It's difficult today to enroll components in a kubernetes cluster since they're ephemeral.

Have you considered deploying beats as a DaemonSet? In the past, I've worked at places with large kubernetes clusters, and this approach worked well.

[https://www.elastic.co/guide/en/beats/filebeat/master/running-on-kubernetes.html](https://www.elastic.co/guide/en/beats/filebeat/master/running-on-kubernetes.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: [November 4, 2022, 7:12am UTC](https://discuss.elastic.co/t/enroll-filebeat-in-kubernetes-monitor-in-kibana-when-output-is-kafka-possible/185892/3 "2022-11-04T07:12:24Z")

</div>


