Add HAProxy as internal loadbalancer (#4480)

This commit is contained in:
Andreas Krüger
2019-04-10 14:56:18 +02:00
committed by Kubernetes Prow Robot
parent 27958e4247
commit 5e0249ae7c
14 changed files with 163 additions and 23 deletions

View File

@@ -19,7 +19,7 @@ stream {
}
server {
listen 127.0.0.1:{{ nginx_kube_apiserver_port|default(kube_apiserver_port) }};
listen {{ loadbalancer_apiserver_port|default(kube_apiserver_port) }};
proxy_pass kube_apiserver;
proxy_timeout 10m;
proxy_connect_timeout 1s;
@@ -38,13 +38,13 @@ http {
server_tokens off;
autoindex off;
{% if nginx_kube_apiserver_healthcheck_port is defined -%}
{% if loadbalancer_apiserver_healthcheck_port is defined -%}
server {
listen {{ nginx_kube_apiserver_healthcheck_port }};
listen {{ loadbalancer_apiserver_healthcheck_port }};
location /healthz {
access_log off;
return 200;
}
}
{% endif -%}
{% endif %}
}