spidernet-io / spiderpool

Underlay and RDMA network solution of the Kubernetes, for bare metal, VM and any public cloud
https://spidernet-io.github.io/spiderpool/
Apache License 2.0
503 stars 72 forks source link

SpiderMultusConfig Support for capabilities and IPAM Static Routes #3641

Open infinitydon opened 1 week ago

infinitydon commented 1 week ago

What help do you need?

I was going through the reference of SpiderMultusConfig https://spidernet-io.github.io/spiderpool/v0.9/reference/crd-spidermultusconfig/ but I could not find support for when there is need to create static route and IP capabilities.

Example of multus NAD that requires static routes:


apiVersion: k8s.cni.cncf.io/v1
kind: NetworkAttachmentDefinition
metadata:
  name: core-n2
  namespace: example
spec:
  config: |
    {
      "cniVersion": "0.3.1",
      "name": "core-n2",
      "plugins": [
        {
          "type": "ipvlan",
          "capabilities": {
            "ips": true
          },
          "master": "eth1",
          "mode": "l2",
          "ipam": {
            "type": "static",
            "routes": [{ "dst": "10.4.2.0/24", "gw": "10.3.0.1" }]
          }
        }
      ]
    }

If this is supported, kindly refer me to the docs.

Thanks
ty-dc commented 1 week ago

Refer to the following document, hope it can help you.

https://github.com/spidernet-io/spiderpool/blob/main/docs/usage/route.md