From 752c8a513be8ddac53903c3deef297d20f9ca791 Mon Sep 17 00:00:00 2001 From: Lalith Kota Date: Tue, 25 Jun 2024 02:12:23 +0530 Subject: [PATCH] Helm charts: Fixed broken labels for templates Signed-off-by: Lalith Kota --- .../esignet/templates/clusterrolebinding.yaml | 5 +---- .../templates/configmap-spring-confg.yaml | 12 ++++-------- charts/esignet/templates/configmap-startup.yaml | 12 ++++-------- charts/esignet/templates/deployment.yaml | 12 ++++-------- charts/esignet/templates/gateway.yaml | 5 +---- charts/esignet/templates/oidc-ui/configmap.yaml | 5 +---- .../esignet/templates/oidc-ui/deployment.yaml | 12 ++++-------- charts/esignet/templates/oidc-ui/gateway.yaml | 5 +---- charts/esignet/templates/oidc-ui/service.yaml | 5 +---- .../templates/oidc-ui/virtualservice.yaml | 5 +---- charts/esignet/templates/postgresInit/job.yaml | 15 ++++----------- .../esignet/templates/postgresql/gateway.yaml | 9 +++------ .../templates/postgresql/virtualservice.yaml | 9 +++------ charts/esignet/templates/secret-git-config.yaml | 12 ++++-------- charts/esignet/templates/service-account.yaml | 5 +---- charts/esignet/templates/service.yaml | 12 ++++-------- charts/esignet/templates/servicemonitor.yaml | 10 ++++------ charts/esignet/templates/virtualservice.yaml | 5 +---- charts/esignet/values.yaml | 2 +- .../templates/clusterrolebinding.yaml | 5 +---- .../templates/configmap-spring-confg.yaml | 12 ++++-------- .../keymanager/templates/configmap-startup.yaml | 12 ++++-------- charts/keymanager/templates/deployment.yaml | 12 ++++-------- charts/keymanager/templates/gateway.yaml | 5 +---- .../templates/keygen/configmap-startup.yaml | 12 ++++-------- charts/keymanager/templates/keygen/job.yaml | 5 +---- .../keymanager/templates/postgresInit/job.yaml | 5 +---- .../templates/postgresql/gateway.yaml | 9 +++------ .../templates/postgresql/virtualservice.yaml | 9 +++------ .../keymanager/templates/secret-git-config.yaml | 12 ++++-------- .../keymanager/templates/service-account.yaml | 5 +---- charts/keymanager/templates/service.yaml | 12 ++++-------- charts/keymanager/templates/servicemonitor.yaml | 10 ++++------ charts/keymanager/templates/virtualservice.yaml | 5 +---- .../templates/clusterrolebinding.yaml | 5 +---- .../templates/configmap-spring-confg.yaml | 12 ++++-------- .../templates/configmap-startup.yaml | 12 ++++-------- .../templates/deployment.yaml | 12 ++++-------- .../mock-identity-system/templates/gateway.yaml | 5 +---- .../templates/keygen/configmap-startup.yaml | 12 ++++-------- .../templates/keygen/job.yaml | 5 +---- .../templates/postgresInit/job.yaml | 5 +---- .../templates/postgresql/gateway.yaml | 9 +++------ .../templates/postgresql/virtualservice.yaml | 9 +++------ .../templates/secret-git-config.yaml | 12 ++++-------- .../templates/service-account.yaml | 5 +---- .../mock-identity-system/templates/service.yaml | 12 ++++-------- .../templates/servicemonitor.yaml | 10 ++++------ .../templates/virtualservice.yaml | 5 +---- .../templates/backend/configmap.yaml | 4 ++++ .../templates/backend/deployment.yaml | 17 +++++------------ charts/odk-central/templates/backend/svc.yaml | 5 +---- .../templates/frontend/configmap.yaml | 4 ++++ .../templates/frontend/deployment.yaml | 17 +++++------------ charts/odk-central/templates/frontend/svc.yaml | 5 +---- charts/odk-central/templates/gateway.yaml | 5 +---- charts/odk-central/templates/ingress.yaml | 5 +---- .../templates/postgresql/gateway.yaml | 9 +++------ .../templates/postgresql/virtualservice.yaml | 9 +++------ .../odk-central/templates/service-account.yaml | 5 +---- .../odk-central/templates/virtualservice.yaml | 5 +---- charts/odk-central/values.yaml | 4 ++-- 62 files changed, 159 insertions(+), 352 deletions(-) diff --git a/charts/esignet/templates/clusterrolebinding.yaml b/charts/esignet/templates/clusterrolebinding.yaml index 2be8130..21ddffe 100644 --- a/charts/esignet/templates/clusterrolebinding.yaml +++ b/charts/esignet/templates/clusterrolebinding.yaml @@ -2,10 +2,7 @@ apiVersion: {{ include "common.capabilities.rbac.apiVersion" . }} kind: ClusterRoleBinding metadata: name: {{ template "common.names.fullname" . }} - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} {{- if .Values.commonAnnotations }} annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} diff --git a/charts/esignet/templates/configmap-spring-confg.yaml b/charts/esignet/templates/configmap-spring-confg.yaml index 4a8dfe2..9b1ae7f 100644 --- a/charts/esignet/templates/configmap-spring-confg.yaml +++ b/charts/esignet/templates/configmap-spring-confg.yaml @@ -3,14 +3,10 @@ apiVersion: v1 kind: ConfigMap metadata: name: {{ template "common.names.fullname" . }}-spring-config - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} - annotations: - {{- if .Values.commonAnnotations }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} data: application.properties: |- {{- include "common.tplvalues.render" (dict "value" .Values.springConfig.rawConfig "context" $) | nindent 4 }} diff --git a/charts/esignet/templates/configmap-startup.yaml b/charts/esignet/templates/configmap-startup.yaml index f474f8d..915c8ab 100644 --- a/charts/esignet/templates/configmap-startup.yaml +++ b/charts/esignet/templates/configmap-startup.yaml @@ -3,14 +3,10 @@ apiVersion: v1 kind: ConfigMap metadata: name: {{ template "common.names.fullname" . }}-startup - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} - annotations: - {{- if .Values.commonAnnotations }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} data: startup.sh: |- {{- include "common.tplvalues.render" (dict "value" .Values.startUpCommand "context" $) | nindent 4 }} diff --git a/charts/esignet/templates/deployment.yaml b/charts/esignet/templates/deployment.yaml index 2bcf7f7..6ede5c2 100644 --- a/charts/esignet/templates/deployment.yaml +++ b/charts/esignet/templates/deployment.yaml @@ -1,15 +1,11 @@ apiVersion: {{ include "common.capabilities.deployment.apiVersion" . }} kind: Deployment metadata: - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} name: {{ template "common.names.fullname" . }} - annotations: - {{- if .Values.commonAnnotations }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} spec: replicas: {{ .Values.replicaCount }} {{- if .Values.updateStrategy }} diff --git a/charts/esignet/templates/gateway.yaml b/charts/esignet/templates/gateway.yaml index 7c525d7..8083264 100644 --- a/charts/esignet/templates/gateway.yaml +++ b/charts/esignet/templates/gateway.yaml @@ -4,10 +4,7 @@ apiVersion: networking.istio.io/v1beta1 kind: Gateway metadata: name: {{ template "common.names.fullname" . }} - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} {{- if .Values.commonAnnotations }} annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} diff --git a/charts/esignet/templates/oidc-ui/configmap.yaml b/charts/esignet/templates/oidc-ui/configmap.yaml index e066294..e9ee741 100644 --- a/charts/esignet/templates/oidc-ui/configmap.yaml +++ b/charts/esignet/templates/oidc-ui/configmap.yaml @@ -3,10 +3,7 @@ apiVersion: v1 kind: ConfigMap metadata: name: {{ template "common.names.fullname" . }}-oidc-ui-nginx-cm - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} {{- if .Values.commonAnnotations }} annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} diff --git a/charts/esignet/templates/oidc-ui/deployment.yaml b/charts/esignet/templates/oidc-ui/deployment.yaml index faa6598..df56e0b 100644 --- a/charts/esignet/templates/oidc-ui/deployment.yaml +++ b/charts/esignet/templates/oidc-ui/deployment.yaml @@ -3,14 +3,10 @@ apiVersion: {{ include "common.capabilities.deployment.apiVersion" . }} kind: Deployment metadata: name: {{ template "common.names.fullname" . }}-oidc-ui - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} - annotations: - {{- if .Values.commonAnnotations }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} spec: replicas: {{ .Values.oidcUi.replicaCount }} {{- if .Values.oidcUi.updateStrategy }} diff --git a/charts/esignet/templates/oidc-ui/gateway.yaml b/charts/esignet/templates/oidc-ui/gateway.yaml index 24a07df..1868abe 100644 --- a/charts/esignet/templates/oidc-ui/gateway.yaml +++ b/charts/esignet/templates/oidc-ui/gateway.yaml @@ -5,10 +5,7 @@ apiVersion: networking.istio.io/v1beta1 kind: Gateway metadata: name: {{ template "common.names.fullname" . }}-oidc-ui - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} {{- if .Values.commonAnnotations }} annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} diff --git a/charts/esignet/templates/oidc-ui/service.yaml b/charts/esignet/templates/oidc-ui/service.yaml index dff4ff0..4abfcc7 100644 --- a/charts/esignet/templates/oidc-ui/service.yaml +++ b/charts/esignet/templates/oidc-ui/service.yaml @@ -2,11 +2,8 @@ apiVersion: v1 kind: Service metadata: - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} name: {{ template "common.names.fullname" . }}-oidc-ui + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} {{- if .Values.commonAnnotations }} annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} diff --git a/charts/esignet/templates/oidc-ui/virtualservice.yaml b/charts/esignet/templates/oidc-ui/virtualservice.yaml index 3c9a10a..456b9e9 100644 --- a/charts/esignet/templates/oidc-ui/virtualservice.yaml +++ b/charts/esignet/templates/oidc-ui/virtualservice.yaml @@ -5,10 +5,7 @@ apiVersion: networking.istio.io/v1alpha3 kind: VirtualService metadata: name: {{ template "common.names.fullname" . }}-oidc-ui - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} {{- if .Values.commonAnnotations }} annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} diff --git a/charts/esignet/templates/postgresInit/job.yaml b/charts/esignet/templates/postgresInit/job.yaml index 504ab2a..c27b49b 100644 --- a/charts/esignet/templates/postgresInit/job.yaml +++ b/charts/esignet/templates/postgresInit/job.yaml @@ -3,17 +3,10 @@ apiVersion: batch/v1 kind: Job metadata: name: {{ template "common.names.fullname" . }}-postgres-init - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} - annotations: - "helm.sh/hook": post-install - "helm.sh/hook-weight": "0" - "helm.sh/hook-delete-policy": before-hook-creation - {{- if .Values.commonAnnotations }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} spec: {{- if .Values.postgresInit.backoffLimit }} backoffLimit: {{ .Values.postgresInit.backoffLimit }} diff --git a/charts/esignet/templates/postgresql/gateway.yaml b/charts/esignet/templates/postgresql/gateway.yaml index 603a773..4b64fc7 100644 --- a/charts/esignet/templates/postgresql/gateway.yaml +++ b/charts/esignet/templates/postgresql/gateway.yaml @@ -5,12 +5,9 @@ apiVersion: networking.istio.io/v1alpha3 kind: Gateway metadata: name: {{ include "postgresql.v1.primary.fullname" .Subcharts.postgresql }} - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} - {{- if .Values.commonAnnotations }} - annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.postgresql.commonLabels "context" .Subcharts.postgresql) | nindent 4 }} + {{- if .Values.postgresql.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.postgresql.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} spec: selector: diff --git a/charts/esignet/templates/postgresql/virtualservice.yaml b/charts/esignet/templates/postgresql/virtualservice.yaml index 9330f4f..e510a57 100644 --- a/charts/esignet/templates/postgresql/virtualservice.yaml +++ b/charts/esignet/templates/postgresql/virtualservice.yaml @@ -5,12 +5,9 @@ apiVersion: networking.istio.io/v1alpha3 kind: VirtualService metadata: name: {{ include "postgresql.v1.primary.fullname" .Subcharts.postgresql }} - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} - {{- if .Values.commonAnnotations }} - annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.postgresql.commonLabels "context" .Subcharts.postgresql) | nindent 4 }} + {{- if .Values.postgresql.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.postgresql.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} spec: hosts: diff --git a/charts/esignet/templates/secret-git-config.yaml b/charts/esignet/templates/secret-git-config.yaml index 5950906..0be0429 100644 --- a/charts/esignet/templates/secret-git-config.yaml +++ b/charts/esignet/templates/secret-git-config.yaml @@ -3,14 +3,10 @@ apiVersion: v1 kind: Secret metadata: name: {{ template "common.names.fullname" . }}-git-config-secret - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} - annotations: - {{- if .Values.commonAnnotations }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} type: Opaque data: {{- range $k, $v := (omit .Values.springConfig.gitRepo "enabled" "envVars") }} diff --git a/charts/esignet/templates/service-account.yaml b/charts/esignet/templates/service-account.yaml index b91dfcd..ce00f11 100644 --- a/charts/esignet/templates/service-account.yaml +++ b/charts/esignet/templates/service-account.yaml @@ -1,11 +1,8 @@ apiVersion: v1 kind: ServiceAccount metadata: - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} name: {{ template "esignet.serviceAccountName" . }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} {{- if .Values.commonAnnotations }} annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} diff --git a/charts/esignet/templates/service.yaml b/charts/esignet/templates/service.yaml index 083f1ff..ef318a5 100644 --- a/charts/esignet/templates/service.yaml +++ b/charts/esignet/templates/service.yaml @@ -1,15 +1,11 @@ apiVersion: v1 kind: Service metadata: - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} name: {{ template "common.names.fullname" . }} - annotations: - {{- if .Values.commonAnnotations }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} spec: type: {{ .Values.service.type }} {{- if (or (eq .Values.service.type "LoadBalancer") (eq .Values.service.type "NodePort")) }} diff --git a/charts/esignet/templates/servicemonitor.yaml b/charts/esignet/templates/servicemonitor.yaml index 699d6bb..e068e8e 100644 --- a/charts/esignet/templates/servicemonitor.yaml +++ b/charts/esignet/templates/servicemonitor.yaml @@ -5,13 +5,11 @@ metadata: name: {{ template "common.names.fullname" . }} {{- if .Values.metrics.serviceMonitor.namespace }} namespace: {{ .Values.metrics.serviceMonitor.namespace }} - {{- else }} - namespace: {{ .Release.Namespace | quote }} {{- end }} - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.metrics.serviceMonitor.additionalLabels }} - {{- include "common.tplvalues.render" (dict "value" .Values.metrics.serviceMonitor.additionalLabels "context" $) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.metrics.serviceMonitor.additionalLabels "context" $) | nindent 4 }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} spec: endpoints: - targetPort: {{ .Values.springServicePort }} diff --git a/charts/esignet/templates/virtualservice.yaml b/charts/esignet/templates/virtualservice.yaml index 4cbe4f7..cc1ff3d 100644 --- a/charts/esignet/templates/virtualservice.yaml +++ b/charts/esignet/templates/virtualservice.yaml @@ -4,10 +4,7 @@ apiVersion: networking.istio.io/v1alpha3 kind: VirtualService metadata: name: {{ template "common.names.fullname" . }} - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} {{- if .Values.commonAnnotations }} annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} diff --git a/charts/esignet/values.yaml b/charts/esignet/values.yaml index 4a2c0ab..e4109c8 100644 --- a/charts/esignet/values.yaml +++ b/charts/esignet/values.yaml @@ -685,7 +685,7 @@ oidcUi: nodeSelector: {} tolerations: [] podLabels: - app.kubernetes.io/name: esignet-oidc-ui + app.kubernetes.io/name: '{{ include "common.names.name" . }}-oidc-ui' podAnnotations: {} # priorityClassName: "" lifecycleHooks: {} diff --git a/charts/keymanager/templates/clusterrolebinding.yaml b/charts/keymanager/templates/clusterrolebinding.yaml index 0fc6e98..88f303a 100644 --- a/charts/keymanager/templates/clusterrolebinding.yaml +++ b/charts/keymanager/templates/clusterrolebinding.yaml @@ -1,11 +1,8 @@ kind: ClusterRoleBinding apiVersion: {{ include "common.capabilities.rbac.apiVersion" . }} metadata: - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} name: {{ template "common.names.fullname" . }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} {{- if .Values.commonAnnotations }} annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} diff --git a/charts/keymanager/templates/configmap-spring-confg.yaml b/charts/keymanager/templates/configmap-spring-confg.yaml index 4a8dfe2..9b1ae7f 100644 --- a/charts/keymanager/templates/configmap-spring-confg.yaml +++ b/charts/keymanager/templates/configmap-spring-confg.yaml @@ -3,14 +3,10 @@ apiVersion: v1 kind: ConfigMap metadata: name: {{ template "common.names.fullname" . }}-spring-config - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} - annotations: - {{- if .Values.commonAnnotations }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} data: application.properties: |- {{- include "common.tplvalues.render" (dict "value" .Values.springConfig.rawConfig "context" $) | nindent 4 }} diff --git a/charts/keymanager/templates/configmap-startup.yaml b/charts/keymanager/templates/configmap-startup.yaml index f474f8d..915c8ab 100644 --- a/charts/keymanager/templates/configmap-startup.yaml +++ b/charts/keymanager/templates/configmap-startup.yaml @@ -3,14 +3,10 @@ apiVersion: v1 kind: ConfigMap metadata: name: {{ template "common.names.fullname" . }}-startup - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} - annotations: - {{- if .Values.commonAnnotations }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} data: startup.sh: |- {{- include "common.tplvalues.render" (dict "value" .Values.startUpCommand "context" $) | nindent 4 }} diff --git a/charts/keymanager/templates/deployment.yaml b/charts/keymanager/templates/deployment.yaml index a296362..72632b5 100644 --- a/charts/keymanager/templates/deployment.yaml +++ b/charts/keymanager/templates/deployment.yaml @@ -1,15 +1,11 @@ apiVersion: {{ include "common.capabilities.deployment.apiVersion" . }} kind: Deployment metadata: - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} name: {{ template "common.names.fullname" . }} - annotations: - {{- if .Values.commonAnnotations }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} spec: replicas: {{ .Values.replicaCount }} {{- if .Values.updateStrategy }} diff --git a/charts/keymanager/templates/gateway.yaml b/charts/keymanager/templates/gateway.yaml index 7c525d7..8083264 100644 --- a/charts/keymanager/templates/gateway.yaml +++ b/charts/keymanager/templates/gateway.yaml @@ -4,10 +4,7 @@ apiVersion: networking.istio.io/v1beta1 kind: Gateway metadata: name: {{ template "common.names.fullname" . }} - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} {{- if .Values.commonAnnotations }} annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} diff --git a/charts/keymanager/templates/keygen/configmap-startup.yaml b/charts/keymanager/templates/keygen/configmap-startup.yaml index f855dde..eeeaf7e 100644 --- a/charts/keymanager/templates/keygen/configmap-startup.yaml +++ b/charts/keymanager/templates/keygen/configmap-startup.yaml @@ -4,14 +4,10 @@ apiVersion: v1 kind: ConfigMap metadata: name: {{ template "common.names.fullname" . }}-keygen-startup - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} - annotations: - {{- if .Values.commonAnnotations }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} data: startup.sh: |- {{- include "common.tplvalues.render" (dict "value" .Values.keygen.startUpCommand "context" $) | nindent 4 }} diff --git a/charts/keymanager/templates/keygen/job.yaml b/charts/keymanager/templates/keygen/job.yaml index 02ae7b2..20173b8 100644 --- a/charts/keymanager/templates/keygen/job.yaml +++ b/charts/keymanager/templates/keygen/job.yaml @@ -3,10 +3,7 @@ apiVersion: batch/v1 kind: Job metadata: name: {{ template "common.names.fullname" . }}-keygen - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} annotations: "helm.sh/hook": post-install "helm.sh/hook-weight": "1" diff --git a/charts/keymanager/templates/postgresInit/job.yaml b/charts/keymanager/templates/postgresInit/job.yaml index d9436b3..682c958 100644 --- a/charts/keymanager/templates/postgresInit/job.yaml +++ b/charts/keymanager/templates/postgresInit/job.yaml @@ -3,10 +3,7 @@ apiVersion: batch/v1 kind: Job metadata: name: {{ template "common.names.fullname" . }}-postgres-init - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} annotations: "helm.sh/hook": post-install "helm.sh/hook-weight": "0" diff --git a/charts/keymanager/templates/postgresql/gateway.yaml b/charts/keymanager/templates/postgresql/gateway.yaml index 603a773..4b64fc7 100644 --- a/charts/keymanager/templates/postgresql/gateway.yaml +++ b/charts/keymanager/templates/postgresql/gateway.yaml @@ -5,12 +5,9 @@ apiVersion: networking.istio.io/v1alpha3 kind: Gateway metadata: name: {{ include "postgresql.v1.primary.fullname" .Subcharts.postgresql }} - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} - {{- if .Values.commonAnnotations }} - annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.postgresql.commonLabels "context" .Subcharts.postgresql) | nindent 4 }} + {{- if .Values.postgresql.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.postgresql.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} spec: selector: diff --git a/charts/keymanager/templates/postgresql/virtualservice.yaml b/charts/keymanager/templates/postgresql/virtualservice.yaml index 9330f4f..e510a57 100644 --- a/charts/keymanager/templates/postgresql/virtualservice.yaml +++ b/charts/keymanager/templates/postgresql/virtualservice.yaml @@ -5,12 +5,9 @@ apiVersion: networking.istio.io/v1alpha3 kind: VirtualService metadata: name: {{ include "postgresql.v1.primary.fullname" .Subcharts.postgresql }} - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} - {{- if .Values.commonAnnotations }} - annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.postgresql.commonLabels "context" .Subcharts.postgresql) | nindent 4 }} + {{- if .Values.postgresql.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.postgresql.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} spec: hosts: diff --git a/charts/keymanager/templates/secret-git-config.yaml b/charts/keymanager/templates/secret-git-config.yaml index 5950906..0be0429 100644 --- a/charts/keymanager/templates/secret-git-config.yaml +++ b/charts/keymanager/templates/secret-git-config.yaml @@ -3,14 +3,10 @@ apiVersion: v1 kind: Secret metadata: name: {{ template "common.names.fullname" . }}-git-config-secret - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} - annotations: - {{- if .Values.commonAnnotations }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} type: Opaque data: {{- range $k, $v := (omit .Values.springConfig.gitRepo "enabled" "envVars") }} diff --git a/charts/keymanager/templates/service-account.yaml b/charts/keymanager/templates/service-account.yaml index 5e39ead..f4c2e9c 100644 --- a/charts/keymanager/templates/service-account.yaml +++ b/charts/keymanager/templates/service-account.yaml @@ -1,11 +1,8 @@ apiVersion: v1 kind: ServiceAccount metadata: - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} name: {{ template "keymanager.serviceAccountName" . }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} {{- if .Values.commonAnnotations }} annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} diff --git a/charts/keymanager/templates/service.yaml b/charts/keymanager/templates/service.yaml index 083f1ff..ef318a5 100644 --- a/charts/keymanager/templates/service.yaml +++ b/charts/keymanager/templates/service.yaml @@ -1,15 +1,11 @@ apiVersion: v1 kind: Service metadata: - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} name: {{ template "common.names.fullname" . }} - annotations: - {{- if .Values.commonAnnotations }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} spec: type: {{ .Values.service.type }} {{- if (or (eq .Values.service.type "LoadBalancer") (eq .Values.service.type "NodePort")) }} diff --git a/charts/keymanager/templates/servicemonitor.yaml b/charts/keymanager/templates/servicemonitor.yaml index 699d6bb..e068e8e 100644 --- a/charts/keymanager/templates/servicemonitor.yaml +++ b/charts/keymanager/templates/servicemonitor.yaml @@ -5,13 +5,11 @@ metadata: name: {{ template "common.names.fullname" . }} {{- if .Values.metrics.serviceMonitor.namespace }} namespace: {{ .Values.metrics.serviceMonitor.namespace }} - {{- else }} - namespace: {{ .Release.Namespace | quote }} {{- end }} - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.metrics.serviceMonitor.additionalLabels }} - {{- include "common.tplvalues.render" (dict "value" .Values.metrics.serviceMonitor.additionalLabels "context" $) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.metrics.serviceMonitor.additionalLabels "context" $) | nindent 4 }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} spec: endpoints: - targetPort: {{ .Values.springServicePort }} diff --git a/charts/keymanager/templates/virtualservice.yaml b/charts/keymanager/templates/virtualservice.yaml index 4cbe4f7..cc1ff3d 100644 --- a/charts/keymanager/templates/virtualservice.yaml +++ b/charts/keymanager/templates/virtualservice.yaml @@ -4,10 +4,7 @@ apiVersion: networking.istio.io/v1alpha3 kind: VirtualService metadata: name: {{ template "common.names.fullname" . }} - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} {{- if .Values.commonAnnotations }} annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} diff --git a/charts/mock-identity-system/templates/clusterrolebinding.yaml b/charts/mock-identity-system/templates/clusterrolebinding.yaml index 7ad094e..d84c6d0 100644 --- a/charts/mock-identity-system/templates/clusterrolebinding.yaml +++ b/charts/mock-identity-system/templates/clusterrolebinding.yaml @@ -2,10 +2,7 @@ apiVersion: {{ include "common.capabilities.rbac.apiVersion" . }} kind: ClusterRoleBinding metadata: name: {{ template "common.names.fullname" . }} - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} {{- if .Values.commonAnnotations }} annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} diff --git a/charts/mock-identity-system/templates/configmap-spring-confg.yaml b/charts/mock-identity-system/templates/configmap-spring-confg.yaml index 4a8dfe2..9b1ae7f 100644 --- a/charts/mock-identity-system/templates/configmap-spring-confg.yaml +++ b/charts/mock-identity-system/templates/configmap-spring-confg.yaml @@ -3,14 +3,10 @@ apiVersion: v1 kind: ConfigMap metadata: name: {{ template "common.names.fullname" . }}-spring-config - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} - annotations: - {{- if .Values.commonAnnotations }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} data: application.properties: |- {{- include "common.tplvalues.render" (dict "value" .Values.springConfig.rawConfig "context" $) | nindent 4 }} diff --git a/charts/mock-identity-system/templates/configmap-startup.yaml b/charts/mock-identity-system/templates/configmap-startup.yaml index f474f8d..915c8ab 100644 --- a/charts/mock-identity-system/templates/configmap-startup.yaml +++ b/charts/mock-identity-system/templates/configmap-startup.yaml @@ -3,14 +3,10 @@ apiVersion: v1 kind: ConfigMap metadata: name: {{ template "common.names.fullname" . }}-startup - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} - annotations: - {{- if .Values.commonAnnotations }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} data: startup.sh: |- {{- include "common.tplvalues.render" (dict "value" .Values.startUpCommand "context" $) | nindent 4 }} diff --git a/charts/mock-identity-system/templates/deployment.yaml b/charts/mock-identity-system/templates/deployment.yaml index 53c0396..17fb5c2 100644 --- a/charts/mock-identity-system/templates/deployment.yaml +++ b/charts/mock-identity-system/templates/deployment.yaml @@ -1,15 +1,11 @@ apiVersion: {{ include "common.capabilities.deployment.apiVersion" . }} kind: Deployment metadata: - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} name: {{ template "common.names.fullname" . }} - annotations: - {{- if .Values.commonAnnotations }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} spec: replicas: {{ .Values.replicaCount }} {{- if .Values.updateStrategy }} diff --git a/charts/mock-identity-system/templates/gateway.yaml b/charts/mock-identity-system/templates/gateway.yaml index 7c525d7..8083264 100644 --- a/charts/mock-identity-system/templates/gateway.yaml +++ b/charts/mock-identity-system/templates/gateway.yaml @@ -4,10 +4,7 @@ apiVersion: networking.istio.io/v1beta1 kind: Gateway metadata: name: {{ template "common.names.fullname" . }} - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} {{- if .Values.commonAnnotations }} annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} diff --git a/charts/mock-identity-system/templates/keygen/configmap-startup.yaml b/charts/mock-identity-system/templates/keygen/configmap-startup.yaml index f855dde..eeeaf7e 100644 --- a/charts/mock-identity-system/templates/keygen/configmap-startup.yaml +++ b/charts/mock-identity-system/templates/keygen/configmap-startup.yaml @@ -4,14 +4,10 @@ apiVersion: v1 kind: ConfigMap metadata: name: {{ template "common.names.fullname" . }}-keygen-startup - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} - annotations: - {{- if .Values.commonAnnotations }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} data: startup.sh: |- {{- include "common.tplvalues.render" (dict "value" .Values.keygen.startUpCommand "context" $) | nindent 4 }} diff --git a/charts/mock-identity-system/templates/keygen/job.yaml b/charts/mock-identity-system/templates/keygen/job.yaml index a92de85..5880bd6 100644 --- a/charts/mock-identity-system/templates/keygen/job.yaml +++ b/charts/mock-identity-system/templates/keygen/job.yaml @@ -3,10 +3,7 @@ apiVersion: batch/v1 kind: Job metadata: name: {{ template "common.names.fullname" . }}-keygen - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} annotations: "helm.sh/hook": post-install "helm.sh/hook-weight": "1" diff --git a/charts/mock-identity-system/templates/postgresInit/job.yaml b/charts/mock-identity-system/templates/postgresInit/job.yaml index f3e531b..bf68f0c 100644 --- a/charts/mock-identity-system/templates/postgresInit/job.yaml +++ b/charts/mock-identity-system/templates/postgresInit/job.yaml @@ -3,10 +3,7 @@ apiVersion: batch/v1 kind: Job metadata: name: {{ template "common.names.fullname" . }}-postgres-init - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} annotations: "helm.sh/hook": post-install "helm.sh/hook-weight": "0" diff --git a/charts/mock-identity-system/templates/postgresql/gateway.yaml b/charts/mock-identity-system/templates/postgresql/gateway.yaml index 603a773..4b64fc7 100644 --- a/charts/mock-identity-system/templates/postgresql/gateway.yaml +++ b/charts/mock-identity-system/templates/postgresql/gateway.yaml @@ -5,12 +5,9 @@ apiVersion: networking.istio.io/v1alpha3 kind: Gateway metadata: name: {{ include "postgresql.v1.primary.fullname" .Subcharts.postgresql }} - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} - {{- if .Values.commonAnnotations }} - annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.postgresql.commonLabels "context" .Subcharts.postgresql) | nindent 4 }} + {{- if .Values.postgresql.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.postgresql.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} spec: selector: diff --git a/charts/mock-identity-system/templates/postgresql/virtualservice.yaml b/charts/mock-identity-system/templates/postgresql/virtualservice.yaml index 9330f4f..e510a57 100644 --- a/charts/mock-identity-system/templates/postgresql/virtualservice.yaml +++ b/charts/mock-identity-system/templates/postgresql/virtualservice.yaml @@ -5,12 +5,9 @@ apiVersion: networking.istio.io/v1alpha3 kind: VirtualService metadata: name: {{ include "postgresql.v1.primary.fullname" .Subcharts.postgresql }} - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} - {{- if .Values.commonAnnotations }} - annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.postgresql.commonLabels "context" .Subcharts.postgresql) | nindent 4 }} + {{- if .Values.postgresql.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.postgresql.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} spec: hosts: diff --git a/charts/mock-identity-system/templates/secret-git-config.yaml b/charts/mock-identity-system/templates/secret-git-config.yaml index 5950906..0be0429 100644 --- a/charts/mock-identity-system/templates/secret-git-config.yaml +++ b/charts/mock-identity-system/templates/secret-git-config.yaml @@ -3,14 +3,10 @@ apiVersion: v1 kind: Secret metadata: name: {{ template "common.names.fullname" . }}-git-config-secret - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} - annotations: - {{- if .Values.commonAnnotations }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} type: Opaque data: {{- range $k, $v := (omit .Values.springConfig.gitRepo "enabled" "envVars") }} diff --git a/charts/mock-identity-system/templates/service-account.yaml b/charts/mock-identity-system/templates/service-account.yaml index 028fce3..89dcda4 100644 --- a/charts/mock-identity-system/templates/service-account.yaml +++ b/charts/mock-identity-system/templates/service-account.yaml @@ -1,11 +1,8 @@ apiVersion: v1 kind: ServiceAccount metadata: - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} name: {{ template "mock-identity-system.serviceAccountName" . }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} {{- if .Values.commonAnnotations }} annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} diff --git a/charts/mock-identity-system/templates/service.yaml b/charts/mock-identity-system/templates/service.yaml index 083f1ff..ef318a5 100644 --- a/charts/mock-identity-system/templates/service.yaml +++ b/charts/mock-identity-system/templates/service.yaml @@ -1,15 +1,11 @@ apiVersion: v1 kind: Service metadata: - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} name: {{ template "common.names.fullname" . }} - annotations: - {{- if .Values.commonAnnotations }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} spec: type: {{ .Values.service.type }} {{- if (or (eq .Values.service.type "LoadBalancer") (eq .Values.service.type "NodePort")) }} diff --git a/charts/mock-identity-system/templates/servicemonitor.yaml b/charts/mock-identity-system/templates/servicemonitor.yaml index 699d6bb..e068e8e 100644 --- a/charts/mock-identity-system/templates/servicemonitor.yaml +++ b/charts/mock-identity-system/templates/servicemonitor.yaml @@ -5,13 +5,11 @@ metadata: name: {{ template "common.names.fullname" . }} {{- if .Values.metrics.serviceMonitor.namespace }} namespace: {{ .Values.metrics.serviceMonitor.namespace }} - {{- else }} - namespace: {{ .Release.Namespace | quote }} {{- end }} - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.metrics.serviceMonitor.additionalLabels }} - {{- include "common.tplvalues.render" (dict "value" .Values.metrics.serviceMonitor.additionalLabels "context" $) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.metrics.serviceMonitor.additionalLabels "context" $) | nindent 4 }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} spec: endpoints: - targetPort: {{ .Values.springServicePort }} diff --git a/charts/mock-identity-system/templates/virtualservice.yaml b/charts/mock-identity-system/templates/virtualservice.yaml index 4cbe4f7..cc1ff3d 100644 --- a/charts/mock-identity-system/templates/virtualservice.yaml +++ b/charts/mock-identity-system/templates/virtualservice.yaml @@ -4,10 +4,7 @@ apiVersion: networking.istio.io/v1alpha3 kind: VirtualService metadata: name: {{ template "common.names.fullname" . }} - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} {{- if .Values.commonAnnotations }} annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} diff --git a/charts/odk-central/templates/backend/configmap.yaml b/charts/odk-central/templates/backend/configmap.yaml index 7c6bce6..a360dee 100644 --- a/charts/odk-central/templates/backend/configmap.yaml +++ b/charts/odk-central/templates/backend/configmap.yaml @@ -3,6 +3,10 @@ apiVersion: v1 kind: ConfigMap metadata: name: {{ include "common.names.fullname" . }}-backend + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} data: config.json.template: |- {{- include "common.tplvalues.render" (dict "value" .Values.backend.configJsonTemplate "context" $) | nindent 4 }} diff --git a/charts/odk-central/templates/backend/deployment.yaml b/charts/odk-central/templates/backend/deployment.yaml index df76cdd..66fabe3 100644 --- a/charts/odk-central/templates/backend/deployment.yaml +++ b/charts/odk-central/templates/backend/deployment.yaml @@ -3,10 +3,7 @@ apiVersion: {{ include "common.capabilities.deployment.apiVersion" . }} kind: Deployment metadata: name: {{ include "common.names.fullname" . }}-backend - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} {{- if .Values.commonAnnotations }} annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} @@ -19,14 +16,10 @@ spec: matchLabels: {{- include "common.labels.matchLabels" (dict "customLabels" .Values.backend.podLabels "context" $) | nindent 6 }} template: metadata: - annotations: - {{- if .Values.backend.podAnnotations }} - {{- include "common.tplvalues.render" (dict "value" .Values.backend.podAnnotations "context" $) | nindent 8 }} - {{- end }} - labels: {{- include "common.labels.standard" . | nindent 8 }} - {{- if .Values.backend.podLabels }} - {{- include "common.tplvalues.render" (dict "value" .Values.backend.podLabels "context" $) | nindent 8 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.backend.podLabels "context" $) | nindent 8 }} + {{- if .Values.backend.podAnnotations }} + annotations: {{- include "common.tplvalues.render" (dict "value" .Values.backend.podAnnotations "context" $) | nindent 8 }} + {{- end }} spec: serviceAccountName: {{ default (include "common.names.fullname" .) .Values.serviceAccount.name }} {{- include "common.images.pullSecrets" (dict "images" (list .Values.backend.image) "global" .Values.global) | nindent 6 }} diff --git a/charts/odk-central/templates/backend/svc.yaml b/charts/odk-central/templates/backend/svc.yaml index 7b0088b..c3dfc85 100644 --- a/charts/odk-central/templates/backend/svc.yaml +++ b/charts/odk-central/templates/backend/svc.yaml @@ -3,10 +3,7 @@ apiVersion: v1 kind: Service metadata: name: {{ include "common.names.fullname" . }}-backend - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} {{- if .Values.commonAnnotations }} annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} diff --git a/charts/odk-central/templates/frontend/configmap.yaml b/charts/odk-central/templates/frontend/configmap.yaml index 67e3f74..52faacb 100644 --- a/charts/odk-central/templates/frontend/configmap.yaml +++ b/charts/odk-central/templates/frontend/configmap.yaml @@ -3,6 +3,10 @@ apiVersion: v1 kind: ConfigMap metadata: name: {{ include "common.names.fullname" . }}-frontend + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} data: odk.conf.template: |- {{- include "common.tplvalues.render" (dict "value" .Values.frontend.odkConfTemplate "context" $) | nindent 4 }} diff --git a/charts/odk-central/templates/frontend/deployment.yaml b/charts/odk-central/templates/frontend/deployment.yaml index 54e5cc4..adc020c 100644 --- a/charts/odk-central/templates/frontend/deployment.yaml +++ b/charts/odk-central/templates/frontend/deployment.yaml @@ -3,10 +3,7 @@ apiVersion: {{ include "common.capabilities.deployment.apiVersion" . }} kind: Deployment metadata: name: {{ include "common.names.fullname" . }}-frontend - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} {{- if .Values.commonAnnotations }} annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} @@ -19,14 +16,10 @@ spec: matchLabels: {{- include "common.labels.matchLabels" (dict "customLabels" .Values.frontend.podLabels "context" $) | nindent 6 }} template: metadata: - annotations: - {{- if .Values.frontend.podAnnotations }} - {{- include "common.tplvalues.render" (dict "value" .Values.frontend.podAnnotations "context" $) | nindent 8 }} - {{- end }} - labels: {{- include "common.labels.standard" . | nindent 8 }} - {{- if .Values.frontend.podLabels }} - {{- include "common.tplvalues.render" (dict "value" .Values.frontend.podLabels "context" $) | nindent 8 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.frontend.podLabels "context" $) | nindent 8 }} + {{- if .Values.frontend.podAnnotations }} + annotations: {{- include "common.tplvalues.render" (dict "value" .Values.frontend.podAnnotations "context" $) | nindent 8 }} + {{- end }} spec: serviceAccountName: {{ default (include "common.names.fullname" .) .Values.serviceAccount.name }} {{- include "common.images.pullSecrets" (dict "images" (list .Values.frontend.image) "global" .Values.global) | nindent 6 }} diff --git a/charts/odk-central/templates/frontend/svc.yaml b/charts/odk-central/templates/frontend/svc.yaml index 4f1f43c..a7682b1 100644 --- a/charts/odk-central/templates/frontend/svc.yaml +++ b/charts/odk-central/templates/frontend/svc.yaml @@ -3,10 +3,7 @@ apiVersion: v1 kind: Service metadata: name: {{ include "common.names.fullname" . }}-frontend - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} {{- if .Values.commonAnnotations }} annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} diff --git a/charts/odk-central/templates/gateway.yaml b/charts/odk-central/templates/gateway.yaml index 7541f3f..bf89d76 100644 --- a/charts/odk-central/templates/gateway.yaml +++ b/charts/odk-central/templates/gateway.yaml @@ -4,10 +4,7 @@ apiVersion: networking.istio.io/v1alpha3 kind: Gateway metadata: name: {{ include "common.names.fullname" . }} - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} {{- if .Values.commonAnnotations }} annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} diff --git a/charts/odk-central/templates/ingress.yaml b/charts/odk-central/templates/ingress.yaml index a65c5ad..899407f 100644 --- a/charts/odk-central/templates/ingress.yaml +++ b/charts/odk-central/templates/ingress.yaml @@ -3,10 +3,7 @@ apiVersion: {{ include "common.capabilities.ingress.apiVersion" . }} kind: Ingress metadata: name: {{ template "common.names.fullname" . }} - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} annotations: {{- if .Values.ingress.annotations }} {{- include "common.tplvalues.render" ( dict "value" .Values.ingress.annotations "context" $) | nindent 4 }} diff --git a/charts/odk-central/templates/postgresql/gateway.yaml b/charts/odk-central/templates/postgresql/gateway.yaml index 603a773..4b64fc7 100644 --- a/charts/odk-central/templates/postgresql/gateway.yaml +++ b/charts/odk-central/templates/postgresql/gateway.yaml @@ -5,12 +5,9 @@ apiVersion: networking.istio.io/v1alpha3 kind: Gateway metadata: name: {{ include "postgresql.v1.primary.fullname" .Subcharts.postgresql }} - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} - {{- if .Values.commonAnnotations }} - annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.postgresql.commonLabels "context" .Subcharts.postgresql) | nindent 4 }} + {{- if .Values.postgresql.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.postgresql.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} spec: selector: diff --git a/charts/odk-central/templates/postgresql/virtualservice.yaml b/charts/odk-central/templates/postgresql/virtualservice.yaml index 9330f4f..e510a57 100644 --- a/charts/odk-central/templates/postgresql/virtualservice.yaml +++ b/charts/odk-central/templates/postgresql/virtualservice.yaml @@ -5,12 +5,9 @@ apiVersion: networking.istio.io/v1alpha3 kind: VirtualService metadata: name: {{ include "postgresql.v1.primary.fullname" .Subcharts.postgresql }} - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} - {{- if .Values.commonAnnotations }} - annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.postgresql.commonLabels "context" .Subcharts.postgresql) | nindent 4 }} + {{- if .Values.postgresql.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.postgresql.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} spec: hosts: diff --git a/charts/odk-central/templates/service-account.yaml b/charts/odk-central/templates/service-account.yaml index 3972453..7dd9901 100644 --- a/charts/odk-central/templates/service-account.yaml +++ b/charts/odk-central/templates/service-account.yaml @@ -3,10 +3,7 @@ apiVersion: v1 kind: ServiceAccount metadata: name: {{ default (include "common.names.fullname" .) .Values.serviceAccount.name }} - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} {{- if .Values.commonAnnotations }} annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} diff --git a/charts/odk-central/templates/virtualservice.yaml b/charts/odk-central/templates/virtualservice.yaml index b7f1e7b..f0bdb87 100644 --- a/charts/odk-central/templates/virtualservice.yaml +++ b/charts/odk-central/templates/virtualservice.yaml @@ -4,10 +4,7 @@ apiVersion: networking.istio.io/v1alpha3 kind: VirtualService metadata: name: {{ include "common.names.fullname" . }} - labels: {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.commonLabels }} - {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} - {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }} {{- if .Values.commonAnnotations }} annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} diff --git a/charts/odk-central/values.yaml b/charts/odk-central/values.yaml index a0a8794..259613b 100644 --- a/charts/odk-central/values.yaml +++ b/charts/odk-central/values.yaml @@ -59,7 +59,7 @@ backend: podAnnotations: {} podLabels: - app.kubernetes.io/name: odk-central-backend + app.kubernetes.io/name: '{{ include "common.names.name" . }}-backend' containerPort: 8383 service: @@ -268,7 +268,7 @@ frontend: containerPort: 80 podAnnotations: {} podLabels: - app.kubernetes.io/name: odk-central-frontend + app.kubernetes.io/name: '{{ include "common.names.name" . }}-frontend' service: type: ClusterIP