[JIRA] (JENKINS-61072) Kubernetes declarative pipeline does not merge initContainer sections

0 views
Skip to first unread message

stephane@odul.com (JIRA)

unread,
Feb 12, 2020, 8:48:03 PM2/12/20
to jenkinsc...@googlegroups.com
Stephane Odul created an issue
 
Jenkins / Bug JENKINS-61072
Kubernetes declarative pipeline does not merge initContainer sections
Issue Type: Bug Bug
Assignee: Unassigned
Components: kubernetes-plugin
Created: 2020-02-13 01:47
Environment: kubernetes:1.23.1
Priority: Major Major
Reporter: Stephane Odul

We use declarative pipelines with `yamlMergeStrategy merge()` and a yaml entry. Some of the YAMLs have an `initContainers` section that is preserved when we do not set the merge strategy but get dropped from the final yaml when we do set the strategy to `merge()`.

https://kubernetes.io/docs/concepts/workloads/pods/init-containers/

 

Add Comment Add Comment
 
This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)
Atlassian logo

stephane@odul.com (JIRA)

unread,
Feb 12, 2020, 8:51:02 PM2/12/20
to jenkinsc...@googlegroups.com
Stephane Odul updated an issue
Change By: Stephane Odul
We use declarative pipelines with ` {{ yamlMergeStrategy merge() ` }}  and a yaml entry. Some of the YAMLs have an `initContainers` {{initContainer}}  section that is preserved when we do not set the merge strategy but get dropped from the final yaml when we do set the strategy to ` {{ merge() ` }} .

[https://kubernetes.io/docs/concepts/workloads/pods/init-containers/]

For reference the {{merge()}} option was added to the declarative pipeline in   https://github.com/jenkinsci/kubernetes-plugin/pull/638
Reply all
Reply to author
Forward
0 new messages