I’m currently working on developing a custom plugin for our company, intended to extend the functionality of the official release-k8s-integration plugin. My goal is to execute kubectl commands with label-based filtering, specifically to list namespaces matching a given label.
I’ve made good progress so far. After reviewing the available options, I decided to build on the existing plugin rather than starting from scratch. I attempted to define a custom type as follows:
Copy
<type type="CustomPlugin.ListNamespacesByLabel" label="List namespaces by label" extends="kubernetes.ListNamespaces">
<property name="cmdParams" kind="string" category="input" required="false" label="Command Parameters" description="(e.g. -l application=monapplication)"/>
</type>From what I understand, the container only recognizes command types that are explicitly registered in the binary. Extending an existing type is not sufficient to make it executable. I’m currently blocked at this stage and looking for a solution that would allow me to inject label filtering into a supported command.
This plugin relies on the following Docker image:
docker.io/xebialabs/release-k8s-integration:25.1.4-808.849
Since this image is not publicly available or modifiable, I’m limited in how I can extend its behavior.
Could you advise on how to proceed? Specifically:
Is there a supported way to inject dynamic parameters (like -l application=...) into a recognized command type?
Is it possible to register new command types externally, or override existing ones safely?
Are there any recommended approaches for extending the plugin ?