Commit Graph

35024 Commits (dc529a03b1f116ae90f666ed9d87cd73b2643c0f)

Author SHA1 Message Date
Kubernetes Submit Queue 0c8b17891b Merge pull request #28759 from xiang90/pas
Automatic merge from submit-queue

controller/podautoscaler: minor cleanup

1. remove unnecessary else statement

2. remove unnecessary initialization
2016-09-06 00:38:46 -07:00
Ilya Dmitrichenko fe768dd405 Do not go into standalone mode when `--require-kubeconfig` is passed (fix #32085) 2016-09-06 08:30:06 +01:00
Kubernetes Submit Queue c4e2ade371 Merge pull request #31761 from ZTE-PaaS/zhangke-patch-032
Automatic merge from submit-queue

change sourcesSeenLock to sync.RWMutex

seenSources can be accessed concurrently
2016-09-05 23:58:27 -07:00
Wojciech Tyczynski 5582856e23 Fix debugging log in RC 2016-09-06 08:50:44 +02:00
Kubernetes Submit Queue 5e22e51f34 Merge pull request #31675 from brendandburns/msgs
Automatic merge from submit-queue

improve some error messages.

Fixes https://github.com/kubernetes/kubernetes/issues/9944

@pwittrock @deads2k 
@kubernetes/kubectl
2016-09-05 23:23:11 -07:00
Kubernetes Submit Queue 7d09f954c4 Merge pull request #31860 from lojies/adddeployforsetimage
Automatic merge from submit-queue

add deploy for deployment in kubectl set image help text

add shorthand deploy for deployment in kubectl set image help text
2016-09-05 22:44:53 -07:00
Kubernetes Submit Queue 562e1747a8 Merge pull request #31698 from m1093782566/m109-pet-set-errs-err
Automatic merge from submit-queue

[Pet Set] Refactor return []error to error

<!--  Thanks for sending a pull request!  Here are some tips for you:
1. If this is your first time, read our contributor guidelines https://github.com/kubernetes/kubernetes/blob/master/CONTRIBUTING.md and developer guide https://github.com/kubernetes/kubernetes/blob/master/docs/devel/development.md
2. If you want *faster* PR reviews, read how: https://github.com/kubernetes/kubernetes/blob/master/docs/devel/faster_reviews.md
3. Follow the instructions for writing a release note: https://github.com/kubernetes/kubernetes/blob/master/docs/devel/pull-requests.md#release-notes
-->

**Which issue this PR fixes** 

I propose refactor return value from `[]error` to error [here](https://github.com/kubernetes/kubernetes/blob/master/pkg/controller/petset/pet_set.go#L80), for the purpose of simplify code and format error output.

I think we can use `errors.NewAggregate(errorList)` to aggregate `[]error`.
2016-09-05 22:09:07 -07:00
Kubernetes Submit Queue 1143107d8b Merge pull request #31857 from lojies/annotataresourcechange
Automatic merge from submit-queue

change annotate_resources to valid_resources

annotate_resources missing some resources such as deployment, namespace. 

i think using valid_resources to replace annotate_resources  more suitable.
2016-09-05 21:32:21 -07:00
Kubernetes Submit Queue 59a25fb7ed Merge pull request #31677 from jianhuiz/federation-replicaset-controller-delay-fix
Automatic merge from submit-queue

fix deliverer dealy constant usage

some delay constants were not correctly used

#29741
@quinton-hoole @deepak-vij @kshafiee @mwielgus
2016-09-05 20:52:34 -07:00
Kubernetes Submit Queue 36a85cae7b Merge pull request #31764 from lojies/adddeploy
Automatic merge from submit-queue

add deploy for deployment in kubectl expose help text

add shorthand deploy for  deployment
2016-09-05 20:13:47 -07:00
Kubernetes Submit Queue 8d00825481 Merge pull request #31685 from jellonek/jell/29524
Automatic merge from submit-queue

kubectl edit: Do not add warning header if ftype is json.

This PR blocks adding warning header if `kubectl edit` is used with `-o json` option.
Fixed header contains comment (what is not supported by json standard) what can break utilities which are using libraries that conforms with http://www.ietf.org/rfc/rfc7159.txt

fixes #29524

/cc @pwittrock 

```release-note
Removed comments in json config when using kubectl edit with -o json
```
2016-09-05 19:35:31 -07:00
Kubernetes Submit Queue 2977d03bfe Merge pull request #30935 from vipulsabhaya/vsphere_zones
Automatic merge from submit-queue

Make a vSphere cluster the failure_zone

vSphere cloud provider returns the FailureZone as Cluster, if the VM belongs to a ResourcePool under a Cluster. 

fixes: #30933

* Currently the vSphere cloud provider treats Datacenter as the failure
  Zone.  This doesn't necessarily work since in the current implemention
  Kubernetes nodes cannot span Datacenters.
* This change introduces Clusters as the failure zone, while treating
  Datacenters as Regions
* Also updated tests for Zones
2016-09-05 18:57:45 -07:00
Mike Danese 9d7d77d4a3 fix log message to include ds name
and lower log level
2016-09-05 18:57:04 -07:00
Kubernetes Submit Queue af8124c7bf Merge pull request #31609 from rhcarvalho/fix-bash
Automatic merge from submit-queue

Fix Bash script

<!--  Thanks for sending a pull request!  Here are some tips for you:
1. If this is your first time, read our contributor guidelines https://github.com/kubernetes/kubernetes/blob/master/CONTRIBUTING.md and developer guide https://github.com/kubernetes/kubernetes/blob/master/docs/devel/development.md
2. If you want *faster* PR reviews, read how: https://github.com/kubernetes/kubernetes/blob/master/docs/devel/faster_reviews.md
3. Follow the instructions for writing a release note: https://github.com/kubernetes/kubernetes/blob/master/docs/devel/pull-requests.md#release-notes
-->

**What this PR does / why we need it**: `cluster/mesos/docker/socat/build.sh` had two lines mixed together.

Old command output:

```
$ ./cluster/mesos/docker/socat/build.sh 
./cluster/mesos/docker/socat/build.sh: line 21: set: pipefailscript_dir=/home/rodolfo/src/k8s.io/kubernetes/cluster/mesos/docker/socat: invalid option name
```

**Special notes for your reviewer**: probably nobody is using that script? @sttts PTAL.

**Release note**:
<!--  Steps to write your release note:
1. Use the release-note-* labels to set the release note state (if you have access) 
2. Enter your extended release note in the below block; leaving it blank means using the PR title as the release note. If no release note is required, just write `NONE`. 
-->
```release-note
NONE
```
2016-09-05 18:10:24 -07:00
Kubernetes Submit Queue 06b6fb5729 Merge pull request #31489 from ZTE-PaaS/zhangke-patch-030
Automatic merge from submit-queue

optimize if-else of setupNode of container_manager_linix

make the code more readable
2016-09-05 17:35:09 -07:00
Kubernetes Submit Queue f06dc326d3 Merge pull request #31393 from StackPointCloud/master
Automatic merge from submit-queue

fixes invalid null selector issue in sysdig example yaml

<!--  Thanks for sending a pull request!  Here are some tips for you:
1. If this is your first time, read our contributor guidelines https://github.com/kubernetes/kubernetes/blob/master/CONTRIBUTING.md and developer guide https://github.com/kubernetes/kubernetes/blob/master/docs/devel/development.md
2. If you want *faster* PR reviews, read how: https://github.com/kubernetes/kubernetes/blob/master/docs/devel/faster_reviews.md
3. Follow the instructions for writing a release note: https://github.com/kubernetes/kubernetes/blob/master/docs/devel/pull-requests.md#release-notes
-->

**What this PR does / why we need it**:

Using the file DaemonSet yaml found in the example repo you get the following error upon import:

```
$ kubectl create -f sysdig.yml
The DaemonSet "sysdig-agent" is invalid.
spec.template.metadata.labels: Invalid value: null: `selector` does not match template `labels`
```

This PR fixes this issue.


**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #

**Special notes for your reviewer**:

**Release note**:
<!--  Steps to write your release note:
1. Use the release-note-* labels to set the release note state (if you have access) 
2. Enter your extended release note in the below block; leaving it blank means using the PR title as the release note. If no release note is required, just write `NONE`. 
-->
```release-note
```
* Corrected name label metadata for Sysdig example.
2016-09-05 16:48:21 -07:00
Kubernetes Submit Queue b9481c18b4 Merge pull request #31227 from pigmej/typos_englishify_pkg_kubelet
Automatic merge from submit-queue

Fix various typos in pkg/kubelet

Just fixed some typos + "englishify" pkg/kubelet.
2016-09-05 16:11:35 -07:00
Kubernetes Submit Queue ae3b956c65 Merge pull request #31144 from ohmystack/fix/zsh-completion
Automatic merge from submit-queue

Fix named pipe in kubectl zsh completion

This PR fixes #28049

Though my zsh version > 5.0, I still got the problem. So, I think we need this fix.

---

### Env

```
OS: Ubuntu 14.04
$ zsh --version
zsh 5.0.2 (x86_64-pc-linux-gnu)
```

### A simple DEMO to show the root cause

In zsh and bash, a multi-line named pipe, who is wrapped by parenthesis, is possible to mismatch the "right parenthesis", even that parenthesis is in a here-document.

The following script was going to use `sed` to print the text in the 'BASH_COMPLETION_EOF' here-document. 
> * I made the `sed` simpler. As you can see, `sed` actually does nothing here. It just prints what it gets from `<<`). In real [`pkg/kubectl/cmd/completion.go`](https://github.com/kubernetes/kubernetes/blob/v1.3.5/pkg/kubectl/cmd/completion.go#L246-L258), `sed` will do some text replacement, changing bash functions to zsh functions. But that is not the point of the problem.
> * I use `cat <(...)` to replace the `source <(...)`.
> In this way, we can see how named pipe works.

run-bad.zsh:
```bash
#!/usr/bin/zsh
cat <(sed -e 's/foo/bar/g' <<'BASH_COMPLETION_EOF'
  aaa='aaa'
  case aaa in
    'aaa')      #  <- This ')' is in a here-document, but it is handled by named pipe by mistake.
      echo 'yes'
      ;;
  esac
BASH_COMPLETION_EOF
)
```

> Output:
> ```
> ./run-bad.zsh
>     aaa='aaa'
>     case aaa in
>       'aaa'yes     <- You can see the here-document `echo yes` has been executed!!!
> ./run-bad.zsh:8: parse error near `;;'
> ```

The named pipe `<(sed ...` "eats" the `)`, which should belong to `case aaa in 'aaa')`. So that the named pipe ends earlier than expectation. The left zsh code is broken, it fails.

### Here's the fix

Move the code into a function, and use an inline named pipe.

run.zsh:
```bash
#!/usr/bin/zsh

print_sed_result() {
  sed -e 's/foo/bar/g' <<'BASH_COMPLETION_EOF'
  aaa='aaa'
  case aaa in
    'aaa')
      echo 'yes'
      ;;
  esac
BASH_COMPLETION_EOF
}

