mirror of
https://github.com/PyratLabs/ansible-role-k3s
synced 2024-11-05 21:33:30 +01:00
34 lines
936 B
Text
34 lines
936 B
Text
worker_processes 4;
|
|
worker_rlimit_nofile 40000;
|
|
|
|
events {
|
|
worker_connections 8192;
|
|
}
|
|
|
|
stream {
|
|
# Set up our upstream of control (master) nodes. The default load balancing
|
|
# algorithm for nginx is to round-robin. Perfect!
|
|
upstream control_plane {
|
|
server node2:6443 max_fails=3 fail_timeout=5s;
|
|
server node3:6443 max_fails=3 fail_timeout=5s;
|
|
}
|
|
|
|
upstream control_plane_443 {
|
|
server node2:443 max_fails=3 fail_timeout=5s;
|
|
server node3:443 max_fails=3 fail_timeout=5s;
|
|
}
|
|
|
|
# Listen on port 6443, this is our default control plane port, then pass
|
|
# all traffic to one of the control (master) nodes.
|
|
server {
|
|
listen 6443;
|
|
proxy_pass control_plane;
|
|
}
|
|
|
|
# Listen on port 443, this is our default ssl port, then pass
|
|
# all traffic to one of the control (master) nodes.
|
|
server {
|
|
listen 443;
|
|
proxy_pass control_plane_443;
|
|
}
|
|
}
|