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

VRF plugin is not populating routes #866

Closed
korroot opened this issue Mar 24, 2023 · 0 comments · Fixed by #874
Closed

VRF plugin is not populating routes #866

korroot opened this issue Mar 24, 2023 · 0 comments · Fixed by #874

Comments

@korroot
Copy link
Contributor

korroot commented Mar 24, 2023

Hi,
I wanted to use VRF plugin chained with Static IPAM, an example configuration of NAD:

apiVersion: k8s.cni.cncf.io/v1
kind: NetworkAttachmentDefinition
metadata:
  name: default-access
  namespace: default
spec:
  config: |-
    {
      "cniVersion": "0.3.1",
      "plugins": [
        {
          "ipam": {
            "addresses": [
              {
                "address": "192.168.2.10/24"
              }
            ],
            "routes": [
              {
                "dst": "192.168.0.0/24",
                "gw": "192.168.2.1"
              }
            ],
            "type": "static"
          },
          "name": "access"
        },
        {
          "type": "vrf",
          "vrfname": "vrf-access"
        }
      ]
    }

The expected result (from inside container):

/ # ip r show table 1
192.168.0.0/24 via 192.168.2.1 dev access
192.168.2.0/24 dev access scope link  src 192.168.2.10
local 192.168.2.10 dev access scope host  src 192.168.2.10
broadcast 192.168.2.255 dev access scope link  src 192.168.2.10

Actual result:

/ # ip r show table 1
192.168.2.0/24 dev access scope link  src 192.168.2.10
local 192.168.2.10 dev access scope host  src 192.168.2.10
broadcast 192.168.2.255 dev access scope link  src 192.168.2.10

So missing route added by static IPAM...

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 a pull request may close this issue.

1 participant