* Fix for helm 3 and k8s 1.16 * Inclusion of archived directory under k8s * separate deploy-all powershell script for local Mac OS deployment.
		
			
				
	
	
		
			110 lines
		
	
	
		
			3.5 KiB
		
	
	
	
		
			YAML
		
	
	
	
	
	
			
		
		
	
	
			110 lines
		
	
	
		
			3.5 KiB
		
	
	
	
		
			YAML
		
	
	
	
	
	
| {{- $name := include "apigwws.fullname" . -}}
 | |
| {{- $cfgname := printf "%s-%s" "cfg" $name -}}
 | |
| {{- $envoycfgname := printf "%s-%s" "envoy" $name -}}
 | |
| apiVersion: apps/v1
 | |
| kind: Deployment
 | |
| metadata:
 | |
|   name: {{ template "apigwws.fullname" . }}
 | |
|   labels:
 | |
|     app: {{ template "apigwws.name" . }}
 | |
|     chart: {{ template "apigwws.chart" . }}
 | |
|     release: {{ .Release.Name }}
 | |
|     heritage: {{ .Release.Service }}
 | |
| spec:
 | |
|   replicas: {{ .Values.replicaCount }}
 | |
|   selector:
 | |
|     matchLabels:
 | |
|       app: {{ template "apigwws.name" . }}
 | |
|       release: {{ .Release.Name }}
 | |
|   template:
 | |
|     metadata:
 | |
|       labels:
 | |
|         app: {{ template "apigwws.name" . }}
 | |
|         release: {{ .Release.Name }}
 | |
|       {{ if .Values.inf.mesh.enabled -}}
 | |
|       annotations:
 | |
|         linkerd.io/inject: enabled
 | |
|       {{- end }}           
 | |
|     spec:
 | |
|       {{ if .Values.inf.registry -}}
 | |
|       imagePullSecrets:
 | |
|       - name: {{ .Values.inf.registry.secretName }}
 | |
|       {{- end }}
 | |
|       volumes:
 | |
|       - name: config
 | |
|         configMap:
 | |
|           name: {{ $envoycfgname }}
 | |
|           items:
 | |
|           - key: envoy.yaml
 | |
|             path: envoy.yaml
 | |
|       containers:
 | |
|         - name: {{ .Chart.Name }}
 | |
|           {{ if .Values.probes -}}
 | |
|           {{- if .Values.probes.liveness -}}
 | |
|           livenessProbe:
 | |
|             httpGet:
 | |
|               port: {{ .Values.probes.liveness.port }}
 | |
|               path: {{ .Values.probes.liveness.path }}
 | |
|             initialDelaySeconds: {{ .Values.probes.liveness.initialDelaySeconds }}
 | |
|             periodSeconds: {{ .Values.probes.liveness.periodSeconds }}
 | |
|           {{- end -}}
 | |
|           {{- end -}}
 | |
|           {{- if .Values.probes -}}
 | |
|           {{- if .Values.probes.readiness }}
 | |
|           readinessProbe:
 | |
|             httpGet:
 | |
|               port: {{ .Values.probes.readiness.port }}
 | |
|               path: {{ .Values.probes.readiness.path }}
 | |
|             initialDelaySeconds: {{ .Values.probes.readiness.initialDelaySeconds }}
 | |
|             periodSeconds: {{ .Values.probes.readiness.periodSeconds }}
 | |
|             timeoutSeconds: {{ .Values.probes.readiness.timeoutSeconds }}
 | |
|           {{- end -}}
 | |
|           {{- end }}        
 | |
|           image: "{{ template "fqdn-image" . }}:{{ .Values.image.tag }}"
 | |
|           imagePullPolicy: {{ .Values.image.pullPolicy }}
 | |
|           volumeMounts:
 | |
|           - name: config
 | |
|             mountPath: {{ .Values.envoy.configPath }}      
 | |
|           env:
 | |
|             - name: PATH_BASE
 | |
|               value: {{ include "pathBase" . }}
 | |
|             - name: k8sname
 | |
|               value: {{ .Values.clusterName }}
 | |
|           {{- if .Values.env.values -}}
 | |
|           {{- range .Values.env.values }}
 | |
|             - name: {{ .name }}
 | |
|               value: {{ .value | quote }}
 | |
|           {{- end -}}
 | |
|           {{- end -}}
 | |
|           {{- if .Values.env.configmap -}}
 | |
|           {{- range .Values.env.configmap }}
 | |
|             - name: {{ .name }}
 | |
|               valueFrom:
 | |
|                 configMapKeyRef:
 | |
|                   name: {{ $cfgname }}
 | |
|                   key: {{ .key }}
 | |
|           {{- end -}}
 | |
|           {{- end }}
 | |
|           ports:
 | |
|             - name: http
 | |
|               containerPort: 80
 | |
|               protocol: TCP
 | |
|             - name: admin
 | |
|               containerPort: 8001
 | |
|               protocol: TCP
 | |
|           resources:
 | |
| {{ toYaml .Values.resources | indent 12 }}
 | |
|     {{- with .Values.nodeSelector }}
 | |
|       nodeSelector:
 | |
| {{ toYaml . | indent 8 }}
 | |
|     {{- end }}
 | |
|     {{- with .Values.affinity }}
 | |
|       affinity:
 | |
| {{ toYaml . | indent 8 }}
 | |
|     {{- end }}
 | |
|     {{- with .Values.tolerations }}
 | |
|       tolerations:
 | |
| {{ toYaml . | indent 8 }}
 | |
|     {{- end }}
 | |
| 
 |