Configuring FTM pod metadata

You can configure FTM pod metadata in the FTM custom resource (CR). The metadata.annotations and metadata.labels lists are optional and can be set to customize pod metadata.

The following table shows the parameters that you can use to configure the metadata for the FTM pods.
Table 1. Pod metadata configuration
CR Property name Description
resources[].metadata.annotations This string map is a list of annotations to set for the pod.
resources[].metadata.labels This string map is a list of labels to set for the pod.

Viewing pod metadata

You can view the metadata of a pod by using the following steps.
  1. To view the annotations of a pod, run the following command. Replace <pod-name> with the actual name of the pod.
    oc get pod <pod name> -o jsonpath='{.metadata.annotations}'
  2. To view the labels of a pod, run the following command. Replace <pod-name> with the actual name of the pod.
    oc get pod <pod name> -o jsonpath='{.metadata.labels}'

The following sections show examples of how to set custom annotations and labels for the FTM pods.

Example YAML 1 - Control Center metadata

In this example, the Control Center pod has one custom label and two custom annotations set.
spec:
  resources:
    - name: control-center
      metadata:
        annotations:
          test.ibm.com/time: 600s
          test.ibm.com/value: "900"
        labels:
          debug: debug-label

Example YAML 2 - Custom and Default metadata

In this example, the Control Center pod has the custom annotation test.ibm.com/time set to 600s and test.ibm.com/value set to 900. The Control Center pod also has the labels debug set to debug-label and logging to logging-label.

All FTM pods that do not have the custom annotation test.ibm.com/time set use the default value 200s. Likewise, all pods that do not have the custom label logging set use the default value logging-label-default.

spec:
  resources:
    - name: control-center
      metadata:
        annotations:
          test.ibm.com/time: 600s
          test.ibm.com/value: "900"
        labels:
          debug: debug-label
          logging: logging-label
    - name: default
      metadata:
        annotations:
          test.ibm.com/time: 200s
        labels:
          logging: logging-label-default