Kibana REST API for integrations setup

Hello,

I have installed Elastic stack using ECK (Elasticsearch, Kibana, Beats, APM Server + agents), and trying to automate setup moving manual configuration steps to Kubernetes jobs that use Elasticsearch REST API.

But can't find any API to install and configure Elastic APM integration on Kibana. Is there a way to automate this setup process?

Thank you!

Hello @OlLap , which version of ECK are you working with?

Also, just to double check, you are not using Fleet correct?

ECK 2.5.0
And yes, no Fleet

Ok, so at first glance it doesn't look like it's intrinsically possible to do what you are asking...
"APM Server exposes an API endpoint that allows agents to query the server for configuration changes", from: Agent configuration API | APM User Guide [8.5] | Elastic

I'll ask my colleagues as well.

Which agent are you using?

Hello again @OlLap and happy new year!
I've reached out to colleagues on the APM team concerning your question.

The moment I hear something back I will let you know.

Ok, I've just heard back.

On k8s, you can automatically install the bundled APM integration in your K8s definition:
K8s Definition

Does this help?

Hello,

thank you for providing this information. I tried with this config lines, but agent policy wasn't created automatically, only Elastic APM integration was created using lines 40-42 from your link.

Maybe it's because I don't have Fleet installed.. But don't see a reason why I need it in my ELK setup

ah ok, I'm glad something helped! Let me ask my teammate about the agent policy auto-creation.

So, I just asked and he's in a different time zone.
I'll let you know as soon as I get a response!

Hello again @OlLap :sunny:
I'm sorry but the APM server has a hard dependency on Fleet now.
I am out of ideas if we are not going to use Fleet :frowning:

Hello,

but can you explain in simple terms why I actually need this Fleet if everything works without it?

I'll ask right now!

While we wait, my colleague also mentioned this link:

At least with this directory, we can see that the apm server depends on fleet. Soon we will find out why. :crossed_fingers:

@OlLap APM currently requires Fleet for powering several APM-specific features:

  • APM Agent central configuration is pushed to APM Server via Fleet
  • Source maps are stored as Fleet artifacts, with references to them pushed down to APM Server via Fleet; APM Server then fetches the source maps via Fleet Server.
  • Tail-based sampling policies are defined in the integration policy, and pushed down to APM Server via Fleet.

Because of this requirement on Fleet, we currently do not support Elastic Agent standalone mode. This is mentioned as a note in our docs:

The APM integration does not support running Elastic Agent in standalone mode; you must use Fleet to manage Elastic Agent.

We're working towards not requiring fleet-server in future versions of APM Server. Keep an eye on the changelog since we're expecting this change to happen in the near future.

thanks @marclop !

I am out of ideas if we are not going to use Fleet :frowning:.

.

@OlLap just curious about why do you not want to use Fleet?

Because it works without Fleet :grinning: just wonder why I need to add one more resource if for my needs it works without it

Thank you everyone for explanation, I'll try to include Fleet

1 Like

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