Commit 1e7b1845 authored by Waqar Ahmed's avatar Waqar Ahmed

Add common methods for deployment metadata

parent b91bc881
{{/*
Retrieve deployment metadata
*/}}
{{- define "common.deployment.metadata" -}}
metadata:
name: {{ template "common.names.fullname" . }}
labels: {{ include "common.labels.selectorLabels" . | nindent 4 }}
{{- end -}}
{{/*
Retrieve replicas/strategy/selector
*/}}
{{- define "common.deployment.common_spec" -}}
replicas: {{ (default 1 .Values.replicas) }}
strategy:
type: {{ (default "Recreate" .Values.strategyType ) }}
selector:
matchLabels: {{ include "common.labels.selectorLabels" . | nindent 4 }}
{{- end -}}
{{/*
Retrieve deployment pod's metadata
*/}}
{{- define "common.deployment.pod.metadata" -}}
metadata:
labels: {{ include "common.labels.selectorLabels" . | nindent 4 }}
annotations: {{ include "common.annotations" . | nindent 4 }}
{{- end -}}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment