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

Trusty: support developer workflow on base image #22960

Merged
merged 1 commit into from
Mar 17, 2016
Merged

Trusty: support developer workflow on base image #22960

merged 1 commit into from
Mar 17, 2016

Conversation

andyzheng0831
Copy link

This change will be helpful in two aspects: (1) Running k8s head in GKE e2e tests; (2) Allow k8s developers to manually run k8s e2e against their local changes. This change also simplifies the logic: no matter test or non-test cluster, binaries are in /usr/bin.

@roberthbailey @dchen1107 @vishh

cc/ @fabioy @wonderfly FYI

I have tested this change in four combinations of configurations:

  • Image: trusty or customized image
  • Cluster type: test cluster created by "go run hack/e2e.go -v --up" or non-test cluster created by "cluster/kube-up.sh"

@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 Mar 14, 2016
# We use the binary from the release tarball if they are not preinstalled, or if this is
# a test cluster.
if ! which kubelet > /dev/null || ! which kubectl > /dev/null; then
cp /tmp/kubernetes/server/bin/kubelet /usr/bin
Copy link
Contributor

Choose a reason for hiding this comment

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

nit: Can we define variables for these paths instead of specifying them verbatim in multiple lines?

Copy link
Author

Choose a reason for hiding this comment

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

Sounds good. I will correct it

@k8s-bot
Copy link

k8s-bot commented Mar 15, 2016

GCE e2e build/test passed for commit 563908cb1ab3288c983eb06e7e09ef872e811be8.

cp /tmp/kubernetes/server/bin/kubelet /home/kubernetes/bin
cp /tmp/kubernetes/server/bin/kubectl /home/kubernetes/bin
mount --bind /home/kubernetes/bin/kubelet /usr/bin/kubelet
mount --bind -o remount,ro,^noexec /usr/bin/kubelet /usr/bin/kubelet
Copy link
Contributor

Choose a reason for hiding this comment

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

Why is ^ needed? Is noexec necessary?

Copy link
Author

Choose a reason for hiding this comment

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

This elif block will only be hit when using our customized images, which preinstalls kubelet and kubectl in /usr/bin but has a read-only /usr/bin. When creating /home/kubernetes/bin, it is non-executable. When bind mounting the binary to overwrite the preinstalled ones, we have to use ^noexec, otherwise, it does not work

@vishh
Copy link
Contributor

vishh commented Mar 15, 2016

Awesome @andyzheng0831!

@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 Mar 15, 2016

GCE e2e build/test passed for commit c3a1ad338b496c0d783eb70901c72ce9566cb184.

@andyzheng0831
Copy link
Author

Manual e2e test result:
go run ./hack/e2e.go -v --test '--test_args=--ginkgo.skip=[Skipped]|[Feature:.+]|[Serial]|[Disruptive]|[Flaky]|[Slow]'

Summarizing 1 Failure:

[Fail] Addon update [BeforeEach] should propagate add-on file changes
/go/src/k8s.io/kubernetes/_output/dockerized/go/src/k8s.io/kubernetes/test/e2e/addon_update.go:358

Ran 159 of 266 Specs in 4274.885 seconds
FAIL! -- 158 Passed | 1 Failed | 0 Pending | 107 Skipped --- FAIL: TestE2E (4275.35s)

The failed one is expected, as the testing code only works for Debian.

@k8s-bot
Copy link

k8s-bot commented Mar 16, 2016

GCE e2e build/test failed for commit eee53df7921b350d9f6851d5fca686b63888736a.

Please reference the list of currently known flakes when examining this failure. If you request a re-test, you must reference the issue describing the flake.

@k8s-bot
Copy link

k8s-bot commented Mar 16, 2016

GCE e2e build/test passed for commit e276c8e.

@andyzheng0831
Copy link
Author

@zmerlynn would you please review this change? It is a blocker for our following works. Thanks!

@zmerlynn zmerlynn added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Mar 16, 2016
@k8s-github-robot
Copy link

@k8s-bot test this [submit-queue is verifying that this PR is safe to merge]

@k8s-bot
Copy link

k8s-bot commented Mar 17, 2016

GCE e2e build/test passed for commit e276c8e.

@k8s-github-robot
Copy link

@k8s-bot test this [submit-queue is verifying that this PR is safe to merge]

@k8s-bot
Copy link

k8s-bot commented Mar 17, 2016

GCE e2e build/test passed for commit e276c8e.

@k8s-github-robot
Copy link

Automatic merge from submit-queue

k8s-github-robot pushed a commit that referenced this pull request Mar 17, 2016
@k8s-github-robot k8s-github-robot merged commit 5cc2bb3 into kubernetes:master Mar 17, 2016
@roberthbailey roberthbailey added this to the v1.2 milestone Mar 18, 2016
@bgrant0607 bgrant0607 added the cherry-pick-approved Indicates a cherry-pick PR into a release branch has been approved by the release branch manager. label Mar 23, 2016
eparis pushed a commit to eparis/kubernetes that referenced this pull request Mar 24, 2016
Auto commit by PR queue bot
(cherry picked from commit 5cc2bb3)
@bgrant0607 bgrant0607 added release-note Denotes a PR that will be considered when it comes time to generate release notes. and removed release-note Denotes a PR that will be considered when it comes time to generate release notes. labels Mar 24, 2016
@k8s-cherrypick-bot
Copy link

Commit 182f781 found in the "release-1.2" branch appears to be this PR. Removing the "cherrypick-candidate" label. If this s an error find help to get your PR picked.

AlainRoy pushed a commit to vmware-archive/kubernetes-archived that referenced this pull request Mar 29, 2016
Auto commit by PR queue bot
(cherry picked from commit 5cc2bb3)
@andyzheng0831 andyzheng0831 deleted the trusty branch April 4, 2016 19:06
alena1108 pushed a commit to rancher/kubernetes that referenced this pull request May 20, 2016
Auto commit by PR queue bot
(cherry picked from commit 5cc2bb3)
shyamjvs pushed a commit to shyamjvs/kubernetes that referenced this pull request Dec 1, 2016
Auto commit by PR queue bot
(cherry picked from commit 5cc2bb3)
shouhong pushed a commit to shouhong/kubernetes that referenced this pull request Feb 14, 2017
Auto commit by PR queue bot
(cherry picked from commit 5cc2bb3)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cherry-pick-approved Indicates a cherry-pick PR into a release branch has been approved by the release branch manager. 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/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

10 participants