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

Bump cni plugins to v1.2.0-k3s1 #7425

Merged
merged 1 commit into from
May 4, 2023
Merged

Conversation

brandond
Copy link
Member

@brandond brandond commented May 4, 2023

Proposed Changes

Bump cni plugins to v1.2.0-k3s1

Also add bandwidth and firewall plugins. The bandwidth plugin is automatically registered with the appropriate capability, but the firewall plugin must be configured by the user if they want to use it.

Bandwidth ref: https://kubernetes.io/docs/reference/labels-annotations-taints/#kubernetes-io-ingress-bandwidth
Firewall ref: https://www.cni.dev/plugins/current/meta/firewall/

Types of Changes

version bump, enhancement

Verification

  • Check cni binary versions using cli
  • Check that bandwidth annotations on pods work properly

Testing

Linked Issues

User-Facing Change

The bundled CNI plugins have been upgraded to v1.2.0-k3s1. The bandwidth and firewall plugins are now included in the bundle.

Further Comments

Also add bandwidth and firewall plugins. The bandwidth plugin is
automatically registered with the appropriate capability, but the
firewall plugin must be configured by the user if they want to use it.

Ref: https://www.cni.dev/plugins/current/meta/firewall/

Signed-off-by: Brad Davidson <[email protected]>
@brandond brandond requested a review from a team as a code owner May 4, 2023 17:57
Copy link
Contributor

@johnatasr johnatasr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm ;)

@codecov
Copy link

codecov bot commented May 4, 2023

Codecov Report

Patch and project coverage have no change.

Comparison is base (e1d4cff) 19.57% compared to head (42c3bf8) 19.57%.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #7425   +/-   ##
=======================================
  Coverage   19.57%   19.57%           
=======================================
  Files          81       81           
  Lines        5461     5461           
=======================================
  Hits         1069     1069           
  Misses       4170     4170           
  Partials      222      222           
Flag Coverage Δ
unittests 19.57% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
pkg/agent/flannel/setup.go 0.00% <ø> (ø)

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@brandond
Copy link
Member Author

brandond commented May 4, 2023

root@k3s-server-1:/# /var/lib/rancher/k3s/data/current/bin/cni
CNI plugins plugin v1.2.0-k3s1
CNI protocol versions supported: 0.1.0, 0.2.0, 0.3.0, 0.3.1, 0.4.0, 1.0.0

root@k3s-server-1:/# /var/lib/rancher/k3s/data/current/bin/flannel
CNI flannel plugin v0.21.4 (linux/amd64) commit HEAD built on 2023-05-04T19:19:31Z

When creating a pod with bandwidth annotations, you should see matching tc configuration in place:

root@k3s-server-1:/# kubectl get pod -o yaml | grep -A2 annotations
    annotations:
      kubernetes.io/egress-bandwidth: 1M
      kubernetes.io/ingress-bandwidth: 1M

root@k3s-server-1:/# tc qdisc | grep tbf
qdisc tbf 1: dev veth5b8bbe6a root refcnt 9 rate 1Mbit burst 21474835b lat 4.12e+03s
qdisc tbf 1: dev bwpafb7cee7e704 root refcnt 2 rate 1Mbit burst 21474835b lat 4.12e+03s

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 this pull request may close these issues.

4 participants