diff --git a/charts/plume/templates/_helpers.tpl b/charts/plume/templates/_helpers.tpl index 873455be..3127aacf 100644 --- a/charts/plume/templates/_helpers.tpl +++ b/charts/plume/templates/_helpers.tpl @@ -2,7 +2,7 @@ {{/* Expand the name of the chart. */}} -{{- define "Sorcerer.name" -}} +{{- define "Plume.name" -}} {{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" }} {{- end }} @@ -11,7 +11,7 @@ Create a default fully qualified app name. We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec). If release name contains chart name it will be used as a full name. */}} -{{- define "Sorcerer.fullname" -}} +{{- define "Plume.fullname" -}} {{- if .Values.fullnameOverride }} {{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" }} {{- else }} @@ -27,16 +27,16 @@ If release name contains chart name it will be used as a full name. {{/* Create chart name and version as used by the chart label. */}} -{{- define "Sorcerer.chart" -}} +{{- define "Plume.chart" -}} {{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }} {{- end }} {{/* Common labels */}} -{{- define "Sorcerer.labels" -}} -helm.sh/chart: {{ include "Sorcerer.chart" . }} -{{ include "Sorcerer.selectorLabels" . }} +{{- define "Plume.labels" -}} +helm.sh/chart: {{ include "Plume.chart" . }} +{{ include "Plume.selectorLabels" . }} {{- if .Chart.AppVersion }} app.kubernetes.io/version: {{ .Chart.AppVersion | quote }} {{- end }} @@ -46,17 +46,17 @@ app.kubernetes.io/managed-by: {{ .Release.Service }} {{/* Selector labels */}} -{{- define "Sorcerer.selectorLabels" -}} -app.kubernetes.io/name: {{ include "Sorcerer.name" . }} +{{- define "Plume.selectorLabels" -}} +app.kubernetes.io/name: {{ include "Plume.name" . }} app.kubernetes.io/instance: {{ .Release.Name }} {{- end }} {{/* Create the name of the service account to use */}} -{{- define "Sorcerer.serviceAccountName" -}} +{{- define "Plume.serviceAccountName" -}} {{- if .Values.serviceAccount.create -}} - {{ default (include "Sorcerer.fullname" .) .Values.serviceAccount.name }} + {{ default (include "Plume.fullname" .) .Values.serviceAccount.name }} {{- else -}} {{ default "default" .Values.serviceAccount.name }} {{- end -}} diff --git a/charts/plume/templates/cluster.yaml b/charts/plume/templates/cluster.yaml index 14ae12e1..f33d94b2 100644 --- a/charts/plume/templates/cluster.yaml +++ b/charts/plume/templates/cluster.yaml @@ -2,11 +2,11 @@ apiVersion: postgresql.cnpg.io/v1 kind: Cluster metadata: - name: {{ include "Sorcerer.fullname" . }} + name: {{ include "Plume.fullname" . }} annotations: linkerd.io/inject: disabled labels: - {{- include "Sorcerer.labels" . | nindent 4 }} + {{- include "Plume.labels" . | nindent 4 }} spec: instances: {{ .Values.cluster.instances | default "2" }} diff --git a/charts/plume/templates/deployment.yaml b/charts/plume/templates/deployment.yaml index bdb675ba..91d8b07f 100644 --- a/charts/plume/templates/deployment.yaml +++ b/charts/plume/templates/deployment.yaml @@ -1,16 +1,16 @@ apiVersion: apps/v1 kind: Deployment metadata: - name: {{ include "Sorcerer.fullname" . }} + name: {{ include "Plume.fullname" . }} labels: - {{- include "Sorcerer.labels" . | nindent 4 }} + {{- include "Plume.labels" . | nindent 4 }} spec: {{- if not .Values.autoscaling.enabled }} replicas: {{ .Values.replicaCount }} {{- end }} selector: matchLabels: - {{- include "Sorcerer.selectorLabels" . | nindent 6 }} + {{- include "Plume.selectorLabels" . | nindent 6 }} template: metadata: {{- with .Values.podAnnotations }} @@ -18,13 +18,13 @@ spec: {{- toYaml . | nindent 8 }} {{- end }} labels: - {{- include "Sorcerer.selectorLabels" . | nindent 8 }} + {{- include "Plume.selectorLabels" . | nindent 8 }} spec: {{- with .Values.imagePullSecrets }} imagePullSecrets: {{- toYaml . | nindent 8 }} {{- end }} - serviceAccountName: {{ include "Sorcerer.serviceAccountName" . }} + serviceAccountName: {{ include "Plume.serviceAccountName" . }} securityContext: {{- toYaml .Values.podSecurityContext | nindent 8 }} containers: @@ -78,13 +78,10 @@ spec: - name: data {{- if .Values.persistence.enabled }} persistentVolumeClaim: - claimName: {{ .Values.persistence.existingClaim | default (include "Sorcerer.fullname" .) }} + claimName: {{ .Values.persistence.existingClaim | default (include "Plume.fullname" .) }} {{- else }} emptyDir: {} {{- end }} - - name: appsettings - configMap: - name: {{ template "Sorcerer.fullname" . }}-appsettings {{- with .Values.nodeSelector }} nodeSelector: {{- toYaml . | nindent 8 }} diff --git a/charts/plume/templates/hpa.yaml b/charts/plume/templates/hpa.yaml index 5f9e4563..bd6f2cb8 100644 --- a/charts/plume/templates/hpa.yaml +++ b/charts/plume/templates/hpa.yaml @@ -2,14 +2,14 @@ apiVersion: autoscaling/v2beta1 kind: HorizontalPodAutoscaler metadata: - name: {{ include "Sorcerer.fullname" . }} + name: {{ include "Plume.fullname" . }} labels: - {{- include "Sorcerer.labels" . | nindent 4 }} + {{- include "Plume.labels" . | nindent 4 }} spec: scaleTargetRef: apiVersion: apps/v1 kind: Deployment - name: {{ include "Sorcerer.fullname" . }} + name: {{ include "Plume.fullname" . }} minReplicas: {{ .Values.autoscaling.minReplicas }} maxReplicas: {{ .Values.autoscaling.maxReplicas }} metrics: diff --git a/charts/plume/templates/ingress.yaml b/charts/plume/templates/ingress.yaml index 697dd44b..5e192721 100644 --- a/charts/plume/templates/ingress.yaml +++ b/charts/plume/templates/ingress.yaml @@ -1,5 +1,5 @@ {{- if .Values.ingress.enabled -}} -{{- $fullName := include "Sorcerer.fullname" . -}} +{{- $fullName := include "Plume.fullname" . -}} {{- $svcPort := .Values.service.port -}} {{- if and .Values.ingress.className (not (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion)) }} {{- if not (hasKey .Values.ingress.annotations "kubernetes.io/ingress.class") }} @@ -17,7 +17,7 @@ kind: Ingress metadata: name: {{ $fullName }} labels: - {{- include "Sorcerer.labels" . | nindent 4 }} + {{- include "Plume.labels" . | nindent 4 }} {{- with .Values.ingress.annotations }} annotations: {{- toYaml . | nindent 4 }} diff --git a/charts/plume/templates/internal-ingress.yaml b/charts/plume/templates/internal-ingress.yaml index 58ab6280..640fd79d 100644 --- a/charts/plume/templates/internal-ingress.yaml +++ b/charts/plume/templates/internal-ingress.yaml @@ -1,5 +1,5 @@ {{- if .Values.ingress.enabled -}} -{{- $fullName := include "Sorcerer.fullname" . -}} +{{- $fullName := include "Plume.fullname" . -}} {{- $svcPort := .Values.service.port -}} {{- if and .Values.ingress.className (not (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion)) }} {{- if not (hasKey .Values.ingress.annotations "kubernetes.io/ingress.class") }} @@ -17,7 +17,7 @@ kind: Ingress metadata: name: {{ $fullName }}-internal labels: - {{- include "Sorcerer.labels" . | nindent 4 }} + {{- include "Plume.labels" . | nindent 4 }} {{- with .Values.ingress.annotations }} annotations: atlantis.oceanbox.io/expose: internal diff --git a/charts/plume/templates/pvc.yaml b/charts/plume/templates/pvc.yaml index 5b81b095..c2b361e5 100644 --- a/charts/plume/templates/pvc.yaml +++ b/charts/plume/templates/pvc.yaml @@ -2,13 +2,13 @@ kind: PersistentVolumeClaim apiVersion: v1 metadata: - name: {{ template "Sorcerer.fullname" . }} + name: {{ template "Plume.fullname" . }} {{- with .Values.persistence.annotations }} annotations: {{ toYaml . | indent 4 }} {{- end }} labels: -{{ include "Sorcerer.labels" . | indent 4 }} +{{ include "Plume.labels" . | indent 4 }} spec: accessModes: - {{ .Values.persistence.accessMode | quote }} diff --git a/charts/plume/templates/service.yaml b/charts/plume/templates/service.yaml index bb151e12..0411cf7d 100644 --- a/charts/plume/templates/service.yaml +++ b/charts/plume/templates/service.yaml @@ -1,9 +1,9 @@ apiVersion: v1 kind: Service metadata: - name: {{ include "Sorcerer.fullname" . }} + name: {{ include "Plume.fullname" . }} labels: - {{- include "Sorcerer.labels" . | nindent 4 }} + {{- include "Plume.labels" . | nindent 4 }} spec: type: {{ .Values.service.type }} ports: @@ -12,4 +12,4 @@ spec: protocol: TCP name: http selector: - {{- include "Sorcerer.selectorLabels" . | nindent 4 }} + {{- include "Plume.selectorLabels" . | nindent 4 }} diff --git a/charts/plume/templates/serviceaccount.yaml b/charts/plume/templates/serviceaccount.yaml index 3691ec99..d1acfba1 100644 --- a/charts/plume/templates/serviceaccount.yaml +++ b/charts/plume/templates/serviceaccount.yaml @@ -2,9 +2,9 @@ apiVersion: v1 kind: ServiceAccount metadata: - name: {{ include "Sorcerer.serviceAccountName" . }} + name: {{ include "Plume.serviceAccountName" . }} labels: - {{- include "Sorcerer.labels" . | nindent 4 }} + {{- include "Plume.labels" . | nindent 4 }} {{- with .Values.serviceAccount.annotations }} annotations: {{- toYaml . | nindent 4 }}