Skip to content

Commit 3770626

Browse files
authored
Merge pull request #9206 from zalando-incubator/skipper/inline-kube-health-2
skipper-ingress: explicit healthcheck routes on the pod level
2 parents 2fe8033 + 27f9e03 commit 3770626

File tree

1 file changed

+18
-4
lines changed

1 file changed

+18
-4
lines changed

cluster/manifests/skipper/deployment.yaml

Lines changed: 18 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -171,6 +171,7 @@ spec:
171171
{{ else }}
172172
- "-kubernetes"
173173
- "-kubernetes-in-cluster"
174+
- "-kubernetes-healthcheck=false" # see -inline-routes
174175
- "-kubernetes-path-mode=path-prefix"
175176
- "-kubernetes-backend-traffic-algorithm={{ .Cluster.ConfigItems.skipper_ingress_backend_traffic_algorithm }}"
176177
- "-kubernetes-default-lb-algorithm={{ .Cluster.ConfigItems.skipper_ingress_default_lb_algorithm }}"
@@ -190,7 +191,6 @@ spec:
190191
- '-kubernetes-annotation-filters-append={{ .Cluster.ConfigItems.skipper_kubernetes_annotation_filters_append }}'
191192
- '-kubernetes-east-west-range-annotation-predicates={{ .Cluster.ConfigItems.skipper_kubernetes_east_west_range_annotation_predicates }}'
192193
- '-kubernetes-east-west-range-annotation-filters-append={{ .Cluster.ConfigItems.skipper_kubernetes_east_west_range_annotation_filters_append }}'
193-
- "-reverse-source-predicate"
194194
{{ end }}
195195
- "-proxy-preserve-host"
196196
- "-compress-encodings={{ .Cluster.ConfigItems.skipper_compress_encodings }}"
@@ -323,9 +323,23 @@ spec:
323323
- "-forwarded-headers=X-Forwarded-For,X-Forwarded-Proto=https,X-Forwarded-Port=443"
324324
- '-forwarded-headers-exclude-cidrs={{ .cluster_internal_cidrs | join "," }}'
325325
{{ end }}
326-
{{ if .Cluster.ConfigItems.skipper_ingress_inline_routes }}
327-
- "-inline-routes={{ .Cluster.ConfigItems.skipper_ingress_inline_routes }}"
328-
{{ end }}
326+
- >-
327+
-inline-routes=
328+
kube__healthz_down:
329+
Path("/kube-system/healthz") &&
330+
Shutdown() &&
331+
SourceFromLast("10.0.0.0/8", "192.168.0.0/16", "172.16.0.0/12", "127.0.0.1/8", "::1/128"{{- if and (eq .Cluster.Provider "zalando-eks") (eq .Cluster.ConfigItems.eks_ip_family "ipv6")}}{{ range $ip := split .Values.subnet_ipv6_cidrs "," }},"{{ $ip }}"{{ end }}{{- else }}, "fd00::/8"{{- end }})
332+
-> disableAccessLog()
333+
-> status(503)
334+
-> <shunt>;
335+
kube__healthz_up:
336+
Path("/kube-system/healthz") &&
337+
SourceFromLast("10.0.0.0/8", "192.168.0.0/16", "172.16.0.0/12", "127.0.0.1/8", "::1/128"{{- if and (eq .Cluster.Provider "zalando-eks") (eq .Cluster.ConfigItems.eks_ip_family "ipv6")}}{{ range $ip := split .Values.subnet_ipv6_cidrs "," }},"{{ $ip }}"{{ end }}{{- else }}, "fd00::/8"{{- end }})
338+
-> disableAccessLog()
339+
-> status(200)
340+
-> <shunt>;
341+
{{ .Cluster.ConfigItems.skipper_ingress_inline_routes }}
342+
329343
{{ if .Cluster.ConfigItems.skipper_ingress_health_check_options }}
330344
- "-passive-health-check={{ .Cluster.ConfigItems.skipper_ingress_health_check_options }}"
331345
{{ end }}

0 commit comments

Comments
 (0)