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

add command to get podman subnet #3263

Merged
merged 1 commit into from
Jun 5, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions site/content/docs/user/loadbalancer.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,11 @@ To complete layer2 configuration, we need to provide MetalLB a range of IP addre
docker network inspect -f '{{.IPAM.Config}}' kind
{{< /codeFromInline >}}

If you are using podman 4.0 or higher in rootful mode with the netavark network backend, use the following command instead:
{{< codeFromInline lang="bash" >}}
podman network inspect -f '{{range .Subnets}}{{if eq (len .Subnet.IP) 4}}{{.Subnet}}{{end}}{{end}}' kind
{{< /codeFromInline >}}

The output will contain a cidr such as 172.19.0.0/16. We want our loadbalancer IP range to come from this subclass. We can configure MetalLB, for instance, to use 172.19.255.200 to 172.19.255.250 by creating the IPAddressPool and the related L2Advertisement.

```yaml
Expand Down