github.com/verrazzano/verrazzano@v1.7.0/platform-operator/thirdparty/charts/dex/templates/deployment.yaml (about) 1 apiVersion: apps/v1 2 kind: Deployment 3 metadata: 4 name: {{ include "dex.fullname" . }} 5 labels: 6 {{- include "dex.labels" . | nindent 4 }} 7 {{ with .Values.deploymentLabels }} 8 {{- toYaml . | nindent 4 }} 9 {{- end }} 10 {{ with .Values.deploymentAnnotations }} 11 annotations: 12 {{- toYaml . | nindent 4 }} 13 {{- end }} 14 spec: 15 {{- if not .Values.autoscaling.enabled }} 16 replicas: {{ .Values.replicaCount }} 17 {{- end }} 18 revisionHistoryLimit: {{ .Values.revisionHistoryLimit }} 19 {{- with .Values.strategy }} 20 strategy: 21 {{- toYaml . | nindent 4 }} 22 {{- end }} 23 selector: 24 matchLabels: 25 {{- include "dex.selectorLabels" . | nindent 6 }} 26 template: 27 metadata: 28 annotations: 29 {{- with .Values.podAnnotations }} 30 {{- toYaml . | nindent 8 }} 31 {{- end }} 32 {{ if .Values.configSecret.create }} 33 checksum/config: {{ include (print $.Template.BasePath "/secret.yaml") . | sha256sum }} 34 {{- end }} 35 labels: 36 {{- include "dex.selectorLabels" . | nindent 8 }} 37 {{- with .Values.podLabels }} 38 {{- toYaml . | nindent 8 }} 39 {{- end }} 40 spec: 41 {{- with .Values.imagePullSecrets }} 42 imagePullSecrets: 43 {{- toYaml . | nindent 8 }} 44 {{- end }} 45 serviceAccountName: {{ include "dex.serviceAccountName" . }} 46 {{- with .Values.priorityClassName }} 47 priorityClassName: {{ . | quote }} 48 {{- end }} 49 securityContext: 50 {{- toYaml .Values.podSecurityContext | nindent 8 }} 51 {{- with .Values.hostAliases }} 52 hostAliases: 53 {{- toYaml . | nindent 8 }} 54 {{- end }} 55 containers: 56 - name: {{ .Chart.Name }} 57 securityContext: 58 {{- toYaml .Values.securityContext | nindent 12 }} 59 image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default (printf "v%s" .Chart.AppVersion) }}" 60 imagePullPolicy: {{ .Values.image.pullPolicy }} 61 args: 62 - dex 63 - serve 64 - --web-http-addr 65 - 0.0.0.0:5556 66 {{- if .Values.https.enabled }} 67 - --web-https-addr 68 - 0.0.0.0:5554 69 {{- end }} 70 {{- if .Values.grpc.enabled }} 71 - --grpc-addr 72 - 0.0.0.0:5557 73 {{- end }} 74 - --telemetry-addr 75 - 0.0.0.0:5558 76 - /etc/dex/config.yaml 77 env: 78 {{- range $key, $value := .Values.env }} 79 - name: {{ $key }} 80 value: {{ $value | quote }} 81 {{- end }} 82 {{- with .Values.envVars }} 83 {{- toYaml . | nindent 12 }} 84 {{- end }} 85 {{- with .Values.envFrom }} 86 envFrom: 87 {{- toYaml . | nindent 12 }} 88 {{- end }} 89 ports: 90 - name: http 91 containerPort: 5556 92 protocol: TCP 93 {{- if .Values.https.enabled }} 94 - name: https 95 containerPort: 5554 96 protocol: TCP 97 {{- end }} 98 {{- if .Values.grpc.enabled }} 99 - name: grpc 100 containerPort: 5557 101 protocol: TCP 102 {{- end }} 103 - name: telemetry 104 containerPort: 5558 105 protocol: TCP 106 livenessProbe: 107 httpGet: 108 path: /healthz/live 109 port: telemetry 110 readinessProbe: 111 httpGet: 112 path: /healthz/ready 113 port: telemetry 114 resources: 115 {{- toYaml .Values.resources | nindent 12 }} 116 volumeMounts: 117 - name: config 118 mountPath: /etc/dex 119 readOnly: true 120 {{- with .Values.volumeMounts }} 121 {{- toYaml . | nindent 12 }} 122 {{- end }} 123 volumes: 124 - name: config 125 secret: 126 secretName: {{ include "dex.configSecretName" . }} 127 {{- with .Values.volumes }} 128 {{- toYaml . | nindent 8 }} 129 {{- end }} 130 {{- with .Values.nodeSelector }} 131 nodeSelector: 132 {{- toYaml . | nindent 8 }} 133 {{- end }} 134 {{- with .Values.affinity }} 135 affinity: 136 {{- toYaml . | nindent 8 }} 137 {{- end }} 138 {{- with .Values.topologySpreadConstraints }} 139 topologySpreadConstraints: 140 {{- toYaml . | nindent 8 }} 141 {{- end }} 142 {{- with .Values.tolerations }} 143 tolerations: 144 {{- toYaml . | nindent 8 }} 145 {{- end }}