# I need help using elastic agent to collect and transform logs

**URL:** <https://discuss.elastic.co/t/i-need-help-using-elastic-agent-to-collect-and-transform-logs/312981>\
**Category:** Elastic Agent\
**Tags:** filebeat\
**Created:** [August 26, 2022, 3:04am UTC](https://discuss.elastic.co/t/i-need-help-using-elastic-agent-to-collect-and-transform-logs/312981 "2022-08-26T03:04:15Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![shshsh](https://avatars.discourse-cdn.com/v4/letter/s/3be4f8/32.png) [@shshsh](https://discuss.elastic.co/u/shshsh)\
**Post date:** [August 26, 2022, 3:04am UTC](https://discuss.elastic.co/t/i-need-help-using-elastic-agent-to-collect-and-transform-logs/312981/1 "2022-08-26T03:04:15Z")

</div>

Hi,  
Im new to elasticsearch and its agents, and I'm having trouble understanding how to use the agents properly, especially ever since its trying to replace the beats family.  
I'm trying to use elastic agents managed by a fleet server deployed as daemonsets in k8s to collect APM, which I think I fully understand how to do, but am stuck with collecting stdout logs from api deployed in a pod.  
If I were to use Kubernetes container logs integration, and need to transform the log in some way, is it perfectly fine to configure and use a pipeline, or is it recommended to use logstash as well? Also, does the agent execute the pipeline, or is it elasticsearch nodes' job to do so?  
If I have to use logstash, I am really confused to how to configure elastic agent to collect logs and send them to logstash via kibana if I'm using the custom logs integration.

TL;dr logstash + elastic agent or agent + k8s container logs + pipeline

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:** [September 23, 2022, 3:04am UTC](https://discuss.elastic.co/t/i-need-help-using-elastic-agent-to-collect-and-transform-logs/312981/2 "2022-09-23T03:04:25Z")

</div>

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