Add kube_vip_lb_fwdmethod option for kube-vip (#10762)

Signed-off-by: tu1h <lihai.tu@daocloud.io>
pull/10511/head
Louis Tu 2024-01-09 15:22:13 +08:00 committed by GitHub
parent 2e8b72e278
commit a656b7ed9a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 11 additions and 0 deletions

View File

@ -70,3 +70,9 @@ If using [control plane load-balancing](https://kube-vip.io/docs/about/architect
```yaml ```yaml
kube_vip_lb_enable: true kube_vip_lb_enable: true
``` ```
In addition, [load-balancing method](https://kube-vip.io/docs/installation/flags/#environment-variables) could be changed:
```yaml
kube_vip_lb_fwdmethod: masquerade
```

View File

@ -86,6 +86,7 @@ kube_vip_bgppeers:
kube_vip_address: kube_vip_address:
kube_vip_enableServicesElection: false kube_vip_enableServicesElection: false
kube_vip_lb_enable: false kube_vip_lb_enable: false
kube_vip_lb_fwdmethod: local
# Requests for load balancer app # Requests for load balancer app
loadbalancer_apiserver_memory_requests: 32M loadbalancer_apiserver_memory_requests: 32M

View File

@ -77,6 +77,10 @@ spec:
{% if kube_vip_lb_enable %} {% if kube_vip_lb_enable %}
- name: lb_enable - name: lb_enable
value: "true" value: "true"
{% endif %}
{% if kube_vip_lb_fwdmethod %}
- name: lb_fwdmethod
value: {{ kube_vip_lb_fwdmethod | string | to_json }}
{% endif %} {% endif %}
image: {{ kube_vip_image_repo }}:{{ kube_vip_image_tag }} image: {{ kube_vip_image_repo }}:{{ kube_vip_image_tag }}
imagePullPolicy: {{ k8s_image_pull_policy }} imagePullPolicy: {{ k8s_image_pull_policy }}