cat <(print_sed_result)     # <- Use an inline named pipe
```

> Output:
> ```
> ./run.zsh                                                                                                                                                                    > stack@docker-dev01
>         aaa='aaa'
>         case aaa in
>           'aaa')
>             echo 'yes'
>             ;;
>         esac
> ```

Now, the here-document and named pipe work correctly.
2016-09-05 15:31:18 -07:00
Kubernetes Submit Queue 54b47dcf0b Merge pull request #31303 from thockin/volume-owners
Automatic merge from submit-queue

Make @rootfs the assignee for various volumes

This, combined with the '/lgtm' capability of reviewers means you can approve
PRs. @rootfs - I assume you're OK with this?
2016-09-05 14:53:32 -07:00
Kubernetes Submit Queue cf7b033fbf Merge pull request #25810 from andreykurilin/kubectl_rollingupdate
Automatic merge from submit-queue

Add link to diagram of `kubectl rolling-update`
2016-09-05 14:15:45 -07:00
Kubernetes Submit Queue 6bcc4e9f2a Merge pull request #31194 from mml/evict.followup
Automatic merge from submit-queue

Fix followups from #31033
2016-09-05 13:38:30 -07:00
Kubernetes Submit Queue 09e5fa62b5 Merge pull request #31294 from mml/federated-oops
Automatic merge from submit-queue

Fix e2e logic when FEDERATION=false.

Also add debugging output to GCE detect-master.

Fixes #31285.
2016-09-05 13:01:12 -07:00
Kubernetes Submit Queue 02dd178039 Merge pull request #30739 from MrHohn/e2e-sourceip
Automatic merge from submit-queue

Add e2e test for Source IP preservation (pod to service cluster IP)

Working on #27134.

This PR added the e2e test for source ip preservation (pod to service cluster IP) in service.go. Test scenario described as below:
- Pick two different nodes in cluster.
- Create a clusterIP type service.
- Create an echo server, which echoes back client IP, to be part of the service.
- Create a client on another node. Hit the server through service cluster IP.
- Verify the source IP.

@girishkalele @freehan
2016-09-05 12:23:25 -07:00
Kubernetes Submit Queue 8f54ab1766 Merge pull request #31451 from jfrazelle/27532-fix-kubectl-on-delete-flake
Automatic merge from submit-queue

test/e2e: fix flake for on delete on namespace

<!--  Thanks for sending a pull request!  Here are some tips for you:
1. If this is your first time, read our contributor guidelines https://github.com/kubernetes/kubernetes/blob/master/CONTRIBUTING.md and developer guide https://github.com/kubernetes/kubernetes/blob/master/docs/devel/development.md
2. If you want *faster* PR reviews, read how: https://github.com/kubernetes/kubernetes/blob/master/docs/devel/faster_reviews.md
3. Follow the instructions for writing a release note: https://github.com/kubernetes/kubernetes/blob/master/docs/devel/pull-requests.md#release-notes
-->

**What this PR does / why we need it**:

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #

**Special notes for your reviewer**:

**Release note**:
<!--  Steps to write your release note:
1. Use the release-note-* labels to set the release note state (if you have access) 
2. Enter your extended release note in the below block; leaving it blank means using the PR title as the release note. If no release note is required, just write `NONE`. 
-->
```release-note
NONE
```

Fixes #27532
2016-09-05 11:47:09 -07:00
Kubernetes Submit Queue 1c85bbe6cb Merge pull request #31718 from pmorie/fake-client-doc
Automatic merge from submit-queue

Improve doc for the fake client

Improve doc in this type.

cc @derekwaynecarr @ncdc @deads2k
2016-09-05 11:10:23 -07:00
Kubernetes Submit Queue b126a7a7e9 Merge pull request #31398 from yongtang/08242016-doc-build
Automatic merge from submit-queue

Update build docs to include path for scripts.

<!--  Thanks for sending a pull request!  Here are some tips for you:
1. If this is your first time, read our contributor guidelines https://github.com/kubernetes/kubernetes/blob/master/CONTRIBUTING.md and developer guide https://github.com/kubernetes/kubernetes/blob/master/docs/devel/development.md
2. If you want *faster* PR reviews, read how: https://github.com/kubernetes/kubernetes/blob/master/docs/devel/faster_reviews.md
3. Follow the instructions for writing a release note: https://github.com/kubernetes/kubernetes/blob/master/docs/devel/pull-requests.md#release-notes
-->

**What this PR does / why we need it**:

This fix updates the build docs (`build/README.md`) to include the path of `build/` for shell scripts (like `run.sh`, `shell.sh`).

The reason is that while trying to follow the `build/README.md` to build the kubernetes, it is not obvious that all the scripts, e.g., `run.sh make`, `shell.sh`, etc. needs to be executed from the root directory (vs. executed from the `build/` directory).

In other words, the executation should be:
```
build/run.sh make
build/make-clean.sh
...
```

This fix adds `build/` so that it is easy for user to follow the steps.

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #

**Special notes for your reviewer**:

**Release note**:
<!--  Steps to write your release note:
1. Use the release-note-* labels to set the release note state (if you have access) 
2. Enter your extended release note in the below block; leaving it blank means using the PR title as the release note. If no release note is required, just write `NONE`. 
-->
```release-note
```
2016-09-05 11:10:18 -07:00
Kubernetes Submit Queue 2650047f65 Merge pull request #31259 from rombit-be/update-dev-doc
Automatic merge from submit-queue

Add go-bindata as development dependency

**What this PR does / why we need it**: 
Small update in the developer notes (a go dependency was missing, which I noticed when setting up my own development environment)

**Which issue this PR fixes**: 
Not applicable

**Special notes for your reviewer**:

**Release note**:
N/A

```release-note
```
2016-09-05 11:10:14 -07:00
Kubernetes Submit Queue 61dda4d34a Merge pull request #31773 from pigmej/typos_englishify_some_pkgs
Automatic merge from submit-queue

Typos and englishify pkg/cloudprovider + pkg/dns + pkg/kubectl

**What this PR does / why we need it**: Just fixed some typos + "englishify" in pkg/cloudprovider + pkg/dns + pkg/kubectl

**Which issue this PR fixes** : None

**Special notes for your reviewer**: It's just fixes typos

**Release note**: `NONE`
2016-09-05 11:10:09 -07:00
Kubernetes Submit Queue 6d812b66aa Merge pull request #31972 from jszczepkowski/hpa-test-oom
Automatic merge from submit-queue

Bumped memory limit for resource consumer. Fixes #31591.

Bumped memory limit for resource consumer from 100 MB to 200 MB, increased request sizes so that the number of consumers will be smaller. Fixes #31591.
2016-09-05 10:33:22 -07:00
Kubernetes Submit Queue de954c0b64 Merge pull request #32081 from wojtek-t/list_from_apiserver_in_nodecontroller
Automatic merge from submit-queue

NodeController listing nodes from apiserver cache

Ref #31981

This is addressing this particular failure:
https://github.com/kubernetes/kubernetes/issues/31981#issuecomment-244432054
2016-09-05 09:54:36 -07:00
Wojciech Tyczynski b69d516763 NodeController listing nodes from apiserver cache 2016-09-05 16:52:57 +02:00
Marek Grabowski 9767c26093 Merge pull request #32079 from gmarek/load
Add a log to help debug #31981
2016-09-05 16:09:51 +02:00
gmarek a82e54262d Add a log to help debug #31981 2016-09-05 15:05:49 +02:00
Marek Grabowski ab0b937c2e Merge pull request #32076 from wojtek-t/fix_density_test
Fix density test
2016-09-05 14:07:51 +02:00
Wojciech Tyczynski 8c1b80c6d5 Fix density test 2016-09-05 13:53:43 +02:00
Dr. Stefan Schimanski 9a34eeed0f Remove net.ipv4.tcp_max_syn_backlog from sysctl whitelist
This is not namespaced in today's kernels.
2016-09-05 13:04:19 +02:00
Kubernetes Submit Queue 921ab5070f Merge pull request #32062 from gmarek/gc_timeout
Automatic merge from submit-queue

Increase GC timeout for RCs bigger than 40k

cc @caesarxuchao
2016-09-05 03:45:30 -07:00
gmarek bac603afd6 Sleep between NodeStatus update retries 2016-09-05 12:29:28 +02:00
gmarek d990720c12 Increase GC timeout for RCs bigger than 40k 2016-09-05 12:08:04 +02:00
Kubernetes Submit Queue 2352464853 Merge pull request #32063 from gmarek/load
Automatic merge from submit-queue

Add few more logs to the Load test

Useful to debug enormous-cluster failures.
2016-09-05 02:22:56 -07:00
gmarek 41e8f10d78 Add few more logs to the Load test 2016-09-05 10:34:30 +02:00
Kubernetes Submit Queue a95dea4147 Merge pull request #32061 from gmarek/constraints
Automatic merge from submit-queue

Increase the threshold for apiserver CPU for 500 node kubemark

Fix #32059
2016-09-05 01:29:48 -07:00
gmarek 4051a2f8ea Increase the threshold for apiserver CPU for 500 node kubemark 2016-09-05 09:48:25 +02:00
Kubernetes Submit Queue 2cc5923ed6 Merge pull request #31974 from piosz/enable-rescheduler
Automatic merge from submit-queue

Enable Rescheduler by default

Rescheduler is stable - e2e test is passing constantly for >1week.

ref #29023

```release-note
Rescheduler which ensures that critical pods are always scheduled enabled by default in GCE.
```
2016-09-05 00:27:43 -07:00
Kubernetes Submit Queue 7f3ce7b320 Merge pull request #32012 from hongchaodeng/f
Automatic merge from submit-queue

Unshare cluster, store in each test suite

For https://github.com/kubernetes/kubernetes/issues/31962 and https://github.com/kubernetes/kubernetes/issues/31300.

Just try to unshare it to minimize interface and focus on correctness of logic.
2016-09-05 00:09:39 -07:00
Kubernetes Submit Queue f6fe7c3ea7 Merge pull request #32052 from ivan4th/allow-ip-addresses-to-be-used-as-node-names
Automatic merge from submit-queue

Allow IP addresses to be used as node names

Fixes #32050

In `pkg/api/validation/validation.go`, there's already `ValidateNodeName()`, so using `ValidateDNS1123Label()` was ujustified. Also, it broke service endpoints in `hack/local-up-cluster.sh` and some other software that doesn't want to do extra work to provide resolvable hostnames for the nodes of test clusters, e.g.
https://github.com/metral/nanokube
https://github.com/sttts/kubernetes-dind-cluster
And probably others.

On affected installs, service latency e2e test hangs, see e.g. https://github.com/kubernetes/kubernetes/issues/30632#issuecomment-244431797

DNS1123Label suggestion is by @thockin, see [here](https://github.com/kubernetes/kubernetes/pull/30301#issuecomment-239602268). I think it's wrong though for aforementioned reasons :(

PR that broke node names: #31311
2016-09-04 21:49:49 -07:00
Ivan Shvedunov 1c9ee74987 Allow IP addresses to be used as node names
Fixes #32050
2016-09-05 02:37:00 +03:00
Kubernetes Submit Queue aee6d10b57 Merge pull request #31848 from YuPengZTE/devTest
Automatic merge from submit-queue

 The first letter should be small in errors.New

<!--  Thanks for sending a pull request!  Here are some tips for you:
1. If this is your first time, read our contributor guidelines https://github.com/kubernetes/kubernetes/blob/master/CONTRIBUTING.md and developer guide https://github.com/kubernetes/kubernetes/blob/master/docs/devel/development.md
2. If you want *faster* PR reviews, read how: https://github.com/kubernetes/kubernetes/blob/master/docs/devel/faster_reviews.md
3. Follow the instructions for writing a release note: https://github.com/kubernetes/kubernetes/blob/master/docs/devel/pull-requests.md#release-notes
-->

**What this PR does / why we need it**:

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #

**Special notes for your reviewer**:

**Release note**:
<!--  Steps to write your release note:
1. Use the release-note-* labels to set the release note state (if you have access) 
2. Enter your extended release note in the below block; leaving it blank means using the PR title as the release note. If no release note is required, just write `NONE`. 
-->
```release-note
```
2016-09-04 15:31:30 -07:00
Clayton Coleman 13adc63bff
generated DeepCopy without a function on a struct pointer is wrong
in and out are both pointers to pointers, so *in has to be cast to
*Type, not Type.
2016-09-04 15:26:02 -04:00
guangxuli b7a5fc9942 const string testQuantityFlag no longer use 2016-09-04 20:37:32 +08:00