d92124561d
Fixes #655. This is a teporary solution for long-polling idle connections to apiserver. It will make Nginx not cut them for the duration of expected timeout. It will also make Nginx extremely slow in realizing that there is some issue with connectivity to apiserver as well, so it might not be perfect permanent solution.
26 lines
644 B
Django/Jinja
26 lines
644 B
Django/Jinja
error_log stderr notice;
|
|
|
|
worker_processes auto;
|
|
events {
|
|
multi_accept on;
|
|
use epoll;
|
|
worker_connections 1024;
|
|
}
|
|
|
|
stream {
|
|
upstream kube_apiserver {
|
|
least_conn;
|
|
{% for host in groups['kube-master'] -%}
|
|
server {{ hostvars[host]['access_ip'] | default(hostvars[host]['ip'] | default(hostvars[host]['ansible_default_ipv4']['address'])) }}:{{ kube_apiserver_port }};
|
|
{% endfor %}
|
|
}
|
|
|
|
server {
|
|
listen {{ kube_apiserver_port }};
|
|
proxy_pass kube_apiserver;
|
|
proxy_timeout 10m;
|
|
proxy_connect_timeout 1s;
|
|
|
|
}
|
|
|
|
}
|