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

Cluster API with IPAM & InCluster compatibility #53

Closed
ErikLundJensen opened this issue Jan 2, 2023 · 4 comments
Closed

Cluster API with IPAM & InCluster compatibility #53

ErikLundJensen opened this issue Jan 2, 2023 · 4 comments

Comments

@ErikLundJensen
Copy link

It looks like we are trying to solve the same issues related to IP address management at vSphere using Kubernetes Cluster API.

Is this component working with CAPV v1.5.1 and Cluster API 1.3.1 ?

Given the following template with reference to the cluster IP pool using the new feature "addressesFromPools" in CAPV 1.5.0:


apiVersion: infrastructure.cluster.x-k8s.io/v1beta1
kind: VSphereMachineTemplate
metadata:
  name: vmware-test-controlplane
spec:
  template:
    spec:
      cloneMode: linkedClone
      datacenter: dc1
      datastore: datastore5
      diskGiB: 10
      folder: vmware-test
      memoryMiB: 8192
      network:
        devices:
        - dhcp4: false
          dhcp6: false
          gateway4: 192.168.0.1
          addressesFromPools:
          - apiGroup: ipam.cluster.x-k8s.io
            kind: InClusterIPPool
            name: vmware-test-controlplane
          networkName: VM Network
     ...

and the IPAM:

apiVersion: ipam.cluster.x-k8s.io/v1alpha1
kind: InClusterIPPool
metadata:
  name: vmware-test-controlplane
spec:
  start: 192.168.5.10
  end: 192.168.5.14
  prefix: 24
  gateway: 192.168.0.1

From those configuration we do get IPAddresses and IPAddressclaims as expected, however, the IP are not propagated to the virtual machine.
I wonder if cluster-api-ipam-provider-in-cluster was written before the release of CAPV 1.5.0 and thereby not being compatible with the new CAPV feature.

Note, we are using Talos for bootstrap & control plane, however, that should not affect IPAM.

@schrej
Copy link
Member

schrej commented Jan 3, 2023

This is the first provider implementation for the CAPI IPAM contract, and is supposed to serve as a reference implementation that providers can use for testing. The intention is that it works with any provider that implements the IPAM contract.

VMware used this project to test their implementation, and they are working on e2e tests using it: kubernetes-sigs/cluster-api-provider-vsphere#1667

Since it's a relatively new addition to CAPV, there might still be bugs. Have you opened an issue for CAPV already?

cc @tylerschultz

@ErikLundJensen
Copy link
Author

Thanks for the info and great work. I can see that the guest-info metadata actually contains the correct network configuration. I will look at why Talos is not picking up that metadata.

@tylerschultz
Copy link
Contributor

@ErikLundJensen Please do let us know if you get to the bottom of what's going sideways, we'd be curious to know.

@ErikLundJensen
Copy link
Author

The issue is Talos' integration with VMware where the Talos v1.3 has no implementation of reading metadata from guestinfo.

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

No branches or pull requests

3 participants