diff --git a/config/metrics/metrics.yaml b/config/metrics/metrics.yaml index 391aa77a1663..50ed111216ae 100644 --- a/config/metrics/metrics.yaml +++ b/config/metrics/metrics.yaml @@ -1,3 +1,7 @@ +# Generated by controller-gen version v0.0.0-00010101000000-000000000000 +# Generated based on types for kube-state-metrics v2.13.0 +--- +kind: CustomResourceStateMetrics spec: resources: - errorLogV: 0 @@ -525,14 +529,12 @@ spec: info: labelsFromPath: node_name: - - status - - nodeRef - name node_uid: - - status - - nodeRef - uid - path: null + path: + - status + - nodeRef type: Info help: Information about the node reference of a machine. name: status_noderef @@ -845,9 +847,9 @@ spec: - each: info: labelsFromPath: - name: - - metadata - - name + maxUnhealthy: + - spec + - maxUnhealthy path: null type: Info help: Information about a machinehealthcheck. @@ -905,7 +907,7 @@ spec: name: status_condition_last_transition_time - each: gauge: - nilIsZero: false + nilIsZero: true path: - status - currentHealthy @@ -915,17 +917,17 @@ spec: name: status_current_healthy - each: gauge: - nilIsZero: false + nilIsZero: true path: - status - expectedMachines valueFrom: null type: Gauge - help: Total number of pods counted by this machinehealthcheck. + help: Total number of machines counted by this machinehealthcheck. name: status_expected_machines - each: gauge: - nilIsZero: false + nilIsZero: true path: - status - remediationsAllowed @@ -1017,7 +1019,7 @@ spec: - version path: null type: Info - help: "" + help: Information about a machinepool. name: info - each: info: @@ -1300,7 +1302,7 @@ spec: name: status_replicas_available - each: gauge: - nilIsZero: false + nilIsZero: true path: - status - fullyLabeledReplicas @@ -1488,4 +1490,3 @@ spec: help: The number of updated replicas per kubeadmcontrolplane. name: status_replicas_updated resourcePlural: "" - diff --git a/config/metrics/rbac.yaml b/config/metrics/rbac.yaml index bcd5bde16ba3..bed50b0a70a0 100644 --- a/config/metrics/rbac.yaml +++ b/config/metrics/rbac.yaml @@ -2,20 +2,28 @@ apiVersion: rbac.authorization.k8s.io/v1 kind: ClusterRole metadata: - name: kube-state-metrics-custom-resource-capi labels: kube-state-metrics/aggregate-to-manager: "true" + name: manager-metrics-role rules: +- apiGroups: + - bootstrap.cluster.x-k8s.io + resources: + - kubeadmconfigs + verbs: + - get + - list + - watch - apiGroups: - cluster.x-k8s.io resources: - clusterclasses - clusters - machinedeployments + - machinehealthchecks - machinepools - - machinesets - machines - - machinehealthchecks + - machinesets verbs: - get - list @@ -28,11 +36,3 @@ rules: - get - list - watch -- apiGroups: - - bootstrap.cluster.x-k8s.io - resources: - - kubeadmconfigs - verbs: - - get - - list - - watch