Finished lb and db
Signed-off-by: Tuan-Dat Tran <tuan-dat.tran@tudattr.dev>
This commit is contained in:
16
roles/loadbalancer/templates/nginx.conf.j2
Normal file
16
roles/loadbalancer/templates/nginx.conf.j2
Normal file
@@ -0,0 +1,16 @@
|
||||
include /etc/nginx/modules-enabled/*.conf;
|
||||
|
||||
events {}
|
||||
|
||||
stream {
|
||||
upstream k3s_servers {
|
||||
{% for ip in k3s_server_ips %}
|
||||
server {{ ip }}:6443;
|
||||
{% endfor %}
|
||||
}
|
||||
|
||||
server {
|
||||
listen 6443;
|
||||
proxy_pass k3s_servers;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user