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

Ubuntu CNI support #21072

Merged
merged 2 commits into from
Feb 26, 2016
Merged

Conversation

MikeSpreitzer
Copy link
Member

Generalize cluster/ubuntu scripting to support either Flannel or CNI networking.
#20292

@k8s-bot
Copy link

k8s-bot commented Feb 11, 2016

Can one of the admins verify that this patch is reasonable to test? (reply "ok to test", or if you trust the user, reply "add to whitelist")

If this message is too spammy, please complain to ixdy.

1 similar comment
@k8s-bot
Copy link

k8s-bot commented Feb 11, 2016

Can one of the admins verify that this patch is reasonable to test? (reply "ok to test", or if you trust the user, reply "add to whitelist")

If this message is too spammy, please complain to ixdy.

@k8s-github-robot
Copy link

Labelling this PR as size/M

@k8s-github-robot k8s-github-robot added the size/M Denotes a PR that changes 30-99 lines, ignoring generated files. label Feb 11, 2016
@MikeSpreitzer MikeSpreitzer force-pushed the issue/20292 branch 3 times, most recently from d981557 to e15058f Compare February 12, 2016 05:48
@eparis
Copy link
Contributor

eparis commented Feb 12, 2016

ok to test

# list of their pathnames (relative to kubernetes/cluster).

export CNI_PLUGIN_CONF=""
export CNI_PLUGIN_EXES=""
Copy link
Contributor

Choose a reason for hiding this comment

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

I'm expected to manually edit this file before I execute it to set CNI_PLUGIN_* ?

Copy link
Member Author

Choose a reason for hiding this comment

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

You are expected to edit those lines (manually or with automation) if you want to use a CNI plugin instead of Flannel.
Now that you mention it, I see it would be better to use defaulting here, so that those envars could be set outside the script. I will change that.

@k8s-bot
Copy link

k8s-bot commented Feb 12, 2016

GCE e2e test build/test passed for commit e15058fe989fadbb22d96112a6ceb1e4df5d7108.

@k8s-github-robot
Copy link

The author of this PR is not in the whitelist for merge, can one of the admins add the 'ok-to-merge' label?

@k8s-bot
Copy link

k8s-bot commented Feb 12, 2016

GCE e2e test build/test passed for commit 31e27a19800b7794cd9d55907a9ee3bd390dc9b1.

@k8s-bot
Copy link

k8s-bot commented Feb 12, 2016

GCE e2e test build/test passed for commit 825f2d8608754409563f565a85492ba47ffaf161.

@k8s-bot
Copy link

k8s-bot commented Feb 14, 2016

GCE e2e test build/test passed for commit 937e9412796cfdc4ed973828c03484ac7f6659a9.

@k8s-bot
Copy link

k8s-bot commented Feb 14, 2016

GCE e2e test build/test passed for commit f4cac5dde390a339caece06cdc8d4e33aa673f2b.

@MikeSpreitzer
Copy link
Member Author

This is a work in progress, not ready for merge yet.

@k8s-bot
Copy link

k8s-bot commented Feb 14, 2016

GCE e2e test build/test passed for commit fe7efc180ae9085f6ebe817001ab16a2d97388a4.

@k8s-bot
Copy link

k8s-bot commented Feb 15, 2016

GCE e2e test build/test passed for commit 7f83398e4282e39fea24cab939c86992135d74b7.

@k8s-bot
Copy link

k8s-bot commented Feb 16, 2016

GCE e2e build/test failed for commit 9cf34bc3bdc7b425cd2fd71aeca572db8e47d1f9.

@k8s-bot
Copy link

k8s-bot commented Feb 16, 2016

GCE e2e build/test failed for commit 99e5e7c262e028a32dfbb4678841bea3dc52f360.

@bgrant0607 bgrant0607 assigned bprashanth and unassigned eparis Feb 18, 2016
@@ -231,6 +231,11 @@ EOF
}

function create-kubelet-opts() {
Copy link
Contributor

Choose a reason for hiding this comment

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

This is a slight maintainence headache. Can you move this function into hack/lib and re-use it from local-up-cluster? That would kill 2 birds with 1 stone, and people who invoke local-up (>>number of people who invoke ubuntu setup) will be aware when it's broken.

Copy link
Member Author

Choose a reason for hiding this comment

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

My ambition here was only to take the first baby step, which is to add CNI support to the Ubuntu scripting. My plan was to think bigger after that is accomplished. I myself have not been using local-up-cluster and am not familiar with it. Do we really need to take the bigger step right out of the gate?

@bprashanth
Copy link
Contributor

@MikeSpreitzer high order bit is I'd really like to streamline this with local-up-cluster and give that the ability to handle CNI plugins as well, because that's used by a wider population and so less likely to break silently. Optionally, it would be cool if I could just run CNI plugins that were auto installed from a tarball at a url (https://github.com/appc/cni/releases/tag/v0.1.0 perhaps?).

@bprashanth
Copy link
Contributor

@resouer as defacto maintainer of ubuntu install

@MikeSpreitzer
Copy link
Member Author

Regarding local-up-cluster.sh, I see that it does not now share a lot with the cluster/ubuntu scripting, but I think @bprashanth you are saying you would like to change that. While that may be a laudatory goal, it seems to me to be a separate project from adding CNI support. Perhaps you are saying the unification project should come first. I will not object if it happens quickly, but that might have to be done by other hands than mine since I am new to all this. @resouer what do you think?

@MikeSpreitzer
Copy link
Member Author

I have added (1) comments documenting several functions in util.sh and (2) sanity checking of the new CNI configuration envars, as requested.
I think the other two suggestions mentioned above --- tarball URL instead of file pathnames, and unifying with local-up-cluster.sh --- are separable projects that should be left for separate PRs; this one is big enough already.
The tarball suggestion sounds intriguing but I think it is pulling on a bigger ball of yarn, namely establishing a standard archive format for containing a CNI plugin. I think that is a potentially good thing, but deserves some discussion of its own merits in a community broader than that reviewing this PR. And it can be added as a later after this PR is merged, if ultimately desired.
The unification with local-up-cluster.sh is clearly a distinct project. It strikes me as a bit odd to unify local-up-cluster.sh with one of the several providers for clusters.

@k8s-bot
Copy link

k8s-bot commented Feb 22, 2016

GCE e2e test build/test passed for commit 2224629.

@bprashanth
Copy link
Contributor

The unification with local-up-cluster.sh is clearly a distinct project. It strikes me as a bit odd to unify local-up-cluster.sh with one of the several providers for clusters.

We're talking about sharing code in a common library. Any number of providers can use it. Local-up-cluster is just the most common script. Did it not work, or just too much to refactor? it's ok to defer if that's the case

@MikeSpreitzer
Copy link
Member Author

I did not try a refactoring. I'm not sure what makes sense. Are you suggesting to move the create-kube-*-opts functions (with the style of the function names adjusted accordingly) from cluster/ubuntu/util.sh into hack/lib/util.sh? That itself would be easy to do, I see no serious difficutly (just the need to make sure hack/lib/util.sh is available everywhere that cluster/ubuntu/util.sh is sourced). It just seems a little odd to me, to move a piece of cluster/ubuntu into hack/lib.

@k8s-bot
Copy link

k8s-bot commented Feb 23, 2016

GCE e2e test build/test passed for commit 6b8e7e1.

@MikeSpreitzer
Copy link
Member Author

@bprashanth ?
@dalanlan ?
@zmerlynn ?

@bprashanth
Copy link
Contributor

LGTM. Beware that ther's a pretty high chance this will drift out of sync as we start making modifications to CNI integration for 1.3, unless you pay close attention to it. If you found a way to share the CNI parts with local-up-cluster, many more people will pay attention to keeping it in sync, but that can easily come in a follow up pr.

@bprashanth bprashanth added lgtm "Looks good to me", indicates that a PR is ready to be merged. ok-to-merge and removed needs-ok-to-merge labels Feb 26, 2016
@k8s-github-robot
Copy link

@k8s-bot test this

Tests are more than 48 hours old. Re-running tests.

@k8s-bot
Copy link

k8s-bot commented Feb 26, 2016

GCE e2e build/test passed for commit 6b8e7e1.

@k8s-github-robot
Copy link

Automatic merge from submit-queue

k8s-github-robot pushed a commit that referenced this pull request Feb 26, 2016
@k8s-github-robot k8s-github-robot merged commit 085d7cb into kubernetes:master Feb 26, 2016
@MikeSpreitzer
Copy link
Member Author

@bprashanth - thanks for the heads-up and the progress.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lgtm "Looks good to me", indicates that a PR is ready to be merged. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

9 participants