Add port configuration to k8s pod
This commit is contained in:
parent
a88f0ad217
commit
5f85618cd0
|
@ -48,3 +48,15 @@ livenessProbe:
|
||||||
periodSeconds: {{ .Values.periodSeconds }}
|
periodSeconds: {{ .Values.periodSeconds }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Container Ports
|
||||||
|
*/}}
|
||||||
|
{{- define "containerPorts" }}
|
||||||
|
{{- if .Values.portForwardingList }}
|
||||||
|
ports:
|
||||||
|
{{- range $index, $config := .Values.portForwardingList }}
|
||||||
|
- containerPort: {{ $config.containerPort }}
|
||||||
|
{{- end }}
|
||||||
|
{{- end }}
|
||||||
|
{{- end }}
|
||||||
|
|
|
@ -62,6 +62,7 @@ containers:
|
||||||
{{- include "containerArgs" . | indent 2 }}
|
{{- include "containerArgs" . | indent 2 }}
|
||||||
{{- include "containerEnvVariables" . | indent 2 }}
|
{{- include "containerEnvVariables" . | indent 2 }}
|
||||||
{{- include "containerLivenssProbe" . | indent 2 }}
|
{{- include "containerLivenssProbe" . | indent 2 }}
|
||||||
|
{{- include "containerPorts" . | indent 2 }}
|
||||||
{{- include "volumeConfiguration" . }}
|
{{- include "volumeConfiguration" . }}
|
||||||
{{- include "dnsConfiguration" . }}
|
{{- include "dnsConfiguration" . }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
apiVersion: v1
|
apiVersion: v1
|
||||||
kind: Service
|
kind: Service
|
||||||
metadata:
|
metadata:
|
||||||
name: {{- include "ix-chart.fullname" . }}
|
name: {{ include "ix-chart.fullname" . }}
|
||||||
labels:
|
labels:
|
||||||
{{- include "ix-chart.labels" . | nindent 4 }}
|
{{- include "ix-chart.labels" . | nindent 4 }}
|
||||||
spec:
|
spec:
|
Loading…
Reference in New Issue