Datadog Agent Docker image not collecting GCE labels as tags
Describe what happened: No label associated to my GCE instance are being exported to datadog.
Describe what you expected: While using datadog agent latest docker image, RepoDigests: datadog/agent@sha256:97359fbf552d3bfb55d051fda070f9d943b6ef41c8ca45b6d90b889b878cce79 What I expected was for the labels associated with my GCE instance, for example, "costcenter:production" to be exported by the datadog agent, as it says it does in this official link https://www.datadoghq.com/blog/monitor-google-compute-engine-with-datadog/ in the 'Drilling down with tags' section of the article.
Steps to reproduce the issue: Setup GCE instance, add custom label (example costcenter:production), run datadog-agent as docker image. The instance will show up in the infrastructure page but will not be taged with the costcenter:production
Additional environment details (Operating System, Cloud provider, etc): I was using a very simple n1-standard-2 instance with Debian9 as the OS, docker-ce installed using the official docker page steps and the latest docker image for the agent.
Hi @Leluke
What's the version of the agent tied to this sha256? Some notes: We are getting the hostname and tags from GKE by hitting these metadata API endpoints:
- http://169.254.169.254/computeMetadata/v1/instance/name
- http://169.254.169.254/computeMetadata/v1/instance/hostname
- http://169.254.169.254/computeMetadata/v1/?recursive=true
workload identity can block access to these endpoints so make sure it is not activated on your cluster or you give the rights to the agent's pod to access these endpoints.
This issue has been automatically marked as stale because it has not had activity in the past 15 days.
It will be closed in 30 days if no further activity occurs. If this issue is still relevant, adding a comment will keep it open. Also, you can always reopen the issue if you missed the window.
Thank you for your contributions!
Automatically closed due to inactivity.