Is the podTemplate
expected to be merged?
#6846
Labels
kind/bug
Categorizes issue or PR as related to a bug.
podTemplate
expected to be merged?
#6846
Should the
podTemplate
merge when specified inpipelineRun.spec.podTemplate
andpipelineRun.spec.taskRunSpecs[].taskPodTemplate
?Pipeline controller provides a way to specify
podTemplate
for anypipelineTask
while creatingpipelineRun
throughpipelineRun.spec.taskRunSpecs
. It is also possible to specifypodTemplate
at thepipelineRun
level throughpipelineRun.spec.podTemplate
.This section on specifying taskRunSpecs explains how
podTemplates
specified in this way results in the overwrite, for example:Like it is described in the doc, with this
pipelineRun
,build-task
will use the task specificpodTemplate
where thenodeSelector
hasdisktype
equal tossd
. But it looses any configuration frompipelineRun.spec.podTemplate
and does not have therunAsUser
,runAsGroup
, orfsGroup
set at all. I wrote a simple unit test making sure the pod templates were merged:Should the following assignment be converted into
MergePodTemplateWithDefault(task.TaskPodTemplate, s.TaskPodTemplate)
such that the rest of the configuration inpipelineRun.spec.podTemplate
?pipeline/pkg/apis/pipeline/v1beta1/pipelinerun_types.go
Line 622 in d267743
Has anyone run into this kind of issue?
/kind question
The text was updated successfully, but these errors were encountered: