Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Exlude invalid IPs when range crosses the third octet #29

Merged
merged 2 commits into from
Feb 27, 2022

Conversation

xprt64
Copy link
Contributor

@xprt64 xprt64 commented Feb 26, 2022

When there is a range that crosses the third octet, there are 2 IPs that shouldn't be used: the ones that end in 255 or 0.
There is also a test that catch this situation and that fails; this PR pass it: "single range, across third octet" in ipam_test.go.

AshleyDumaine and others added 2 commits February 25, 2022 00:17
I was hitting this when running `make build` on main:
```
...
# github.com/kube-vip/kube-vip-cloud-provider/pkg/provider
pkg/provider/provider.go:83:22: not enough arguments in call to newLoadBalancer
	have (*kubernetes.Clientset, string, string)
	want (*kubernetes.Clientset, string, string, string)
make: *** [Makefile:28: kube-vip-cloud-provider] Error 2
```
`serviceCidr` isn't used in this function so I removed it so `make build` can successfully complete again.

Signed-off-by: AshleyDumaine <ashley.dumaine@gmail.com>
Signed-off-by: Constantin Galbenu <xprt64@gmail.com>
@thebsdbox thebsdbox merged commit 2e3dac3 into kube-vip:main Feb 27, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants