-
Notifications
You must be signed in to change notification settings - Fork 4.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[META Issue]Enhancement for being able to toggle the kubeadm-config api calls #40276
Comments
Pinging @elastic/obs-ds-hosted-services (Team:obs-ds-hosted-services) |
@cmacknz I was testing the above enhancement through the integration, but I could not observe any improvements in case of applying the use_kubeadm variable through the integration. I think the reason is that the kubernetes provider is already started and we call the GetPodMetadataGen here So to my questions: DEV=true EXTERNAL=true SNAPSHOT=true PLATFORMS=linux/amd64 PACKAGES=tar.gz mage -v package
failed to run compiled magefile: signal: killed I have at least 7GB of memory, any ideas how else I can unblock myself here?
|
Not yet.
It was paused because we are working on getting rid of the beats sub-processes which would eliminate this problem. I would suggest if you need control over this for k8s to expose it as a env var as was done for add_cloud_metadata. There is unfortunately no other easy change to make here, the global processor configuration is unnecessarily hard to do in the current agent architecture. |
@gizas Could we add a way to toggle this via an ENV var? Btw. |
It took me a bit of time to figure out where the kubeadm behaviour is configured in elastic-agent, so I'm going to leave the results here for posterity. To start with, this is the default of our internal autodiscovery library, defined here. Elastic-agent implements this default here. If we wanted to disable this behaviour in agent, the config fragment would look like the following: providers:
kubernetes:
add_resource_metadata:
namespace:
use_kubeadm: false
node:
use_kubeadm: false |
Oh I see that we refer https://github.com/elastic/elastic-agent-autodiscover/blob/main/kubernetes/metadata/config.go#L63-L64 and this uses use_kubeadm: true!!!! So question would be how to initialise the kubeadm in agent provider: I see only this option https://www.elastic.co/guide/en/fleet/current/advanced-kubernetes-managed-by-fleet.html#_step_2_create_a_new_configmap correct? |
I think you can also set this via overrides in the fleet policy after elastic/elastic-agent#6169. @blakerouse please let me know if I'm off the mark here. |
This is the META issue that will summarise all the needed sub issues that are needed in order to be able to disable the /api/v1/namespaces/kube-system/configmaps/kubeadm-config API calls through configuration.
The relevant enhancement was raised here: https://github.com/elastic/enhancements/issues/21172
See this issue for more details
The enhancement finally needs to be available in the elastic agent when users install the Kubernetes Integration. Additional we note that the kubeadm config calls are being made both as part of log collection process start and as metrics collection starts.
So in more details the task list is:
Tasks
NOTES:
The text was updated successfully, but these errors were encountered: