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

Update CNI plugin to newest version; support ConfigLists #42202

Merged
merged 2 commits into from
Apr 21, 2017

Conversation

squeed
Copy link
Contributor

@squeed squeed commented Feb 28, 2017

What this PR does / why we need it: Updates the CNI network plugin to use the newest version of CNI. This brings with it plugin chaining and support for multiple versions.

Special notes for your reviewer: This libcni change is backwards-compatible - older plugins will work without any changes needed.

Release note:

This adds support for CNI ConfigLists, which permit plugin chaining.

@k8s-ci-robot
Copy link
Contributor

Hi @squeed. Thanks for your PR.

I'm waiting for a kubernetes member to verify that this patch is reasonable to test. If it is, they should reply with @k8s-bot ok to test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Feb 28, 2017
@squeed
Copy link
Contributor Author

squeed commented Feb 28, 2017

@freehan

@k8s-github-robot k8s-github-robot added size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. release-note Denotes a PR that will be considered when it comes time to generate release notes. labels Feb 28, 2017
@freehan freehan assigned freehan and unassigned jbeda Feb 28, 2017
@feiskyer
Copy link
Member

@squeed Cool. When will CNI v0.5.0 be released?

@squeed
Copy link
Contributor Author

squeed commented Feb 28, 2017

We were hoping to cut a -rc release today or tomorrow, and a full release a few days after that.

@k8s-reviewable
Copy link

This change is Reviewable

Copy link
Contributor

@freehan freehan left a comment

Choose a reason for hiding this comment

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

Look good overall. Waiting for CNI release. Will take a final look later

if err != nil {
return err
}
// Coerce the CNI result version
res, err := cnitypes020.GetResult(resT)
Copy link
Contributor

Choose a reason for hiding this comment

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

I assume this is backward compatible, right?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Correct - this converts the result in to the 0.2.0 format, which is what kubenet already expects.

"host_ip": p.HostIP,
})
}
// TODO(cdc) CNI #373 needs to be merged first
Copy link
Contributor

Choose a reason for hiding this comment

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

I assume there will be follow up on this

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yup :-). It was merged a few hours ago.

glog.Warningf("Error converting CNI config file %s to list: %v", confFile, err)
continue
}

Copy link
Contributor

Choose a reason for hiding this comment

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

nit: remove this empty line

continue
}
} else {

Copy link
Contributor

Choose a reason for hiding this comment

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

nit: remove this empty line

@freehan
Copy link
Contributor

freehan commented Mar 2, 2017

@k8s-bot ok to test

@freehan
Copy link
Contributor

freehan commented Mar 2, 2017

Need to run hack/update-bazel.sh

@squeed
Copy link
Contributor Author

squeed commented Mar 2, 2017

0.5.0-rc1 was just released. Going to update the PR with that.

@squeed squeed force-pushed the update-cni branch 5 times, most recently from c471c5e to 23ed942 Compare March 3, 2017 13:49
@k8s-github-robot k8s-github-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Mar 4, 2017
@k8s-github-robot k8s-github-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Mar 6, 2017
@squeed squeed force-pushed the update-cni branch 2 times, most recently from c373e33 to 3003bc6 Compare March 6, 2017 15:03
@squeed
Copy link
Contributor Author

squeed commented Mar 6, 2017

Ok, all checks are passing. All that's left now is to wait for 0.5.0 to be released - should be sometime this week.

@squeed
Copy link
Contributor Author

squeed commented Mar 9, 2017

CNI v0.5.0 has been updated. This can be considered for merge.

@k8s-ci-robot
Copy link
Contributor

k8s-ci-robot commented Mar 9, 2017

@squeed: The following test(s) failed:

Test name Commit Details Rerun command
Jenkins GCI GKE smoke e2e 23ed9422f31a649fe9b8d3bbbfa69c5410b21d8d link @k8s-bot gci gke e2e test this
Jenkins GKE smoke e2e 23ed9422f31a649fe9b8d3bbbfa69c5410b21d8d link @k8s-bot cvm gke e2e test this

Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@squeed
Copy link
Contributor Author

squeed commented Apr 12, 2017

@freehan updated & rebased, thanks

@freehan
Copy link
Contributor

freehan commented Apr 12, 2017

/lgtm
/approve

Thanks!

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Apr 12, 2017
@freehan
Copy link
Contributor

freehan commented Apr 12, 2017

Could you approve this? It needs owners at root. @thockin

Casey Callendrello added 2 commits April 18, 2017 14:04
…rameters

** reason for this change **
CNI has recently introduced a new configuration list feature. This
allows for plugin chaining. It also supports varied plugin versions.
@k8s-github-robot k8s-github-robot removed the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Apr 18, 2017
@squeed
Copy link
Contributor Author

squeed commented Apr 18, 2017

Had to rebase. @freehan @thockin is there any chance of getting this reviewed and merged quickly?

// Search for vendor-specific plugins as well as default plugins in the CNI codebase.
vendorDir := vendorCNIDir(vendorCNIDirPrefix, conf.Network.Type)
vendorDir := vendorCNIDir(vendorCNIDirPrefix, confType)
Copy link
Member

Choose a reason for hiding this comment

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

Should we search vendor CNI dir for all plugin types, e.g. networks may have different type in confList.Plugins

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Maybe, but that is changing behavior. The aim of this PR is only to enable config lists.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

There is a lot of cleaning up that can be done with how k8s uses CNI but this PR is not the place for it, IMHO. Just trying to get the version bump out now.

@freehan
Copy link
Contributor

freehan commented Apr 20, 2017

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Apr 20, 2017
@freehan
Copy link
Contributor

freehan commented Apr 20, 2017

@thockin for approve

@freehan
Copy link
Contributor

freehan commented Apr 20, 2017

fyi @dnardo

@squeed
Copy link
Contributor Author

squeed commented Apr 21, 2017

Fingers crossed that this wins the rebase race.

@dcbw
Copy link
Member

dcbw commented Apr 21, 2017

/lgtm

@thockin
Copy link
Member

thockin commented Apr 21, 2017

/approve

@k8s-github-robot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: freehan, squeed, thockin

Needs approval from an approver in each of these OWNERS Files:

You can indicate your approval by writing /approve in a comment
You can cancel your approval by writing /approve cancel in a comment

@k8s-github-robot k8s-github-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Apr 21, 2017
@k8s-github-robot
Copy link

Automatic merge from submit-queue (batch tested with PRs 42202, 40784, 44642, 44623, 44761)

@k8s-github-robot k8s-github-robot merged commit 0acb721 into kubernetes:master Apr 21, 2017
@redbaron
Copy link
Contributor

are there any plans to have it in 1.6 branch?

@bboreham
Copy link
Contributor

Can I request that the top description of this PR be extended to mention the portmap capability that it adds?

Really I would like it in the 1.7.0 release notes too, but I'm not sure if those can be changed retrospectively.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.