Added option to install MetalLB

This commit is contained in:
kimiroo 2026-01-04 20:33:17 +09:00
parent 2b3315df22
commit c201702b9a
5 changed files with 15 additions and 2 deletions

View File

@ -93,6 +93,8 @@ kube_vip_tag_version: v1.0.0
# (uncomment to use kube-vip for services instead of MetalLB)
# kube_vip_lb_ip_range: "192.168.30.80-192.168.30.90"
metal_lb_install: true
# metallb type frr or native
metal_lb_type: native

View File

@ -90,6 +90,11 @@ argument_specs:
description: IP range for kube-vip load balancer
default: ~
metal_lb_install:
description: Install MetalLB
default: true
type: bool
metal_lb_controller_tag_version:
description: Image tag for MetalLB
default: v0.14.3

View File

@ -24,10 +24,11 @@
- name: Deploy vip manifest
ansible.builtin.include_tasks: vip.yml
- name: Deploy metallb manifest
ansible.builtin.include_tasks: metallb.yml
tags: metallb
when: kube_vip_lb_ip_range is not defined and (not cilium_bgp or cilium_iface is not defined)
when: kube_vip_lb_ip_range is not defined and (not cilium_bgp or cilium_iface is not defined) and metal_lb_install
- name: Deploy kube-vip manifest
ansible.builtin.include_tasks: kube-vip.yml

View File

@ -121,6 +121,11 @@ argument_specs:
description: IP range for kube-vip load balancer
default: ~
metal_lb_install:
description: Install MetalLB
default: true
type: bool
metal_lb_available_timeout:
description: Wait for MetalLB resources
default: 240s

View File

@ -12,7 +12,7 @@
- name: Deploy metallb pool
ansible.builtin.include_tasks: metallb.yml
tags: metallb
when: kube_vip_lb_ip_range is not defined and (not cilium_bgp or cilium_iface is not defined)
when: kube_vip_lb_ip_range is not defined and (not cilium_bgp or cilium_iface is not defined) and metal_lb_install
- name: Remove tmp directory used for manifests
ansible.builtin.file: