-
Story
-
Resolution: Done
-
Undefined
-
None
-
None
-
None
-
None
-
BU Product Work
-
5
-
False
-
None
-
False
-
OCPSTRAT-169 - [Tech Preview] Apply user defined tags to all resources created by OpenShift (GCP)
-
-
Enhancement proposed for GCP labels support in OCP, requires Infrastructure CRD to be updated to include gcp userLabels in the status field, so that any new gcp resource created by an in-cluster operator can refer the field for the user defined list of labels.
Below is the snippet of change required in the CRD
apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: name: infrastructures.config.openshift.io spec: versions: - name: v1 schema: openAPIV3Schema: properties: status: properties: platformStatus: properties: gcp: properties: resourceLabels: description: resourceLabels is a list of additional labels to apply to GCP resources created for the cluster. See https://cloud.google.com/compute/docs/labeling-resources for information on labeling GCP resources. GCP supports a maximum of 64 labels per resource. OpenShift reserves 32 labels for its internal use, and allows 32 labels for user configuration. type: array maxItems: 32 items: description: GCPResourceLabels is the labels to apply to GCP resources created for the cluster. type: object required: - key - value properties: key: description: key is the name of the label type: string maxLength: 63 minLength: 1 pattern: ^[a-z][0-9a-z_-]+$ value: description: value is the value of the label. type: string maxLength: 63 minLength: 1 pattern: ^[0-9a-z_-]+$
This change is required for testing the changes of the feature, and should ideally get merged first.
Acceptance Criteria
- Code linting, validation and best practices adhered to
- Infrastructure CRD has the new field resourceLabels in platformStatus.status.gcp
- Fields descriptions
- links to