Skip to content

Commit

Permalink
[metallb] add config option for IPAddressPool avoidBuggyIPs (kubernet…
Browse files Browse the repository at this point in the history
…es-sigs#10458)

* Add avoid_buggy_ips as optional
* Revert avoid_buggy_ips default back to false
* Change auto_assign to optional, default true
  • Loading branch information
zeeZ authored and guy.gold committed Oct 30, 2023
1 parent e78001a commit e949ef9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
5 changes: 2 additions & 3 deletions docs/metallb.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,6 @@ metallb_config:
primary:
ip_range:
- 192.0.1.0-192.0.1.254
auto_assign: true

pool1:
ip_range:
Expand All @@ -82,8 +81,8 @@ metallb_config:

pool2:
ip_range:
- 192.0.2.2-192.0.2.2
auto_assign: false
- 192.0.3.0/24
avoid_buggy_ips: true # When set to true, .0 and .255 addresses will be avoided.
```
## Layer2 Mode
Expand Down
4 changes: 2 additions & 2 deletions roles/kubernetes-apps/metallb/templates/pools.yaml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ spec:
{% for ip_range in pool.ip_range %}
- "{{ ip_range }}"
{% endfor %}
autoAssign: {{ pool.auto_assign }}
avoidBuggyIPs: true
autoAssign: {{ pool.auto_assign | default(true) }}
avoidBuggyIPs: {{ pool.avoid_buggy_ips | default(false) }}

{% endfor %}

0 comments on commit e949ef9

Please sign in to comment.