-
Bug
-
Resolution: Unresolved
-
Major
-
None
Consulting the kubernetes plugin readme you'll find the following statements
...
Note that it was previously possible to define containerTemplate but that has been deprecated in favor of the yaml format.
...
and
...
Unlike scripted k8s template, declarative templates do not inherit from parent template. Since the agents declared at stage level can override a global agent, implicit inheritance was leading to confusion.
You need to explicitly declare the inheritance if necessary using the field inheritFrom.
In the following example, nested-pod will only contain the maven container.
...
In the following there's an example about where there's no inheritance happening. But there's no single example about how to use inheritFrom with declarative Pipeline.
Tried to define a name for the outer POD to inherit from using several different things, but seems like I did not find the right place to do so.
Please improve the documentation making it more clear about how to use this feature (if it is supposed to work).