diff --git a/templates/containers.tmpl b/templates/containers.tmpl index 30845f1..22d1b48 100644 --- a/templates/containers.tmpl +++ b/templates/containers.tmpl @@ -11,7 +11,7 @@ {{- if .Ports}} ports: {{- range .Ports}} - - containerPort: {{.Port}} + - containerPort: {{- if .TargetPort }} {{.TargetPort}} {{- else }} {{.Port}} {{- end}} name: {{.Name}} {{- end}} {{- end}}