-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
experimentally allow custom networks #1538
experimentally allow custom networks #1538
Conversation
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: BenTheElder The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
bazel build flake |
missed changing kind/pkg/cluster/internal/providers/docker/provision.go Lines 147 to 148 in 1f9ac83
|
1a5d820
to
2da88e6
Compare
done |
/retest |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
/hold
2da88e6
to
8cef04c
Compare
New changes are detected. LGTM label has been removed. |
/hold cancel |
re-applying, made trivial change per comments. this is the last PR before the v0.8.0 tag |
Instead of using two completely separate subnets (`172.x.0.0/16` is used by Kind and I had arbitrarily chosen `192.168.2.0/24` for MetalLB), use a custom Docker network for `kind` instead. I needed to create the Docker network myself rather than letting `kind` do it because otherwise the subnet IP range will not necessarily be fixed (see https://github.com/kubernetes-sigs/kind/blob/add83858a0addea5899a88003a598399a8a36747/pkg/cluster/internal/providers/docker/network.go#L94). To allow `kind` to use the custom Docker network, I am relying on `KIND_EXPERIMENTAL_DOCKER_NETWORK`. See kubernetes-sigs/kind#273 and kubernetes-sigs/kind#1538. For documentation on `docker network create`, see https://docs.docker.com/engine/reference/commandline/network_create/. | Subnet | Usage | |------------------|----------------------| | `172.100.0.0/24` | Kubernetes nodes | | `172.100.1.0/24` | MetalLB address pool |
can we make this an experimental option in the API, instead of an environment variable? It's not very easy to use environment variable when using the library to create the kind cluster. |
experimental options are only exposed via environment variable and are highly discouraged. making it easy would defeat the purpose. what's your use-case in not using the standard network? we'd actually prefer to use the default "bridge" network but we can't due to the lack of embedded DNS. |
fixes #273