Use apps/v1 k8s controllers and add labels
Update apiversion for deployment to apps/v1 Add selector match labels to deployment This patch is similar to https://review.opendev.org/#/c/638276/ These changes are required to install deckhand helm chart on k8s 1.16.0 Change-Id: Ifca6020dee953252629f42a1b04f384e959c0916
This commit is contained in:
parent
070124b578
commit
abbbf3d6b2
@ -16,12 +16,13 @@
|
|||||||
|
|
||||||
{{- if .Values.manifests.deployment }}
|
{{- if .Values.manifests.deployment }}
|
||||||
{{- $envAll := . }}
|
{{- $envAll := . }}
|
||||||
|
{{- $labels := tuple $envAll "deckhand" "api" | include "helm-toolkit.snippets.kubernetes_metadata_labels" -}}
|
||||||
{{- $mounts_deckhand := .Values.pod.mounts.deckhand.deckhand }}
|
{{- $mounts_deckhand := .Values.pod.mounts.deckhand.deckhand }}
|
||||||
{{- $mounts_deckhand_init := .Values.pod.mounts.deckhand.init_container }}
|
{{- $mounts_deckhand_init := .Values.pod.mounts.deckhand.init_container }}
|
||||||
{{- $serviceAccountName := "deckhand" }}
|
{{- $serviceAccountName := "deckhand" }}
|
||||||
{{ tuple $envAll "deckhand" $serviceAccountName | include "helm-toolkit.snippets.kubernetes_pod_rbac_serviceaccount" }}
|
{{ tuple $envAll "deckhand" $serviceAccountName | include "helm-toolkit.snippets.kubernetes_pod_rbac_serviceaccount" }}
|
||||||
---
|
---
|
||||||
apiVersion: apps/v1beta1
|
apiVersion: apps/v1
|
||||||
kind: Deployment
|
kind: Deployment
|
||||||
metadata:
|
metadata:
|
||||||
name: deckhand-api
|
name: deckhand-api
|
||||||
@ -29,11 +30,14 @@ metadata:
|
|||||||
{{ tuple $envAll | include "helm-toolkit.snippets.release_uuid" }}
|
{{ tuple $envAll | include "helm-toolkit.snippets.release_uuid" }}
|
||||||
spec:
|
spec:
|
||||||
replicas: {{ .Values.pod.replicas.deckhand }}
|
replicas: {{ .Values.pod.replicas.deckhand }}
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
{{ $labels | indent 6 }}
|
||||||
{{ tuple $envAll | include "helm-toolkit.snippets.kubernetes_upgrades_deployment" | indent 2 }}
|
{{ tuple $envAll | include "helm-toolkit.snippets.kubernetes_upgrades_deployment" | indent 2 }}
|
||||||
template:
|
template:
|
||||||
metadata:
|
metadata:
|
||||||
labels:
|
labels:
|
||||||
{{ tuple $envAll "deckhand" "api" | include "helm-toolkit.snippets.kubernetes_metadata_labels" | indent 8 }}
|
{{ $labels | indent 8 }}
|
||||||
annotations:
|
annotations:
|
||||||
{{ tuple $envAll | include "helm-toolkit.snippets.release_uuid" | indent 8 }}
|
{{ tuple $envAll | include "helm-toolkit.snippets.release_uuid" | indent 8 }}
|
||||||
configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }}
|
configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user