github.com/terraform-modules-krish/terratest@v0.29.0/examples/helm-basic-example/templates/deployment.yaml (about)

     1  apiVersion: apps/v1
     2  kind: Deployment
     3  metadata:
     4    name: {{ include "helm-basic-example.fullname" . }}
     5    namespace: {{ .Release.Namespace }}
     6    labels:
     7      # These labels are required by helm. You can read more about required labels in the chart best pracices guide:
     8      # https://docs.helm.sh/chart_best_practices/#standard-labels
     9      helm.sh/chart: {{ include "helm-basic-example.chart" . }}
    10      app.kubernetes.io/name: {{ include "helm-basic-example.name" . }}
    11      app.kubernetes.io/instance: {{ .Release.Name }}
    12      app.kubernetes.io/managed-by: {{ .Release.Service }}
    13  spec:
    14    replicas: 1
    15    selector:
    16      matchLabels:
    17        app.kubernetes.io/name: {{ include "helm-basic-example.name" . }}
    18        app.kubernetes.io/instance: {{ .Release.Name }}
    19    template:
    20      metadata:
    21        labels:
    22          app.kubernetes.io/name: {{ include "helm-basic-example.name" . }}
    23          app.kubernetes.io/instance: {{ .Release.Name }}
    24      spec:
    25        containers:
    26          - name: app
    27            {{- $repo := required "containerImageRepo is required" .Values.containerImageRepo }}
    28            {{- $tag := required "containerImageTag is required" .Values.containerImageTag }}
    29            image: "{{ $repo }}:{{ $tag }}"
    30            ports:
    31            - containerPort: 80