Skip to content
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

[BUG] Automatic version tagging for containerized environments doesn't work #29425

Open
yoav-klein opened this issue Sep 18, 2024 · 1 comment

Comments

@yoav-klein
Copy link

Agent Environment
Agent version: 7.55.2

Describe what happened:
The docs in https://docs.datadoghq.com/getting_started/tagging/unified_service_tagging/?tab=kubernetes
state that the version tag should be taken from the image_tag. Therefore, for the following pod:

apiVersion: v1
kind: Pod
metadata:
  name: test
  labels:
    app: my-app
    tags.datadoghq.com/env: "staging"
    tags.datadoghq.com/service: "mysvc"
spec:
  containers:
  - name: nginx
    image: yoavklein3/nginx:0.1
    ports:
    - containerPort: 80

the version tag should be 0.1. But I don't see any version tag on the logs generated by this container.

Describe what you expected:
the version tag should be 0.1. But I don't see any version tag on the logs generated by this container.

Steps to reproduce the issue:

  1. Install the Datadog Agent using the Datadog Operator on a Kubernetes cluster.
  2. Deploy the following pod:
apiVersion: v1
kind: Pod
metadata:
  name: test
  labels:
    app: my-app
    tags.datadoghq.com/env: "staging"
    tags.datadoghq.com/service: "mysvc"
spec:
  containers:
  - name: nginx
    image: yoavklein3/nginx:0.1
    ports:
    - containerPort: 80

Additional environment details (Operating System, Cloud provider, etc):

@clamoriniere
Copy link
Contributor

clamoriniere commented Sep 20, 2024

Hi @yoav-klein

Thank you for reporting this issue, and we apologize for the inconvenience. While the documentation was recently updated (DataDog/documentation#23262), it is not yet fully accurate in describing how "Unified Service Tagging" works across all Datadog products.

Currently, only the APM product supports automatic "version" tagging from image_tag. As such, it is expected that this functionality isn't yet available for logs and metrics emitted by your application.

We are planning to update the documentation soon to provide a more accurate description of the current Unified Service Tagging capabilities. In parallel, we're starting an internal discussion about extending this behavior to other products. In the meantime, I recommend reapplying the tags.datadoghq.com/version label to retrieve the version tags.

Thanks again for your understanding, and we'll keep you posted on any updates.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants