Annotations in Managed controller Pods and Statefulsets

Article ID:360030995031
1 minute readKnowledge base

Issue

You would like to use annotations in Managed controllers Pods and Statefulsets

Resolution

For a single Managed controller

In the Managed controller configuration, under the Advanced configuration you can customize the items being sent to the server, using YAML.

modern-cloud-mm-config.png
modern-cloud-mm-config-yaml.png
  • For Pods annotations use:

      kind: StatefulSet
      spec:
        template:
          metadata:
              annotations:
                  foo: bar
  • And for Statefulsets annotations:

      kind: StatefulSet
      metadata:
          annotations:
              foo: bar

For all the Managed controllers

The same configuration can be applied in the Operation Center under Manage Jenkins  Configure System  Kubernetes controller Provisioning  Advanced  YAML. This setting would apply to newly created controller only (including Team controllers).

Tested products/plugins version

The latest update of this article was tested with: