adde generation of Server resources.

This commit is contained in:
2025-01-19 22:18:44 +01:00
parent f27f3610ab
commit 496e58347c
4 changed files with 30 additions and 1 deletions
@@ -14,4 +14,4 @@ spec:
{{- else }}
fail (printf "no service accounts defined for app %s" .Name )
{{- end}}
@@ -0,0 +1,16 @@
{{- range $port := .Ports }}
{{- if or (eq $port.Protocol "TCP") (not $port.Protocol) }}
---
apiVersion: policy.linkerd.io/v1beta1
kind: Server
metadata:
name: {{ $.Name }}-p{{ $port.Port }}
namespace: {{ $.Namespace.Name }}
spec:
podSelector:
matchLabels: {{ $.MatchLabels | toJson }}
matchExpressions: {{ $.MatchExpressions | toJson }}
port: {{ $port.Port }}
#proxyProtocol: "HTTP/2"
{{- end }}
{{- end }}