You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
podMetadata from a referenced WorkflowTemplate is not applied to the containers executed when a Sensor triggers a Workflow with a templateRef.
Most of the Sensor examples show how to create a Workflow that runs a single container. See this k8s resources example. It works great, and you can add the following to the spec (line 25 of the current example).
If the referenced template has a podMetadata applying annotations to containers, these are ignored.
podMetadata:
annotations:
my-example/xyz: true
To fix this, the annotation must be applied directly to the containers in the WorkflowTemplate being referenced. This is not true if the WorkflowTemplate is executed with argo submit.
To Reproduce
Steps to reproduce the behavior:
Create a Sensor with the a reference to a templateRef
Configure the templateRef with a container or two and configure the podMetadata to globally apply annotations to those containers
Cause the Sensor to be triggered
Watch the pods execute; they will not have the expected annotations
Expected behavior
A valid WorkflowTemplate, when referenced by a Sensor, should apply all of the podMetadata settings.
Environment (please complete the following information):
Kubernetes: v1.30
Argo Events: v2.4.7
Argo Workflows: v0.41.1
Additional context
See the issue described here #2044 for the history of adding support for WorkflowTemplate's via TemplateRef and the pull request #2120
Message from the maintainers:
If you wish to see this enhancement implemented please add a 👍 reaction to this issue! We often sort issues this way to know what to prioritize.
The text was updated successfully, but these errors were encountered:
Describe the bug
podMetadata
from a referenced WorkflowTemplate is not applied to the containers executed when a Sensor triggers a Workflow with atemplateRef
.Most of the Sensor examples show how to create a Workflow that runs a single container. See this k8s resources example. It works great, and you can add the following to the spec (line 25 of the current example).
The problem occurs when the Workflow resource has a template that includes a
templateRef
such as the example below.If the referenced template has a
podMetadata
applying annotations to containers, these are ignored.To fix this, the annotation must be applied directly to the containers in the WorkflowTemplate being referenced. This is not true if the WorkflowTemplate is executed with
argo submit
.To Reproduce
Steps to reproduce the behavior:
podMetadata
to globally apply annotations to those containersExpected behavior
A valid WorkflowTemplate, when referenced by a Sensor, should apply all of the
podMetadata
settings.Environment (please complete the following information):
Additional context
See the issue described here #2044 for the history of adding support for WorkflowTemplate's via
TemplateRef
and the pull request #2120Message from the maintainers:
If you wish to see this enhancement implemented please add a 👍 reaction to this issue! We often sort issues this way to know what to prioritize.
The text was updated successfully, but these errors were encountered: