Commit Graph

4101 Commits (3b1407af70ac54c925fe5abb060e83d625d77b88)

Author SHA1 Message Date
Jay Vyas 6166083c78 kill repo-root : test/e2e/serviceloadbalancers.go
bindata and yaml, Gobindata automation
bindata utils for generating, go generate
match server version
gitignore for dirty, ca, rbase, KUBE_ROOT, buildfix
(rebased jul-25,29)
2016-07-29 14:35:19 -04:00
k8s-merge-robot 7abc3de621 Merge pull request #29694 from jsafrane/dynprov2-apionly
Automatic merge from submit-queue

Add API for StorageClasses

This is the API objects only required for dynamic provisioning picked apart from the controller logic.

Entire feature is here: https://github.com/kubernetes/kubernetes/pull/29006
2016-07-28 22:00:05 -07:00
k8s-merge-robot eca270bb41 Merge pull request #29423 from kevin-wangzefeng/fix-taints-tolerations-e2e
Automatic merge from submit-queue

Remove redundant pod deletion in scheduler predicates tests and fix taints-tolerations e2e

~~In scheduler predicates test, some tests won't clean pods they created when exit with failure, which may lead to pod leak. This PR is to fix it.~~

Remove redundant pod deletion in scheduler predicates tests, since framework.AfterEach() already did the cleanup work after every test.

Also fix the test "validates that taints-tolerations is respected if not matching", refer to the change on taint-toleration test in #29003, and https://github.com/kubernetes/kubernetes/pull/24134#discussion_r63794924.
2016-07-28 21:26:51 -07:00
childsb f5bd7d471e API Changes for StorageClass 2016-07-28 19:01:01 -04:00
k8s-merge-robot 2817674715 Merge pull request #29557 from deads2k/make-prefx-configurable
Automatic merge from submit-queue

make the resource prefix in etcd configurable for cohabitation

This looks big, its not as bad as it seems.

When you have different resources cohabiting, the resource name used for the etcd directory needs to be configurable.  HPA in two different groups worked fine before.  Now we're looking at something like RC<->RS.  They normally store into two different etcd directories.  This code allows them to be configured to store into the same location.

To maintain consistency across all resources, I allowed the `StorageFactory` to indicate which `ResourcePrefix` should be used inside `RESTOptions` which already contains storage information.

@lavalamp affects cohabitation.
@smarterclayton @mfojtik prereq for our rc<->rs and d<->dc story.
2016-07-28 03:01:28 -07:00
k8s-merge-robot 1ae9b73cd3 Merge pull request #29673 from pmorie/mount-collision
Automatic merge from submit-queue

Fix mount collision timeout issue

Short- or medium-term workaround for #29555.  The root issue being fixed here is that the recent attach/detach work in the kubelet uses a unique volume name as a key that tracks the work that has to be done for each volume in a pod to attach/mount/umount/detach.  However, the non-attachable volume plugins do not report unique names for themselves, which causes collisions when a single secret or configmap is mounted multiple times in a pod.

This is still a WIP -- I need to add a couple E2E tests that ensure that tests break in the future if there is a regression -- but posting for early review.

cc @kubernetes/sig-storage 

Ultimately, I would like to refine this a bit further.  A couple things I would like to change:

1.  `GetUniqueVolumeName` should be a property ONLY of attachable volumes
2.  I would like to see the kubelet apparatus for attach/mount/umount/detach handle non-attachable volumes specifically to avoid things like the `WaitForControllerAttach` call that has to be done for those volume types now
2016-07-27 21:06:47 -07:00
Paul Morie f15684e0c4 Add e2e coverage for mount collisions 2016-07-27 17:54:01 -04:00
Erick Fejta 12d923ed15 Revert "Fix killing child sudo process in e2e_node tests" 2016-07-27 21:53:05 +05:30
deads2k aa3db4d995 make the resource prefix in etcd configurable for cohabitation 2016-07-27 07:51:40 -04:00
k8s-merge-robot 03fe6b962c Merge pull request #29380 from bboreham/kill-setpgid
Automatic merge from submit-queue

Fix killing child sudo process in e2e_node tests

Fixes #29211.

The context is we are trying to kill a process started as `sudo kube-apiserver`, but `sudo` ignores signals from the same process group. Applying `Setpgid` means the `sudo kill` process won't be in the same process group, so will not fall foul of this nifty feature.

I also took the liberty of removing some code setting `Pdeathsig` because it claims to be doing something  in the same area, but actually it doesn't do that at all.  The setting is applied to the forked process, i.e. `sudo`, and it means the `sudo` will get killed if we (`e2e_node.test`) die.  This (a) isn't what the comment says and (b) doesn't help because sending SIGKILL to the sudo process leaves sudo's child alive.

I didn't use the "hack for linux-only" approach because I think `Setpgid` is available on all platforms that `e2e_node` builds on.
2016-07-27 03:18:15 -07:00
Bryan Boreham dbc59aad7c For e2e_node tests tell etcd to listen on ports 2379 and 4001
This is the default for etcd2, but etcd3 only listens on 2379.
Specifying the ports keeps things consistent no matter which
version the user has installed.
2016-07-27 11:16:40 +01:00
k8s-merge-robot 540e992e08 Merge pull request #28850 from MHBauer/faster-test
Automatic merge from submit-queue

Faster test

<!--
Checklist for submitting a Pull Request

Please remove this comment block before submitting.

1. Please read our [contributor guidelines](https://github.com/kubernetes/kubernetes/blob/master/CONTRIBUTING.md).
2. See our [developer guide](https://github.com/kubernetes/kubernetes/blob/master/docs/devel/development.md).
3. If you want this PR to automatically close an issue when it is merged,
   add `fixes #<issue number>` or `fixes #<issue number>, fixes #<issue number>`
   to close multiple issues (see: https://github.com/blog/1506-closing-issues-via-pull-requests).
4. Follow the instructions for [labeling and writing a release note for this PR](https://github.com/kubernetes/kubernetes/blob/master/docs/devel/pull-requests.md#release-notes) in the block below.
-->
In attempting to troubleshoot flakes with this test case I actually wanted to understand how it worked.
There's some poor comments that need work.
I added some additional output which may or may not help in debugging the flakes.
I doubt this fixes the flake.

My major concern is the 'refactor' I did of the test case to batch up runs by sub-test-case. As it stood there was a 200ms pause between each sub, so they should not have interfered with each other. Now they are just started as fast as possible, but only 20 run at a time before moving on to the next 20. I am not sure if I am violating the ethos of the original test case.

Runs on my computer are down from 2m40s -> 40s.
Getting rid of the arbitrary client limiting brings it down to ~12 seconds. 11 to fetch the image and <1 to actually run the tests against the proxies. I can add a zero to the number of loops if you want to hit it harder. It would result in 10x as much text output though.


[![Analytics](https://kubernetes-site.appspot.com/UA-36037335-10/GitHub/.github/PULL_REQUEST_TEMPLATE.md?pixel)]()
2016-07-26 23:38:09 -07:00
Kevin 57d22a156c Remove redundant pod deletion in scheduler predicates tests and fix taints-tolerations e2e 2016-07-27 14:01:13 +08:00
k8s-merge-robot d82e404a00 Merge pull request #28351 from sttts/sttts-kubectl-create-quota
Automatic merge from submit-queue

Add support for kubectl create quota command

Follow-up of https://github.com/kubernetes/kubernetes/pull/19625

```
Create a resourcequota with the specified name, hard limits and optional scopes

Usage:
  kubectl create quota NAME [--hard=key1=value1,key2=value2] [--scopes=Scope1,Scope2] [--dry-run=bool] [flags]

Aliases:
  quota, q


Examples:
  // Create a new resourcequota named my-quota
  $ kubectl create quota my-quota --hard=cpu=1,memory=1G,pods=2,services=3,replicationcontrollers=2,resourcequotas=1,secrets=5,persistentvolumeclaims=10

  // Create a new resourcequota named best-effort
  $ kubectl create quota best-effort --hard=pods=100 --scopes=BestEffort
```
2016-07-26 21:20:04 -07:00
k8s-merge-robot b8e78b3310 Merge pull request #29558 from janetkuo/deployment-rollover-minreadyseconds-e2e
Automatic merge from submit-queue

Use nonexistent image instead of minReadySeconds in deployment rollover e2e test

Fixes #26834 

@kubernetes/deployment
2016-07-26 15:34:14 -07:00
k8s-merge-robot 9014ceb9d8 Merge pull request #29286 from soltysh/wait_pod2
Automatic merge from submit-queue

Rework pod waiting mechanism in e2e tests to accept pod and watch based

This PR re-applies #28212 which was reverted in #29223. The only difference is that the initial PR contained also `PodStartTimeout` shortening (see [here](4b0c0bd924)) which might caused the problems. Let's give it a 2nd try. I've tested all the flakes and they were passing on my machine.

@smarterclayton @apelisse ptal
2016-07-26 15:01:13 -07:00
PingWang 1606ce57ea combine the const definition
Signed-off-by: PingWang <wang.ping5@zte.com.cn>
2016-07-26 20:28:12 +08:00
Dr. Stefan Schimanski 199f991f6a Add --scopes to kubectl-create-quota and add tests 2016-07-26 14:12:35 +02:00
Dr. Stefan Schimanski 36afe2a43a Fix nsFlag scope in kubectl-run e2e test 2016-07-26 11:32:08 +02:00
k8s-merge-robot 396254c11a Merge pull request #29486 from vishh/gci-node-e2e
Automatic merge from submit-queue

Make it possible to run node e2e with GCI.
2016-07-25 16:53:27 -07:00
Morgan Bauer b50e986fad
code comments
- what the test is doing
 - how the test is set up
 - subsections of the test setup

additional output

 - print time spent getting ready to run proxy attempts
 - number of test cases
 - multiple attempts of each test case
 - how many total proxying attempts will be made
 - fast path output now has numerical identity of attempt like error output
 - error output has time taken and http status like fast path output

batching runs

 - run groups of test cases vs starting all 34*20=680 proxy attempts at
   the same time.
 - don't wait between starting proxy attempts anymore.

proxy e2e changes

 - disable the client side rate limiter
 - use `By` construct of ginkgo for inline `STEP` logging
 - move the waitGroup add outside of the loop
2016-07-25 14:40:57 -07:00
Vishnu kannan d31608fcc8 Make it possible to run node e2e with GCI via make
Signed-off-by: Vishnu kannan <vishnuk@google.com>
2016-07-25 12:21:37 -07:00
Janet Kuo b45afc04a2 Use nonexistent image instead of minReadySeconds in deployment rollover e2e test 2016-07-25 11:45:46 -07:00
k8s-merge-robot c186afd46e Merge pull request #29122 from ronnielai/image-gc-1-1
Automatic merge from submit-queue

Syncing imaging pulling backoff logic

- Syncing the backoff logic in the parallel image puller and the sequential image puller to prepare for merging the two pullers into one.
- Moving image error definitions under kubelet/images
2016-07-25 11:43:22 -07:00
k8s-merge-robot ca06157421 Merge pull request #28162 from kargakis/annotation-fixes-for-scaling
Automatic merge from submit-queue

controller: update all rs annotations on a scaled rollout

Closes https://github.com/kubernetes/kubernetes/issues/28145

@kubernetes/deployment
2016-07-25 10:58:18 -07:00
k8s-merge-robot 4fdde68f78 Merge pull request #28916 from luxas/flake_celery
Automatic merge from submit-queue

Add liveness probe to the flower rc in order to fix a flake

Fixes #27857 
@fejta @ixdy @timstclair @mwielgus
2016-07-23 15:19:52 -07:00
Lucas Käldström 5db3f6d25e Add liveness probe to the flower rc in order to fix a flake 2016-07-24 00:08:52 +03:00
k8s-merge-robot 9e5d562805 Merge pull request #29435 from Random-Liu/setup-node-for-docker-validation
Automatic merge from submit-queue

Change SETUP_NODE to True for node e2e docker validation test.

The continuous node e2e docker validation test is failing because:
```
W0722 00:48:52.163940    1265 image_list.go:85] Could not pre-pull image gcr.io/google_containers/netexec:1.4 exit status 1 output:  Cannot connect to the Docker daemon. Is the docker daemon running on this host?
```
This is because jenkins is not added to docker user group.
For other images tested in node e2e, jenkins is added to docker user group when the images are initially created https://github.com/kubernetes/kubernetes/blob/master/test/e2e_node/environment/setup_host.sh#L102.

However, in node e2e docker validation test, we are using GCI image which doesn't do that.
So we should use the `SETUP_NODE` option to add user to docker group before test running b6c87904f6/test/e2e_node/e2e_remote.go (L150-L159).

This is only one line change, could you help me review the PR? @wonderfly 
Thanks a lot! :)
2016-07-22 17:13:09 -07:00
Hongchao Deng 74e6626967 Update etcd deprecated flag
- "-addr" => "--advertise-client-urls"
- "-bind-addr" => "--listen-client-urls"
2016-07-22 11:01:11 -07:00
k8s-merge-robot 60e59c9461 Merge pull request #29184 from wojtek-t/rs_controller_ref
Automatic merge from submit-queue

ReplicaSet controller can set/remove ControllerRef

This is mostly a copy from https://github.com/kubernetes/kubernetes/pull/27600
2016-07-22 04:18:00 -07:00
k8s-merge-robot f37cadd357 Merge pull request #29445 from wojtek-t/fix_kubemark_after_ip_address_machinations
Automatic merge from submit-queue

Fix Kubemark config after IP addresses machinations
2016-07-22 03:44:46 -07:00
Wojciech Tyczynski 28205d6a43 Fix Kubemark config after IP addresses machinations 2016-07-22 11:49:15 +02:00
Random-Liu 7b27358068 Change SetupNode to True for node e2e docker validation test. 2016-07-22 00:07:09 -07:00
k8s-merge-robot cfdb468654 Merge pull request #29114 from matttproud/cleanups/density_e2e
Automatic merge from submit-queue

test/e2e: plug time.Ticker resource leak.

This commit ensures that `logPodStartupStatus` does not leak
running `time.Ticker` instances.  Upon termination of the consuming
routine, we stop the ticker.
2016-07-22 00:05:20 -07:00
Antoine Pelisse ab3e4494d3 Tentatively fix broken kubemark tests
The multi-line bash command is ill-formed.
2016-07-21 20:39:04 -07:00
k8s-merge-robot c8a3c5c02c Merge pull request #29396 from fgrzadkowski/fix_kubemark
Automatic merge from submit-queue

Add static IP address for kubemark master.

This PR fixes kubemark, which was broken after https://github.com/kubernetes/kubernetes/pull/29295.

Because of https://github.com/kubernetes/kubernetes/issues/29392 merge queue is not blocked so it's not super urgent.

@k8s-oncall @wojtek-t  @roberthbailey @lavalamp
2016-07-21 16:35:44 -07:00
k8s-merge-robot ea312b7b31 Merge pull request #29182 from kevin-wangzefeng/fix-scheduler-predicates
Automatic merge from submit-queue

use regular client instead of kubectl in scheduler predicate tests when checking/setting/cleanning taints/labels

The existing implementation in scheduler predicate tests uses kubectl to check/set/clean taints/labels on node, which makes the test very related to kubectl.

 This PR is to use regular client instead.
2016-07-21 16:02:59 -07:00
Filip Grzadkowski a2c2f7d8f7 Add static IP address for kubemark master. 2016-07-21 21:03:18 +02:00
k8s-merge-robot cad9333ce7 Merge pull request #29242 from kubernetes/revert-28802-service
Automatic merge from submit-queue

Revert "Drop support for --gce-service-account, require activated creds"

Reverts kubernetes/kubernetes#28802

This appears to break the soak tests with "invalid grant" errors -- see the recent batch of errors in #27920.
2016-07-21 07:57:41 -07:00
Bryan Boreham e5e7b60e9a Remove Pdeathsig code because it doesn't do what was intended
Pdeathsig is applied to the process we are starting, so that will get
killed if the e2e_node process dies, which isn't what we need.
2016-07-21 15:19:39 +01:00
Bryan Boreham a8d7e93d66 Change process group when sending kill signal
Otherwise when the target process is running sudo it ignores the signal.
2016-07-21 15:11:03 +01:00
k8s-merge-robot 7e0a6e497a Merge pull request #29288 from wojtek-t/ability_for_faster_load_test
Automatic merge from submit-queue

Allow for overriding throughput in load test

We seem to be already supporting higher throughput that what the default is.

I'm going to increase the throughput in our tests:
- speed up scalability tests
- ensure that what I'm seeing locally is really the repeatable case

This PR is a short preparation for those experiments.

[Ideally, I would like to have kubemark-500 to be finishing within 30 minutes. And I think this should be doable pretty soon.]

@gmarek
2016-07-21 05:20:20 -07:00
k8s-merge-robot 80a59f0294 Merge pull request #29131 from Random-Liu/use-pre-pull
Automatic merge from submit-queue

Change some node e2e test to use the prepull image framework.

Fix https://github.com/kubernetes/kubernetes/issues/28868.

Node e2e test framework pre-pulls all images in [image_list.go](bc2f223f5a/test/e2e_node/image_list.go)

All node e2e test should use image from the "image_list". If a test needs new image, we should update the image_list to include the new image.

/cc @kubernetes/sig-node to notice people to use `image_list` when adding test. :)
2016-07-21 02:39:57 -07:00
Wojciech Tyczynski e21b7109e1 Integration tests for ReplicaSet OwnerRef 2016-07-21 11:36:52 +02:00
Kevin 4e280c6fd9 use regular client instead of kubectl in scheduler predicate tests when setting/cleanning taints/labels 2016-07-21 17:13:28 +08:00
Wojciech Tyczynski 7f70a63095 Allow for overriding throughput in load test 2016-07-21 10:07:53 +02:00
Wojciech Tyczynski 4d0d115690 Revert "add tokenreviews endpoint to implement webhook" 2016-07-21 09:40:35 +02:00
k8s-merge-robot 8ead63f127 Merge pull request #28788 from deads2k/wire-authentication
Automatic merge from submit-queue

add tokenreviews endpoint to implement webhook

Wires up an API resource under `apis/authentication.k8s.io/v1beta1` to expose the webhook token authentication API as an API resource.  This allows one API server to use another for authentication and uses existing policy engines for the "authoritative" API server to controller access to the endpoint.

@cjcullen you wrote the initial type
2016-07-20 22:23:45 -07:00
Michail Kargakis 97b9c73bf1 e2e: test for scaling+rolling out a deployment at once 2016-07-21 00:42:25 +02:00
Tim Hockin b829d4d4ef Merge pull request #26702 from joe2far/fix-broken-links
Fix broken warning image link in docs
2016-07-20 15:10:41 -07:00
Ron Lai ee4822e476 Moving image pulling errors under kubelet/images 2016-07-20 14:20:53 -07:00
deads2k 2c4a9f2e8d interesting changes to add tokenreviews endpoint to implement webhook 2016-07-20 15:11:56 -04:00
Avesh Agarwal f37d8fd60f Fix node e2e (kubelet metrics) by adding GinkgoRecover to a goroutine
to avoid panic
2016-07-20 13:26:56 -04:00
k8s-merge-robot d1fba05a1b Merge pull request #29020 from Random-Liu/add-namespace-controller-in-node-e2e
Automatic merge from submit-queue

Start namespace controller in node e2e

Fix https://github.com/kubernetes/kubernetes/issues/28320.
Based on https://github.com/kubernetes/kubernetes/pull/28807, only the last 2 commits are new.

Before this PR, there was no namespace controller running in node e2e test infrastructure. We can not enable the [`delete-namespace`](f2ddd60eb9/test/e2e/framework/test_context.go (L109)) flag in the test framework.
So after the test running, there will be running pod left on the test node. This seems to be acceptable in our test infrastructure because we create an new instance each time.

However, in 1.4 we may want to provide part of the test as node conformance test to the user, they definitely don't want the test to leave tons of pods on their node after test running.

Currently, there is no easy way to only start namespace controller in kube-controller-manager (confirmed with @mikedanese), so in this PR I started a "uncontainerized" one in the test infrastructure.

This PR:
* Started the namespace controller in the node e2e test infrastructure and enable the automatic namespace deletion.
* Change the privileged test to use framework (@yujuhong), so that all node e2e tests are using the framework and test pods will be cleaned up by namespace controller.

/cc @kubernetes/sig-node
2016-07-20 09:24:26 -07:00
Random-Liu 691d24cc66 Change some node e2e test to use the prepull image framework. 2016-07-20 08:16:40 -07:00
k8s-merge-robot 3af6f472e4 Merge pull request #29250 from aveshagarwal/master-node-e2e-configmap-fixes
Automatic merge from submit-queue

Fix a typo
2016-07-20 07:52:23 -07:00
Maciej Szulik 17788bb1e0 Rework pod waiting mechanism in e2e tests to accept pod and watch based
on its ResourceVersion to make sure we catch all the events.
2016-07-20 15:21:50 +02:00
Avesh Agarwal 0c8b7de238 Fixes a typo 2016-07-19 22:40:48 -04:00
Marek Grabowski ec4b28791e Revert "Scheduler predicates tests should consider unschedulable" 2016-07-19 18:50:40 -07:00
Ryan Hitchman 0cb96b3614 Revert "Drop support for --gce-service-account, require activated creds" 2016-07-19 17:41:39 -07:00
Antoine Pelisse 321c410308 Revert "Switched watches in tests require ResourceVersion to be passed" 2016-07-19 13:28:57 -07:00
derekwaynecarr 09bac89aff Add support to quota pvc storage requests 2016-07-19 16:08:49 -04:00
k8s-merge-robot 63bb2810d2 Merge pull request #28212 from soltysh/wait_pod
Automatic merge from submit-queue

Switched watches in tests require ResourceVersion to be passed

For testing the Watches are not sufficient in that it might miss the event of transitioning a Pod from one state to another which might happen before we start Watching events. To remedy this, I'm proposing to switch to Gets to always read the actual state of a Pod.

@smarterclayton this fixes https://github.com/openshift/origin/issues/9192 and hopefully all `gave up waiting for pod...` flakes 

[![Analytics](https://kubernetes-site.appspot.com/UA-36037335-10/GitHub/.github/PULL_REQUEST_TEMPLATE.md?pixel)]()
2016-07-19 11:28:23 -07:00
Davanum Srinivas ee8507a5ae Use Infof/Warningf when appropriate
When we use a format string, we should use Infof/Warningf instead
of Info/Warning
2016-07-19 12:10:53 -04:00
k8s-merge-robot dca70739af Merge pull request #29110 from bboreham/clarify-healthcheck
Automatic merge from submit-queue

Don't repeat the program name in healthCheckCommand.String()

The name is in both `Path` and `Args[0]`, so start printing args at 1.
Also refactor to avoid an extra space character in the output.

I pondered whether `healthCheckCommand.String()` should check if the slice is empty, to avoid a panic, but it didn't check for `Cmd==nil` before.

Fixes #29107
2016-07-19 05:08:42 -07:00
k8s-merge-robot be8abdabf8 Merge pull request #27157 from soltysh/scheduledjob_test_2
Automatic merge from submit-queue

Scheduledjob test cont.

This continuation of #25737.

@erictune @caesarxuchao ptal

[![Analytics](https://kubernetes-site.appspot.com/UA-36037335-10/GitHub/.github/PULL_REQUEST_TEMPLATE.md?pixel)]()
2016-07-19 02:52:19 -07:00
k8s-merge-robot 8f8e6205e5 Merge pull request #28970 from intelsdi-x/sheduler_tests_should_consider_unschedulable
Automatic merge from submit-queue

Scheduler predicates tests should consider unschedulable

fixes https://github.com/kubernetes/kubernetes/issues/28857
2016-07-19 00:34:53 -07:00
k8s-merge-robot b3797b8a25 Merge pull request #28927 from Random-Liu/docker-validation-image-config-file
Automatic merge from submit-queue

Change the docker validation node e2e test to use gci-canary-test

This PR changed the continuous docker validation node e2e test to use the image config file introduced in https://github.com/kubernetes/kubernetes/pull/28708. @euank 

This PR also changed the gci image family from `gci-preview-test` to `gci-canary-test`. @wonderfly
2016-07-18 23:27:18 -07:00
k8s-merge-robot a049a97820 Merge pull request #28803 from lukaszo/ds
Automatic merge from submit-queue

Make Daemonset use GeneralPredicates

fixes: #21454 #22205
2016-07-18 22:12:14 -07:00
k8s-merge-robot 8d46d9b0c7 Merge pull request #28281 from nhlfr/authorize-return-bool
Automatic merge from submit-queue

Return (bool, error) in Authorizer.Authorize()

Before this change, Authorize() method was just returning an error, regardless of whether the user is unauthorized or whether there is some other unrelated error. Returning boolean with information about user authorization and error (which should be unrelated to the authorization) separately will make it easier to debug.

Fixes #27974
2016-07-18 21:40:26 -07:00
Random-Liu fa8bd1d034 Change privileged test to use framework, so that all namespaces
will be cleaned up by namespace controller.
2016-07-18 19:06:59 -07:00
Random-Liu ad7e3c3053 Start namespace controller in node e2e test. 2016-07-18 19:06:59 -07:00
k8s-merge-robot af0835c0f4 Merge pull request #28807 from Random-Liu/e2e-node-e2e-share-test
Automatic merge from submit-queue

Node E2E: Make it possible to share test between e2e and node e2e

This PR is part of the plan to improve node e2e test coverage.
* Now to improve test coverage, we have to copy test from e2e to node e2e.
* When adding a new test, we have to decide its destiny at the very beginning - whether it is a node e2e or e2e.

This PR makes it possible to share test between e2e and node e2e. 
By leveraging the mechanism of ginkgo, as long as we can import the test package in the test suite, the corresponding `Describe` will be run to initialize the global variable `_`, and the test will be inserted into the test suite. (See https://github.com/onsi/composition-ginkgo-example)

In the future, we just need to use the framework to write the test, and put the test into `test/e2e/node`, then it will be automatically shared by the 2 test suites.

This PR:
1) Refactored the framework to make it automatically differentiate e2e and node e2e (Mainly refactored the `PodClient` and the apiserver client initialization).
2) Created a new directory `test/e2e/node` and make it shared by e2e and node e2e.
3) Moved `container_probe.go` into `test/e2e/node` to verify the change.

@kubernetes/sig-node 

[![Analytics](https://kubernetes-site.appspot.com/UA-36037335-10/GitHub/.github/PULL_REQUEST_TEMPLATE.md?pixel)]()
2016-07-18 18:52:56 -07:00
Random-Liu e40e82bd5c Make it possible to share test between e2e and node e2e,
and make container probing test shared to validate.
2016-07-18 14:05:08 -07:00
k8s-merge-robot 92f6b0c889 Merge pull request #29130 from caesarxuchao/fix-29065
Automatic merge from submit-queue

[flake fix] Wait for the podInformer to observe the pod

Fix #29065 

The problem is that the rc manager hasn't observed pod1, so it creates another pod and scales down, pod1 might get deleted. To fix it, wait for the podInformer to observe the pod before running the rc manager.

Marked as P0 as it's fixing a P0 flake.
2016-07-18 13:54:41 -07:00
k8s-merge-robot d08a722647 Merge pull request #28802 from fejta/service
Automatic merge from submit-queue

Drop support for --gce-service-account, require activated creds

Now that `gcloud auth activate-service-account` is in remove support in the test framework for default service accounts -- testing GCE/GKE now requires prior gcloud activation.
2016-07-18 12:08:03 -07:00
Maciej Szulik 647124bf5e ScheduledJob client and storage tests 2016-07-18 21:01:21 +02:00
Chao Xu 519b57484c wait for the podInformer to observe the pod creation in the rc's TestAdoption test 2016-07-18 11:26:58 -07:00
Marek Grabowski 77037722a3 Merge pull request #29111 from gmarek/maxpods
Fix the fix - no type-checking...
2016-07-18 16:30:18 +02:00
Matt T. Proud 656ea8f98f test/e2e: plug time.Ticker resource leak.
This commit ensures that `logPodStartupStatus` does not leak
running `time.Ticker` instances.  Upon termination of the consuming
routine, we stop the ticker.
2016-07-18 16:26:42 +02:00
k8s-merge-robot fa174bcdaf Merge pull request #29042 from dims/fixup-imports
Automatic merge from submit-queue

Use Go canonical import paths

Add canonical imports only in existing doc.go files.
https://golang.org/doc/go1.4#canonicalimports

Fixes #29014
2016-07-18 07:23:38 -07:00
gmarek 9c49e87aa4 Fix the fix - no type-checking... 2016-07-18 16:02:47 +02:00
Bryan Boreham 0991c04be1 Don't repeat the program name in healthCheckCommand.String()
The name is in both 'Path' and 'Args[0]', so start printing args at 1.
Also refactor to avoid an extra space character in the output.
2016-07-18 14:55:39 +01:00
Pawel Skrzynski 1d7ee42ff0 Scheduler predicates tests shouldnt use unschedulable nodes to count capacity 2016-07-18 15:51:26 +02:00
Michal Rostecki fa0dd46ab7 Return (bool, error) in Authorizer.Authorize()
Before this change, Authorize() method was just returning an error,
regardless of whether the user is unauthorized or whether there
is some other unrelated error. Returning boolean with information
about user authorization and error (which should be unrelated to
the authorization) separately will make it easier to debug.

Fixes #27974
2016-07-18 12:06:54 +02:00
Maciej Szulik 83297a0617 Rework pod waiting mechanism in e2e tests to accept pod and watch based
on its ResourceVersion to make sure we catch all the events.
2016-07-18 12:06:36 +02:00
Maciej Szulik 4b0c0bd924 Shorten initial pod start time to 30s in e2e, since 4566 is closed 2016-07-18 12:03:32 +02:00
k8s-merge-robot 524c5b5361 Merge pull request #29005 from gmarek/maxpods
Automatic merge from submit-queue

Fix verify results in MaxPods

As we already have "unschedulable" PodCondition we can stop relying on Events, which should make the tests more reliable.

cc @davidopp
2016-07-18 02:54:44 -07:00
k8s-merge-robot 156205523d Merge pull request #28852 from deads2k/use-user
Automatic merge from submit-queue

authorize based on user.Info

Update the `authorization.Attributes` to use the `user.Info` instead of discrete getters for each piece.

@kubernetes/sig-auth
2016-07-16 20:12:43 -07:00
Davanum Srinivas 2b0ed014b7 Use Go canonical import paths
Add canonical imports only in existing doc.go files.
https://golang.org/doc/go1.4#canonicalimports

Fixes #29014
2016-07-16 13:48:21 -04:00
k8s-merge-robot 51629f50b7 Merge pull request #29031 from saad-ali/waitForDetachOnPDTests
Automatic merge from submit-queue

Make PD E2E Tests Wait for Detach to Prevent Kernel Errors

Fixes https://github.com/kubernetes/kubernetes/issues/28854
2016-07-16 10:01:15 -07:00
k8s-merge-robot 5b027a5861 Merge pull request #28976 from coufon/debug_mirror_pod_test
Automatic merge from submit-queue

Fix a bug in mirror pod node e2e test.

Fixed a bug in test/e2e_node/mirror_pod_test.go. The function 'checkMirrorPodDisappear' returns nil even when the pod does not disappear. It should return a non-nil error. 

@Random-Liu
2016-07-15 17:39:16 -07:00
saadali ce0e976c7c Wait for PD detach on PD E2E to prevent kernel err 2016-07-15 14:31:45 -07:00
k8s-merge-robot 36c07cc554 Merge pull request #27961 from maisem/os-distribution
Automatic merge from submit-queue

Splitting OS_DISTRIBUTION into NODE_OS_DISTRIBUTION and MASTER_OS_DISTRIBUTION

fixes #26183 
[![Analytics](https://kubernetes-site.appspot.com/UA-36037335-10/GitHub/.github/PULL_REQUEST_TEMPLATE.md?pixel)]()
2016-07-15 14:11:47 -07:00
Maisem Ali 97f3f80833 Splitting OS_DISTRIBUTION into NODE_OS_DISTRIBUTION and
MASTER_OS_DISTRIBUTION.
2016-07-15 12:02:31 -07:00
Buddha Prakash 5000e74664 Inject top level QoS cgroup creation in the Kubelet 2016-07-15 10:02:22 -07:00
gmarek 47d51e5138 Fix verify results in MaxPods 2016-07-15 16:18:22 +02:00
Marek Grabowski d1ff1b9726 Merge pull request #29003 from gmarek/taint
Fix the fix for taint scheduler predicate test
2016-07-15 16:15:02 +02:00
gmarek e936d57266 Fix the fix for taint scheduler predicate test 2016-07-15 16:13:13 +02:00
k8s-merge-robot 186c0c7b14 Merge pull request #29000 from gmarek/taint
Automatic merge from submit-queue

Defer taint removal in SchedulerPredictes

cc @davidopp @kevin-wangzefeng
2016-07-15 06:23:01 -07:00
gmarek 0129e25f8e Defer taint removal in SchedulerPredictes 2016-07-15 14:01:32 +02:00
k8s-merge-robot e7e434b10d Merge pull request #27600 from caesarxuchao/rc-gc
Automatic merge from submit-queue

[GarbageCollector] Let the RC manager set/remove ControllerRef

What's done:
* RC manager sets Controller Ref when creating new pods
* RC manager sets Controller Ref when adopting pods with matching labels but having no controller
* RC manager clears Controller Ref when pod labels change
* RC manager clears pods' Controller Ref when rc's selector changes
* RC manager stops adoption/creating/deleting pods when rc's DeletionTimestamp is set
* RC manager bumps up ObservedGeneration: The [original code](https://github.com/kubernetes/kubernetes/blob/master/pkg/controller/replication/replication_controller_utils.go#L36) will do this.
* Integration tests:
  * verifies that changing RC's selector or Pod's Labels triggers adoption/abandoning
* e2e tests (separated to #27151):
  * verifies GC deletes the pods created by RC if DeleteOptions.OrphanDependents=false, and orphans the pods if DeleteOptions.OrphanDependents=true.

TODO:

- [x] we need to be able to select Pods that have a specific ControllerRef. Then each time we sync the RC, we will iterate through all the Pods that has a controllerRef pointing the RC, event if the labels of the Pod doesn't match the selector of RC anymore. This will prevent a Pod from stuck with a stale controllerRef, which could be caused by the race between abandoner (the goroutine that removes controllerRef) and worker the goroutine that add controllerRef to pods).
- [ ] use controllerRef instead of calling `getPodController`. This might be carried out by the control-plane team.
- [ ] according to the controllerRef proposal (#25256): "For debugging purposes we want to add an adoptionTime annotation prefixed with kubernetes.io/ which will keep the time of last controller ownership transfer." This might be carried out by the control-plane team.

cc @lavalamp @gmarek
2016-07-15 04:40:40 -07:00
joe2far 88b6d4ad36 Fix broken warning image link in docs 2016-07-15 10:44:58 +01:00
Wojciech Tyczynski f71244975d Revert "[garbage collector] add e2e test" 2016-07-15 10:10:02 +02:00
Chao Xu 11a341de67 let RC manager utilize the GC 2016-07-14 19:59:31 -07:00
k8s-merge-robot 01e34b72c1 Merge pull request #27151 from caesarxuchao/gc-e2e
Automatic merge from submit-queue

[garbage collector] add e2e test

This PR also includes some changes to plumb controller-manager's `--enable_garbage_collector` from the environment variable.

The e2e test will not be run by the core suite because it's marked `[Feature:GarbageCollector]`.

The corresponding jenkins job configuration PR is https://github.com/kubernetes/test-infra/pull/132.
2016-07-14 19:55:52 -07:00
Daniel Smith 360f2eb927 Revert "Remove pod mutation for PVs with supplemental GIDs" 2016-07-14 17:47:46 -07:00
coufong 8a4c394ede Fix a bug in mirror pod node e2e test. 2016-07-14 16:59:08 -07:00
k8s-merge-robot be3175611c Merge pull request #28691 from wongma7/pv-gid-squash2
Automatic merge from submit-queue

Remove pod mutation for PVs with supplemental GIDs

Continuation of https://github.com/kubernetes/kubernetes/pull/27571 to bring the feature back without pod mutation
2016-07-14 11:22:04 -07:00
k8s-merge-robot 50172148e4 Merge pull request #25273 from ncdc/exec-sigwinch
Automatic merge from submit-queue

Support terminal resizing for exec/attach/run

```release-note
Add support for terminal resizing for exec, attach, and run. Note that for Docker, exec sessions
inherit the environment from the primary process, so if the container was created with tty=false,
that means the exec session's TERM variable will default to "dumb". Users can override this by
setting TERM=xterm (or whatever is appropriate) to get the correct "smart" terminal behavior.
```

Fixes #13585
2016-07-14 07:26:49 -07:00
deads2k f6f1ab34aa authorize based on user.Info 2016-07-14 07:48:42 -04:00
Random-Liu b0d3f4c14a Change gci-preview-test to gci-canary-test. 2016-07-13 17:57:23 -07:00
Andy Goldstein 3b21a9901b Support terminal resizing for exec/attach/run
Add support for terminal resizing for exec, attach, and run. Note that for Docker, exec sessions
inherit the environment from the primary process, so if the container was created with tty=false,
that means the exec session's TERM variable will default to "dumb". Users can override this by
setting TERM=xterm (or whatever is appropriate) to get the correct "smart" terminal behavior.
2016-07-13 17:06:16 -04:00
Matthew Wong 58f973d8e7 Remove pod mutation for PVs with supplemental GIDs 2016-07-13 13:51:17 -04:00
Łukasz Oleś 528bf7af3a Make Daemonset use GeneralPredicates
fixes #21454, fixes #22205
2016-07-13 14:50:29 +02:00
Tim Hockin 6e516e1c8a make Jenkins pass 2016-07-12 21:52:54 -07:00
Tim Hockin faeef5c4ae Use make as the main build tool
This allows us to start building real dependencies into Makefile.

Leave old hack/* scripts in place but advise to use 'make'.  There are a few
rules that call things like 'go run' or 'build/*' that I left as-is for now.
2016-07-12 21:52:00 -07:00
k8s-merge-robot 0cd93cfc53 Merge pull request #28708 from euank/node-e2e-image-conf
Automatic merge from submit-queue

node_e2e: configure gce images via config file

This file provides the abiliy to specify image project on a per-image
basis and is more extensible for future changes.

For backwards compatibility and local development convenience, the
existing flags are kept and should work.

The eventual goal is to be able to source some images, such as the CoreOS one (and possibly containervm one) from their upstream projects and do all new configuration changes via a cloud-init key added to the image config.

This PR is a first step there. A following PR will add a config key of `cloud-init` or `user-data` and migrate the CoreOS e2e to use that.

This motivation is driven by the fact that currently the changes needed for the CoreOS image can all be done quickly in cloud-init and this will make it much easier to update the image and ensure that changes are applied consistently.

/cc @timstclair @vishh @yifan-gu @pwittrock
2016-07-12 19:06:14 -07:00
k8s-merge-robot b6ffcf7875 Merge pull request #28213 from Random-Liu/docker-validation-node-e2e
Automatic merge from submit-queue

Node E2E: Prep for continuous Docker validation node e2e test

Based on https://github.com/kubernetes/kubernetes/pull/28516, for https://github.com/kubernetes/kubernetes/issues/25215.

https://github.com/kubernetes/kubernetes/pull/26813 added support to run e2e test on gci preview image and newest docker version.
This PR added the same support to node e2e test.

The main dependencies of node e2e test are `docker`, `kubelet`, `etcd` and `apiserver`.
Currently, node e2e test builds `kubelet` and `apiserver` locally, and copies them into `/tmp` directory in VM instance. GCI also has built-in `docker`. So the only dependency missing is `etcd`.

This PR injected a simple cloud-init script when creating instance to install `etcd` during node startup.

@andyzheng0831 for the cloud init script.
@wonderfly for the gci instance setup.
@pwittrock for the node e2e test change.

/cc @dchen1107 

[![Analytics](https://kubernetes-site.appspot.com/UA-36037335-10/GitHub/.github/PULL_REQUEST_TEMPLATE.md?pixel)]()
2016-07-12 14:51:29 -07:00
k8s-merge-robot 9467c21958 Merge pull request #28760 from kubernetes/revert-28015-workaround_kubeproxy
Automatic merge from submit-queue

Revert "Workardound KubeProxy failures in test framework"

Reverts kubernetes/kubernetes#28015

For https://github.com/kubernetes/kubernetes/issues/25543.
Revert walkaround in test framework to verify whether https://github.com/kubernetes/kubernetes/pull/28697 solved the problem.

@wojtek-t
2016-07-12 05:00:10 -07:00
k8s-merge-robot 629f3c159e Merge pull request #28558 from quinton-hoole/2016-07-06-excise-ubernetes-from-main-repo
Automatic merge from submit-queue

Deprecate the term "Ubernetes" 

Deprecate the term "Ubernetes" in favor of "Cluster Federation" and  "Multi-AZ Clusters"
2016-07-11 23:20:53 -07:00
k8s-merge-robot 70a2c7ddbe Merge pull request #28808 from dims/fix-issue-27978
Automatic merge from submit-queue

Fix path for examples - storage/volume directories changed

Added /volume and /storage in a couple of spots. 

Fixes #27978
2016-07-11 20:41:31 -07:00
k8s-merge-robot b840f039cc Merge pull request #28747 from mtaufen/framework_pods
Automatic merge from submit-queue

Return server's representation of pod from framework pod creation functions

Since PodInterface.Create returns the server's representation of the pod, which may differ from the api.Pod object passed to Create, we do the same from the framework's pod creation functions. This is useful if e.g. you create pods using Pod.GenerateName rather than Pod.Name, and you still want to refer to pods by name later on (e.g. for deletion).

cc @timstclair
2016-07-11 20:06:39 -07:00
Euan Kemp af1700b41e node_e2e: configure gce images via config file
This file provides the abiliy to specify image project on a per-image
basis and is more extensible for future changes.

For backwards compatibility and local development convenience, the
existing flags are kept and should work.
2016-07-11 19:19:37 -07:00
Davanum Srinivas 5fda0c25c5
Fix path for examples - storage/volume directories changed
Fixes #27978
2016-07-11 22:00:28 -04:00
Random-Liu 79f564e9dc Add docker validation node e2e test. 2016-07-11 18:58:57 -07:00
Erick Fejta fe8578db80 Drop support for --gce-service-account, require activated creds 2016-07-11 14:47:04 -07:00
Minhan Xia 0bd411878a bump cni version 2016-07-11 14:33:01 -07:00
Jan Safranek 8d0cebd4af integration test: Modify PVs/PVCs during binding.
Previous volume binder code was not able to cope with PVs or PVCs getting
modified during the binding process. Current one should be resilient to
these changes, so let's test it.

It makes the test approximately twice as long as before, from ~2 seconds to
~4-5.
2016-07-11 15:55:24 +02:00
Lantao Liu f68acf6460 Revert "Workardound KubeProxy failures in test framework" 2016-07-11 00:19:15 -07:00
k8s-merge-robot 0a6561f5e9 Merge pull request #28704 from dims/fix-issue-11747
Automatic merge from submit-queue

E2E test for kubectl replace
2016-07-11 00:14:57 -07:00
Michael Taufen e709599854 Modify framework pod creation functions to return the server's representation of the pod
Since PodInterface.Create returns the server's representation of the
pod, which may differ from the api.Pod object passed to Create, we do
the same from the framework's pod creation functions. This is useful if
e.g. you create pods using Pod.GenerateName rather than
Pod.Name, and you still want to refer to pods by name later on
(e.g. for deletion).
2016-07-10 17:03:39 -07:00
Davanum Srinivas 87771957d0
E2E test for kubectl replace
Fixes #10764
2016-07-09 09:41:01 -04:00
k8s-merge-robot 3b3f7fb09c Merge pull request #27977 from ciwang/move-storage-examples
Automatic merge from submit-queue

Move storage examples

Fixes #23671 

Consolidate storage examples into separate folders for storage and volume plugins
2016-07-08 21:45:38 -07:00
k8s-merge-robot 66d580bf3c Merge pull request #28661 from dubstack/dubstack-update-coreos
Automatic merge from submit-queue

Update coreos node e2e image to a version that uses cgroupfs

Temporary fix for #28192. This PR updates coreos node e2e image to a version that uses cgroupfs.

cc @vishh @yifan-gu
2016-07-08 14:40:23 -07:00
Cindy Wang fedc513658 Consolidated examples into storage/ and volume/ folders
Search and replace for references to moved examples

Reverted find and replace paths on auto gen docs

Reverting changes to changelog

Fix bugs in test-cmd.sh

Fixed path in examples README

ran update-all successfully

Updated verify-flags exceptions to include renamed files
2016-07-08 13:34:32 -07:00
Buddha Prakash fb7f18f542 Update node e2e image copy script 2016-07-08 11:10:23 -07:00
Chao Xu 7a5b3c43a0 plumb --enable_garbage_collector from environment variable;
adding a simple e2e test
2016-07-08 10:27:16 -07:00
k8s-merge-robot c092e2c5c5 Merge pull request #28466 from sttts/sttts-fix-benchmark-integration
Automatic merge from submit-queue

Fix compilation of master_benchmark_test.go
2016-07-08 03:41:05 -07:00
Angus Salkeld eec08872c7 Move deployment utilities to there own package 2016-07-08 09:46:56 +02:00
Dr. Stefan Schimanski 1f9046471c Compile fixes for master_benchmark_test.go 2016-07-08 08:02:04 +02:00
k8s-merge-robot d6d846f4e5 Merge pull request #28517 from Random-Liu/better-image-pull-test
Automatic merge from submit-queue

Node E2E: Use waiting reason to figure out image pulling error.

Addresses https://github.com/kubernetes/kubernetes/pull/28323#issuecomment-230002158, using `Waiting` reason to check whether the image pulling failures as expected.

@yujuhong 

[![Analytics](https://kubernetes-site.appspot.com/UA-36037335-10/GitHub/.github/PULL_REQUEST_TEMPLATE.md?pixel)]()
2016-07-07 19:36:25 -07:00
k8s-merge-robot 60b0bc2efc Merge pull request #28516 from Random-Liu/disable-cni-for-local-node-e2e
Automatic merge from submit-queue

Node E2E: Disable kubenet for local node e2e test.

After https://github.com/kubernetes/kubernetes/pull/28196, we must manually setup cni and nsenter in local node to run `make test_e2e_node`, which may not be necessary for local development.

I've tried to move cni downloading logic into `BeforeSuite`, however it is still hard to figure out who should install nsenter, manually installed by every developer? in the `setup_host.sh` script? in `BeforeSuite`?

This PR:
* Added a flag to disable kubenet and disabled kubenet in local test.
* Cleaned up the CNI installation logic a bit.

/cc @yujuhong @freehan 
[![Analytics](https://kubernetes-site.appspot.com/UA-36037335-10/GitHub/.github/PULL_REQUEST_TEMPLATE.md?pixel)]()
2016-07-07 18:52:57 -07:00
Mike Danese 13f36d5117
delete some dead code
Signed-off-by: Mike Danese <mikedanese@google.com>
2016-07-07 00:54:19 -07:00
Mike Danese f3de21bdf0
move integration tests into individual pacakges
Signed-off-by: Mike Danese <mikedanese@google.com>
2016-07-07 00:54:15 -07:00
k8s-merge-robot 9075f53dca Merge pull request #28388 from mml/cluster-refactor
Automatic merge from submit-queue

Collect cluster state into a single type.

Mostly just makes it easier to read and, hopefully, extend.
2016-07-06 23:03:01 -07:00
k8s-merge-robot 6de30e64d3 Merge pull request #28521 from Random-Liu/fix-flake-pod-test
Automatic merge from submit-queue

E2E: Add UpdatePod function in e2e framework and change the test to use it.

Fix https://github.com/kubernetes/kubernetes/issues/28096.

Some e2e tests need to update pod, but the pod update is a bit complex because of potential conflict. #28096 happened just because the test only called pod `Update` once.

This PR move the update pod logic into a util function `UpdatePod` in e2e framework, and change the tests to use it.

Mark P2 because the original issue is P0, but in fact happens not quite frequently. :)

[![Analytics](https://kubernetes-site.appspot.com/UA-36037335-10/GitHub/.github/PULL_REQUEST_TEMPLATE.md?pixel)]()

the test to use it.
2016-07-06 17:25:31 -07:00
Quinton Hoole 791dd215d2 Deprecate the term "Ubernetes" in favor of "Cluster Federation" and "Multi-AZ Clusters" 2016-07-06 15:42:56 -07:00
Matt Liggett 5b8113dffd code review fixes 2016-07-06 15:10:29 -07:00
Matt Liggett 55e642cb9f Use a pointer. Duh. 2016-07-06 15:10:29 -07:00