Skip to content

Annotations from container source not applied to kubernetes deployment #8547

@MatthiasDrews

Description

@MatthiasDrews

Describe the bug
We have a container source with dedicated annotations on the template:

apiVersion: sources.knative.dev/v1
kind: ContainerSource
...
spec:
  template:
    metadata:
      annotations:
        timestamp: 2025-03-27T13:54:57+0000
...

Expected behavior
I expect the annotation to be present also in the generated kubernetes Deployment, as described in the documentation: A template in the shape of Deployment.spec.template to be used for this ContainerSource.. However it is missing:

kind: Deployment
apiVersion: apps/v1
spec:
  template:
      metadata:
        creationTimestamp: null
        labels:
          sources.knative.dev/containerSource: ...
          sources.knative.dev/source: container-source-controller

To Reproduce
Steps to reproduce the behavior.

Knative release version
1.17.3

Additional context

Metadata

Metadata

Assignees

No one assigned

    Labels

    kind/bugCategorizes issue or PR as related to a bug.

    Type

    No type

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions