adjust the naming style for resources to make them not pass the length limit (#13345)

Signed-off-by: Gang Liu <gang.liu@daocloud.io>

Signed-off-by: Gang Liu <gang.liu@daocloud.io>
This commit is contained in:
izturn
2022-11-10 00:59:37 +08:00
committed by GitHub
parent f606604a60
commit 0ff5afe3d6
2 changed files with 4 additions and 4 deletions

View File

@@ -2,7 +2,7 @@
apiVersion: integreatly.org/v1alpha1
kind: Grafana
metadata:
name: {{ include "common.names.fullname" . }}-grafana
name: {{ printf "%s-grafana" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" }}
namespace: {{ include "common.names.namespace" . | quote }}
labels: {{- include "common.labels.standard" . | nindent 4 }}
{{- if .Values.commonLabels }}

View File

@@ -3,7 +3,7 @@
apiVersion: {{ include "common.capabilities.rbac.apiVersion" . }}
kind: Role
metadata:
name: {{ include "common.names.fullname" . }}-leader-election
name: {{ printf "%s-leader-election" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" }}
namespace: {{ include "common.names.namespace" . | quote }}
labels: {{- include "common.labels.standard" . | nindent 4 }}
{{- if .Values.commonLabels }}
@@ -48,7 +48,7 @@ rules:
apiVersion: {{ include "common.capabilities.rbac.apiVersion" . }}
kind: RoleBinding
metadata:
name: {{ include "common.names.fullname" . }}-leader-election
name: {{ printf "%s-leader-election" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" }}
namespace: {{ include "common.names.namespace" . | quote }}
labels: {{- include "common.labels.standard" . | nindent 4 }}
{{- if .Values.commonLabels }}
@@ -60,7 +60,7 @@ metadata:
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: Role
name: {{ include "common.names.fullname" . }}-leader-election
name: {{ printf "%s-leader-election" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" }}
subjects:
- kind: ServiceAccount
name: {{ include "grafana-operator.serviceAccountName" . }}