Commit Graph

636 Commits (00dd32b1672b4c589ba2b53fe551e3889aeec1aa)

Author SHA1 Message Date
Dr. Stefan Schimanski e3a3d108fb Fixup after k8s.io/{kube-gen -> code-generator} rename 2017-08-17 17:55:12 +02:00
Kubernetes Submit Queue ccc40f49ee Merge pull request #49342 from RenaudWasTaken/protobufapionly
Automatic merge from submit-queue (batch tested with PRs 49342, 50581, 50777)

Device Plugin Protobuf API

**What this PR does / why we need it:**
This implements the Device Plugin API

- Design document: kubernetes/community#695
- PR tracking: [kubernetes/features#368](https://github.com/kubernetes/features/issues/368#issuecomment-321625420)

Special notes for your reviewer:

First proposal submitted to the community repo, please advise if something's not right with the format or procedure, etc.
@vishh @derekwaynecarr

**Release note:**
```
NONE
```
2017-08-16 23:08:08 -07:00
Jeffrey Regan dbc22ad6fd Remove kubectl's dependence on schema file in pkg/api/validation.
**What this PR does / why we need it**:

Makes functions in validation/schema.go private to kubectl,
further isolating kubectl.

**Which issue this PR fixes**

Part of a series of PRs to address kubernetes/community#598

**Release note**:
```release-note
NONE
```
2017-08-16 16:38:28 -07:00
Kubernetes Submit Queue 4032896ef1 Merge pull request #41901 from soltysh/cronjobs_beta
Automatic merge from submit-queue

Promote CronJobs to batch/v1beta1 - just the API

This PR promotes CronJobs to beta.

@erictune @kubernetes/sig-apps-api-reviews @kubernetes/api-approvers ptal

This builds on top of #41890 and needs #40932 as well

```release-note
Promote CronJobs to batch/v1beta1.
```
2017-08-16 15:59:46 -07:00
Maciej Szulik 43b8715d82
Promote CronJobs to batch/v1beta1 2017-08-16 08:42:21 +02:00
Dr. Stefan Schimanski f763fdc3c1 Make kube::util::ensure_clean_working_dir more verbose in log files 2017-08-16 08:31:07 +02:00
Renaud Gaubert 4971cbfe14 Added script to verify the generated Device Plugin API
Signed-off-by: Renaud Gaubert <rgaubert@nvidia.com>
2017-08-15 14:59:42 -07:00
Renaud Gaubert e6a210ca1b Added script to generate the Device Plugin API
Signed-off-by: Renaud Gaubert <rgaubert@nvidia.com>
2017-08-15 14:59:42 -07:00
Kubernetes Submit Queue a12cf94432 Merge pull request #50500 from shiywang/sortby
Automatic merge from submit-queue (batch tested with PRs 50302, 50573, 50500, 50633, 50617)

add cmd-test for sort-by command

this follow up : https://github.com/kubernetes/kubernetes/pull/48659
/assign @pwittrock 
as your suggestion, cmd-test added, ptal

```release-note
NONE
```
2017-08-14 20:42:20 -07:00
Jeff Grafton a7f49c906d Use buildozer to delete licenses() rules except under third_party/ 2017-08-11 09:32:39 -07:00
Shiyang Wang 1010916c1a add cmd-test for sort-by command 2017-08-11 15:53:31 +08:00
Jordan Liggitt dd7be70a4a
Add rbac.authorization.k8s.io/v1 2017-08-09 17:04:54 -04:00
Kubernetes Submit Queue f9f43143a4 Merge pull request #46193 from cblecker/staging-godeps-dockerized
Automatic merge from submit-queue (batch tested with PRs 43443, 46193, 49071, 47252)

Run the update-staging-godeps script inside a docker container

**What this PR does / why we need it**:
This PR moves the update-staging-godeps script to run inside a docker container.

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

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```

/assign @ixdy @sttts
2017-07-25 21:52:48 -07:00
Kubernetes Submit Queue 66a1ae38ea Merge pull request #43443 from irfanurrehman/kubefed-doc-1
Automatic merge from submit-queue (batch tested with PRs 43443, 46193, 49071, 47252)

[Federation][Kubefed] Support reference document autogeneration for kubefed

This PR is needed to address the documentation issue https://github.com/kubernetes/kubernetes.github.io/issues/2888

Apart from the code auto generation have updated some descriptions for consistency.

**Special notes for your reviewer**:
@kubernetes/sig-federation-misc 
cc @madhusudancs @csbell  

**Release note**:

```NONE
```
2017-07-25 21:52:45 -07:00
Christoph Blecker 2ee8983daf
Dockerize update-staging-godeps 2017-07-25 12:26:57 -07:00
Christoph Blecker 26491cef81
Simplify output of ensure_godep_version 2017-07-25 12:11:06 -07:00
Christoph Blecker 499d6da965
Bump required golang version to 1.8 2017-07-25 12:11:03 -07:00
Dr. Stefan Schimanski 263b918541 hack/update-staging-godep.sh: check for staging repos in GOPATH 2017-07-24 10:44:42 +02:00
Kubernetes Submit Queue 22cc294364 Merge pull request #46598 from xiangpengzhao/fix-kubectl-version
Automatic merge from submit-queue (batch tested with PRs 46210, 48607, 46874, 46598, 49240)

Make "kubectl version" json format output more readable.

**What this PR does / why we need it**:
##39858 adds a flag --output to `kubectl version`, but the json format output is displayed in one line. It's not so readable. This PR fixes it.

and

- adds a shorthand for `output`
- ~~refactors that: if `--short` is specified, `--output` will be ignored~~

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

**Special notes for your reviewer**:
/cc @php-coder @alejandroEsc 

**Release note**:

```release-note
NONE
```
2017-07-21 17:00:21 -07:00
Kubernetes Submit Queue ae1ff1a2d4 Merge pull request #48746 from janetkuo/apps-v1beta2
Automatic merge from submit-queue

Add a new API version apps/v1beta2

xref: #49135
This PR adds a new API version `apps/v1beta2` which contains a copy (of types, conversions, and defaults) of `apps/v1beta1` StatefulSet, Deployment, and their subresources. Note that `apps/v1beta2` is still WIP and we will make breaking changes to it before releasing 1.8.

Moving core controllers (StatefulSet, Deployment, ReplicaSet, DaemonSet) to `apps/v1beta2` is the first step of moving them to `apps/v1` (GA). 

This PR is a starting point for DaemonSet and ReplicaSet to move from `/extensions` to `/apps` and for Deployment and StatefulSet to make some breaking changes (e.g. new defaults and/or remove deprecated fields).

```release-note
Add a new API version apps/v1beta2
```
2017-07-21 11:47:21 -07:00
Kubernetes Submit Queue ab6f1f0da1 Merge pull request #48708 from bmwiedemann/date
Automatic merge from submit-queue (batch tested with PRs 49222, 49333, 48708, 49337)

Allow to override build date

See https://reproducible-builds.org/ for why this is good
and https://reproducible-builds.org/specs/source-date-epoch/
for the definition of this variable.

Background: issue #48710
when trying to build the kubernetes package
for the openSUSE Linux distribution
```
/usr/bin/hyperkube
/usr/bin/kubeadm
/usr/src/kubernetes/platforms/linux/amd64/e2e.test
```
had a date+time string embedded in them in the format
2018-08-15T19:08:34Z

which meant that each build produced new binaries
even when nothing actually changed.
Those then had to be synced to mirrors, wasting their and our users' bandwidth.
2017-07-20 23:01:21 -07:00
Janet Kuo 767082e8e9 Add new API version apps/v1beta2
Add a new API version apps/v1beta2 and enable it by default.
apps/v1beta2 has a copy of apps/v1beta1 types, except for
ControllerRevision.
2017-07-20 10:25:21 -07:00
Kubernetes Submit Queue 9e5eb70d55 Merge pull request #46862 from dims/respect-build-platform-env-var
Automatic merge from submit-queue (batch tested with PRs 49083, 45540, 46862)

Respect KUBE_BUILD_PLATFORMS set by user

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

Currently the only(?) toggle available for custom arch builds is
KUBE_FASTBUILD. We should allow the user to specify a list
of arch(es) in the environment variable KUBE_BUILD_PLATFORMS.

Example:
KUBE_BUILD_PLATFORMS="linux/amd64 linux/arm64" hack/build-cross.sh

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

Fixes #20365

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2017-07-19 21:18:27 -07:00
Kubernetes Submit Queue 5a3cc4fab6 Merge pull request #49083 from sakeven/fix/golang_version_check
Automatic merge from submit-queue (batch tested with PRs 49083, 45540, 46862)

update golang version to go1.8

Signed-off-by: sakeven <jc5930@sina.cn>



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

There are some code breaking the compatibility with golang 1.6. Now kubernetes only support golang 1.8.
We need to update golang version check script.

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

**Special notes for your reviewer**:

**Release note**:

```
NONE
```
2017-07-19 21:18:23 -07:00
Kubernetes Submit Queue 8d26afa8a6 Merge pull request #48377 from bsalamat/priority_class
Automatic merge from submit-queue

Add PriorityClass API object under new "scheduling" API group

**What this PR does / why we need it**: This PR is a part of a series of PRs to add pod priority to Kubernetes. This PR adds a new API group called "scheduling" with a new API object called "PriorityClass". PriorityClass maps the string value of priority to its integer value.

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

**Special notes for your reviewer**: Given the size of this PR, I will add the admission controller for the PriorityClass in a separate PR.

**Release note**:

```release-note
Add PriorityClass API object under new "scheduling" API group
```

ref/ #47604
ref/ #48646
2017-07-19 19:04:29 -07:00
Davanum Srinivas 476e816107 Respect KUBE_BUILD_PLATFORMS set by user
Currently the only(?) toggle available for custom arch builds is
KUBE_FASTBUILD. We should allow the user to specify a list
of arch(es) in the environment variable KUBE_BUILD_PLATFORMS.

Example:
KUBE_BUILD_PLATFORMS="linux/amd64 linux/arm64" hack/build-cross.sh

Fixes #20365
2017-07-19 20:00:39 -04:00
Kubernetes Submit Queue 3fb2d8248d Merge pull request #48964 from ixdy/switch-to-kazel
Automatic merge from submit-queue

Switch from gazel to kazel

**What this PR does / why we need it**: switches to `kazel`, where all new development will be focused. Part of the effort for switching from `gazel` to `gazelle`.

I'm imagining that we'll use `kube::util::go_install_from_commit` to version `gazelle` as well.

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

**Release note**:

```release-note
NONE
```

/release-note-none
/assign @mikedanese @spxtr
2017-07-19 13:31:24 -07:00
Bernhard M. Wiedemann cd0e7b9e17 Allow to override build date
See https://reproducible-builds.org/ for why this is good
and https://reproducible-builds.org/specs/source-date-epoch/
for the definition of this variable.
2017-07-19 13:27:13 +02:00
Kubernetes Submit Queue 164cae1151 Merge pull request #46755 from CaoShuFeng/cani-test-cmd
Automatic merge from submit-queue (batch tested with PRs 49120, 46755, 49157, 49165, 48950)

add cmd test for kubectl auth can-i

**Release note**:

```
NONE
```
2017-07-19 00:06:23 -07:00
Bobby Salamat 33e6a476ba Add PriorityClass API
Add PriorityClass to pkg/registry

Add PriorityClass to pkg/master/master.go

Add PriorityClass to import_know_versions.go

Update linted packages

minor fix
2017-07-18 17:47:57 -07:00
Jeff Grafton 9ac0950166 Add utility function to install go package at a particular commit 2017-07-18 12:48:02 -07:00
sakeven e6d2d726ed update golang version to go1.8
Signed-off-by: sakeven <jc5930@sina.cn>
2017-07-18 14:11:28 +08:00
xiangpengzhao a6be3b64f8 Make "kubectl version" json output more readable. 2017-07-18 11:21:35 +08:00
Dr. Stefan Schimanski 918721078f godep-save.sh: add sanity checks 2017-07-07 21:16:34 +02:00
Tim Hockin a0db287299 Merge pull request #47934 from wlan0/master
enable docs and man page autogeneration for cloud-controller-manager
2017-06-30 16:58:08 -07:00
Kubernetes Submit Queue e4af9dccb0 Merge pull request #46923 from dims/nuke-wrapper-go-flags
Automatic merge from submit-queue (batch tested with PRs 47921, 45984, 46829, 46896, 46923)

Remove unnecessary wrapper flags

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

Drop KUBE_GOFLAGS, KUBE_GOGCFLAGS, KUBE_GOLDFLAGS references
from the build infrastructure

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

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2017-06-22 20:26:29 -07:00
Kubernetes Submit Queue a509cbf919 Merge pull request #46829 from cblecker/swagger-dir-fix
Automatic merge from submit-queue (batch tested with PRs 47921, 45984, 46829, 46896, 46923)

Create output_dir if doesn't exist

**What this PR does / why we need it**:
Minor fix to the swagger spec gen, that if the directory doesn't exist, create it before copying.

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

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2017-06-22 20:26:24 -07:00
wlan0 38b060c4fd enable docs and man page autogeneration for cloud-controller-manager 2017-06-22 17:04:26 -07:00
Chao Xu 0a853fec93 hack/lib/init.sh util.sh update-codegen.sh 2017-06-22 11:30:57 -07:00
Davanum Srinivas 5b3c3665f3 Remove timestamps from docs/api-reference/*/*.html
If there are 2 or more PR(s) in the queue, they will end up with
conflicts (and rechecks). So let us remove the timestamp entirely
when we generate the files.

Fixes #46814
2017-06-19 21:41:38 -04:00
Jeff Grafton 64bd79fad7 Convert go_binary linkstamp to x_defs 2017-06-08 14:59:55 -07:00
Davanum Srinivas 823e26ddbf Remove unnecessary wrapper flags
Drop KUBE_GOFLAGS, KUBE_GOGCFLAGS, KUBE_GOLDFLAGS references
from the build infrastructure. There are some usages still
for KUBE_GOFLAGS, so we should print a deprecation message
until all those are fixed. If both KUBE_GOFLAGS and GOFLAGS
are just then we just bail out.
2017-06-07 12:31:01 -04:00
Dr. Stefan Schimanski 33e50da9f4 Rename {kube- ->}apiextensions-{-> api}server 2017-06-06 12:06:31 +02:00
Irfan Ur Rehman bc9852fca4 [Federation][Kubefed] Support documentation for kubefed and its sub commands 2017-06-03 17:11:36 +05:30
Cao Shufeng c28efb85ff add cmd test for kubectl auth can-i 2017-06-03 17:01:00 +08:00
Kubernetes Submit Queue e837c3bbc2 Merge pull request #46388 from lavalamp/whitlockjc-generic-webhook-admission
Automatic merge from submit-queue (batch tested with PRs 46239, 46627, 46346, 46388, 46524)

Dynamic webhook admission control plugin

Unit tests pass.

Needs plumbing:
* [ ] service resolver (depends on @wfender PR)
* [x] client cert (depends on ????)
* [ ] hook source (depends on @caesarxuchao PR)

Also at least one thing will need to be renamed after Chao's PR merges.

```release-note
Allow remote admission controllers to be dynamically added and removed by administrators.  External admission controllers make an HTTP POST containing details of the requested action which the service can approve or reject.
```
2017-06-02 23:37:42 -07:00
Christoph Blecker f75274e04e
Create output_dir if doesn't exist 2017-06-01 23:09:14 -07:00
Jeremy Whitlock 83d3d59ce0 add "install" package for admission API group
To properly register the types in the admission API group we need to
create an "install" package and wire it up.  This is required by the
webhook admission controller being developed as part of
https://github.com/kubernetes/community/pull/132
2017-05-31 11:41:10 -07:00
Clayton Coleman 3f41f8fcd1
Add priority and condition to column definitions
Allow the server to indicate additional information along with each row
and table.
2017-05-29 18:23:48 -04:00
Dan Winship 0683e55fc1 Add networking.k8s.io v1 API, with NetworkPolicy 2017-05-28 10:11:01 -04:00
Chao Xu bc9b305f17 generated clients 2017-05-26 00:03:53 -07:00
Wojciech Tyczynski 97b6701ea1 Get rid of patched version of Go 1.8.1 2017-05-25 20:05:34 +02:00
Jeremy Whitlock 1b59dd887d add "admission" API group
This commit is an initial pass at providing an admission API group.
The API group is required by the webhook admission controller being
developed as part of https://github.com/kubernetes/community/pull/132
and could be used more as that proposal comes to fruition.
2017-05-19 10:17:37 -06:00
Wojciech Tyczynski 3a1bb09ea9 Patch golang 2017-05-16 21:29:22 +02:00
deads2k ed27887ad2 wire new staging repo 2017-05-02 08:43:31 -04:00
Timothy St. Clair 01366851ea Prune k8petstore from examples and e2es per discussion on sig-testing 2017-04-28 11:49:23 -05:00
Kubernetes Submit Queue 549bd4b7d5 Merge pull request #44591 from ixdy/bazel-push-build
Automatic merge from submit-queue (batch tested with PRs 44591, 44549)

Update repo-infra bazel dependency and use new gcs_upload rule

This PR provides similar functionality to push-build.sh entirely within Bazel rules (though it relies on gsutil).

It's an alternative to #44306.

Depends on https://github.com/kubernetes/repo-infra/pull/13.

**Release note**:

```release-note
NONE
```
2017-04-27 10:54:56 -07:00
Lucas Käldström 6b5d5371d9
Bump to go1.8.1 and remove the edge GOROOT 2017-04-25 23:45:47 +03:00
Jeff Grafton a9bfae8ec3 Update repo-infra bazel dependency and use new gcs_upload rule 2017-04-25 13:45:28 -07:00
Matthew Wong 04241a673d Do etcd semver validation using posix only 2017-04-12 12:44:07 -04:00
Matthew Wong 36d244f084 Fix etcd semver validation by using 'sort -V' 2017-04-11 14:19:30 -04:00
Kubernetes Submit Queue b9a5a5c9b3 Merge pull request #42748 from dcbw/cfssl-localup
Automatic merge from submit-queue (batch tested with PRs 43866, 42748)

hack/cluster: download cfssl if not present

hack/local-up-cluster.sh uses cfssl to generate certificates and
will exit it cfssl is not already installed.  But other cluster-up
mechanisms (GCE) that generate certs just download cfssl if not
present.  Make local-up-cluster.sh do that too so users don't have
to bother installing it from somewhere.
2017-04-10 14:27:11 -07:00
Christoph Blecker 4c2985e144
Update gen_api_ref_docs to use same diff method as verify 2017-04-05 13:06:35 -07:00
Kubernetes Submit Queue 7e18392f16 Merge pull request #43671 from k82cn/skip_e2e_4_mac
Automatic merge from submit-queue

Skip e2e test for Mac.

fixes #36792
2017-04-04 18:27:25 -07:00
Dan Williams f20437a822 hack/cluster: download cfssl if not present
hack/local-up-cluster.sh uses cfssl to generate certificates and
will exit it cfssl is not already installed.  But other cluster-up
mechanisms (GCE) that generate certs just download cfssl if not
present.  Make local-up-cluster.sh do that too.
2017-04-03 23:31:16 -05:00
Dan Williams b3705b6e35 hack/cluster: consolidate cluster/ utils to hack/lib/util.sh
Per Clayton's suggestion, move stuff from cluster/lib/util.sh to
hack/lib/util.sh.  Also consolidate ensure-temp-dir and use the
hack/lib/util.sh implementation rather than cluster/common.sh.
2017-03-30 22:34:46 -05:00
Alejandro Escobar a5e6dcb434 addressing issue #39427 adding a flag --output to allow for either json or yaml.
updating with PR changes requested.

latest changes to having short for human readable only, and error cases moved a bit to the end.

rebase fixes

latest pr. changes.

small change moving return nil out of switch.

updated the nil check for the error in the humanreadable case.

more optimization in humanreadable code.

pushed up current test changes, this is purely temporary

finished writing tests

updated test and function names.

changed output extensions from .sh to output.

updated version, version struct now just called Version and not VersionObj.

made a few changes to testing.

fixed testing issues, created better test and cleanup

go format change.
2017-03-28 10:07:53 -07:00
Klaus Ma c6e79167f4 Skip e2e test for Mac. 2017-03-28 11:40:40 +08:00
Kubernetes Submit Queue 6d2defbc09 Merge pull request #42967 from cblecker/godep-version79
Automatic merge from submit-queue (batch tested with PRs 40964, 42967, 43091, 43115)

Update hack scripts to use godep v79 and ensure_godep_version

**What this PR does / why we need it**:
Based on #42965 and https://github.com/kubernetes/kubernetes/pull/42958#discussion_r105568318, this pins the godep version at v79, which should fix some issues when running godep in go1.8 local environments.

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

**Special notes for your reviewer**:
This should likely get the v1.6 milestone so that it can be merged into master. While I'm setting a default godep version, I'm continuing to use the local pins per this comment: https://github.com/kubernetes/kubernetes/pull/42965#issuecomment-285962723 .

**Release note**:

```release-note
NONE
```

cc: @sttts
2017-03-15 16:08:25 -07:00
Christoph Blecker 4d85a54027
Change verify-godeps.sh use ensure_godep_version 2017-03-15 10:32:44 -07:00
Christoph Blecker d31a88fee7
Bump godep version to v79 2017-03-15 10:32:37 -07:00
Kubernetes Submit Queue 5e29e1ee05 Merge pull request #42623 from liggitt/kubectl-version
Automatic merge from submit-queue

Fix v0.0.0 in kubectl built from master

Fixes https://github.com/kubernetes/kubernetes/issues/40813
2017-03-13 15:06:31 -07:00
Kubernetes Submit Queue 72c94b1aa8 Merge pull request #42728 from sttts/sttts-udpate-all-dirty-checkout
Automatic merge from submit-queue

Don't try to run hack/verify-staging-* on dirty repository

When the repo is dirty after running all `update-*` scripts in `hack/update-all.sh`, the staging verify scripts still fail. This PR removes these from `hack/update-all.sh`. Instead give useful instructions or continue automatically with `hack/update-all-staging.sh`.
2017-03-09 05:09:44 -08:00
Dr. Stefan Schimanski c128e4686a Don't try to run hack/verify-staging-* on dirty repository 2017-03-09 13:05:31 +01:00
Jordan Liggitt 2d06607885
Fix v0.0.0 in kubectl built from master 2017-03-07 01:09:57 -05:00
Kubernetes Submit Queue 79883dc48d Merge pull request #42070 from luxas/remove_kube_discovery
Automatic merge from submit-queue

Remove the kube-discovery binary from the tree

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

kube-discovery was a temporary solution to implementing proposal: https://github.com/kubernetes/community/blob/master/contributors/design-proposals/bootstrap-discovery.md

However, this functionality is now gonna be implemented in the core for v1.6 and will fully replace kube-discovery:
 - https://github.com/kubernetes/kubernetes/pull/36101 
 - https://github.com/kubernetes/kubernetes/pull/41281
 - https://github.com/kubernetes/kubernetes/pull/41417

So due to that `kube-discovery` isn't used in any v1.6 code, it should be removed.
The image `gcr.io/google_containers/kube-discovery-${ARCH}:1.0` should and will continue to exist so kubeadm <= v1.5 continues to work.

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

**Special notes for your reviewer**:

**Release note**:

```release-note
Remove cmd/kube-discovery from the tree since it's not necessary anymore
```
@jbeda @dgoodwin @mikedanese @dmmcquay @lukemarsden @errordeveloper @pires
2017-03-04 12:58:23 -08:00
Clayton Coleman 4e7c10a520
Don't bypass filter on generic output
It is inconsistent and confusing (filtering is orthogonal from output)
and we don't want to regress behavior from 1.5.
2017-03-02 15:58:22 -05:00
Kubernetes Submit Queue e9d34a692d Merge pull request #42309 from cblecker/godep-race
Automatic merge from submit-queue (batch tested with PRs 42128, 42064, 42253, 42309, 42322)

Fix godep race in local builds

**What this PR does / why we need it**:
This fixes a small race condition when building a godep version other than the latest. As you're building godep once, and then building it again after checkout, this can cause inconsistency in the version selected for use. This fix tells the first `go get` to only download and not build. Then we build manually after checking out the target version.

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

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2017-03-02 05:00:54 -08:00
Jan Safranek 584b57b8b4 Add storage.k8s.io/v1 2017-03-02 08:55:25 +01:00
Jess Frazelle fe84363ce2
Add settings API and admission controller
export functions from pkg/api/validation

add settings API

add settings to pkg/registry

add settings api to pkg/master/master.go

add admission control plugin for pod preset

add new admission control plugin to kube-apiserver

add settings to import_known_versions.go

add settings to codegen

add validation tests

add settings to client generation

add protobufs generation for settings api

update linted packages

add settings to testapi

add settings install to clientset

add start of e2e

add pod preset plugin to config-test.sh

Signed-off-by: Jess Frazelle <acidburn@google.com>
2017-03-01 13:04:28 -08:00
Christoph Blecker fa135fa4a6
Fix godep race in local builds 2017-02-28 20:17:55 -08:00
Kubernetes Submit Queue 7d510f2681 Merge pull request #41160 from pipejakob/webhooksigner-pr
Automatic merge from submit-queue (batch tested with PRs 42058, 41160, 42065, 42076, 39338)

New command for stand-alone GKE certificates controller

New stand-alone certificates controller for GKE. Rather than requiring the CA's private key on disk, this allows making external calls to GKE in order to sign cluster certificates.
    
**Which issue this PR fixes**: fixes #39761

**Release note**:

```release-note
New GKE certificates controller.
```

CC @mikedanese @jcbsmpsn
2017-02-27 01:29:59 -08:00
Kubernetes Submit Queue 8124705c81 Merge pull request #41987 from sttts/sttts-verify-staging-client-go-unify-with-copy-sh
Automatic merge from submit-queue (batch tested with PRs 42044, 41694, 41927, 42050, 41987)

Simplify and fix hack/{verify,update}-staging-{client-go,godeps}.sh

- merge `hack/{verify,update}-staging-client-go.sh`
- pin godep with shared code
- remove godep-restore completely from the process and replace with a simple check that godeps are restored
- add safety check in `staging/copy.sh` that there is no lingering `k8s.io/apimachinery` in the GOPATH which would lead to inconsistent client-go builds (!)
- check that all these scripts only operate in a clean working dir.
2017-02-26 23:16:56 -08:00
Kubernetes Submit Queue 0bc16d8966 Merge pull request #40576 from nikhiljindal/kubectlcascDel
Automatic merge from submit-queue (batch tested with PRs 41994, 41969, 41997, 40952, 40576)

Updating kubectl to send delete requests with orphanDependents=false if --cascade is true

Ref https://github.com/kubernetes/kubernetes/issues/40568 #38897

Updating kubectl to always set `DeleteOptions.orphanDependents=false` when deleting a resource with `--cascade=true`.
This is primarily for federation where we want to use server side cascading deletion.

Impact on kubernetes: kubectl will do another GET after sending a DELETE and wait till the resource is actually deleted. This can have an impact if the resource has a finalizer. kubectl will wait till the finalizer is removed and then the resource is deleted, which is the right thing to do but a notable change in behavior.

cc @caesarxuchao @lavalamp @smarterclayton @kubernetes/sig-federation-pr-reviews @kubernetes/sig-cli-pr-reviews
2017-02-26 12:58:01 -08:00
Dr. Stefan Schimanski dd9219f304 update-staging-{client-go,godeps}.sh: no godep-restore, pin godep, check workdir 2017-02-25 22:38:23 +01:00
Jacob Beacham 0d7a6eb058 New command: gke-certificates-controller
This adds a new stand-alone certificates controller for use on GKE. It
allows calling GKE to sign certificates instead of requiring the CA
private key locally.

It does not aim for 100% feature parity with kube-controller-manager
yet, so for instance, leader election support is omitted.
2017-02-24 14:35:32 -08:00
Lucas Käldström c4e989f51c
Remove the kube-discovery binary from the tree 2017-02-24 21:23:26 +02:00
nikhiljindal b6e2a09c2b Add cascading deletion test cases to kubectl tests 2017-02-23 12:04:13 -08:00
Aaron Crickenberger 57170100a0 avoid ls'ing third_party/etcd
third_party/etcd isn't guaranteed to be present, this was causing
the script to fail prior to printing out the error message about
version mismatch

fixes #41989
2017-02-23 11:11:31 -08:00
Wojciech Tyczynski a7d2136ce1 Update etcd to 3.0.17 in integration tests 2017-02-23 10:08:50 +01:00
Phillip Wittrock 93ea01663f Move .generated_docs to docs/ so docs OWNERS can review / approve 2017-02-16 10:11:57 -08:00
deads2k 1d40c3ff76 update scripts for new kube-aggregator location 2017-02-14 14:16:59 -05:00
Kubernetes Submit Queue f9215e8fb3 Merge pull request #41058 from liggitt/v1-tokenreview
Automatic merge from submit-queue (batch tested with PRs 41112, 41201, 41058, 40650, 40926)

Promote TokenReview to v1

Peer to https://github.com/kubernetes/kubernetes/pull/40709

We have multiple features that depend on this API:

- [webhook authentication](https://kubernetes.io/docs/admin/authentication/#webhook-token-authentication)
- [kubelet delegated authentication](https://kubernetes.io/docs/admin/kubelet-authentication-authorization/#kubelet-authentication)
- add-on API server delegated authentication

The API has been in use since 1.3 in beta status (v1beta1) with negligible changes:
- Added a status field for reporting errors evaluating the token

This PR promotes the existing v1beta1 API to v1 with no changes

Because the API does not persist data (it is a query/response-style API), there are no data migration concerns.

This positions us to promote the features that depend on this API to stable in 1.7

cc @kubernetes/sig-auth-api-reviews @kubernetes/sig-auth-misc

```release-note
The authentication.k8s.io API group was promoted to v1
```
2017-02-10 01:40:44 -08:00
Kubernetes Submit Queue 45d122dd6b Merge pull request #36033 from DirectXMan12/feature/hpa-v2
Automatic merge from submit-queue (batch tested with PRs 40796, 40878, 36033, 40838, 41210)

HPA v2 (API Changes)

**Release note**:
```release-note
Introduces an new alpha version of the Horizontal Pod Autoscaler including expanded support for specifying metrics.
```

Implements the API changes for kubernetes/features#117.

This implements #34754, which is the new design for the Horizontal Pod Autoscaler.  It includes improved support for custom metrics (and/or arbitrary metrics) as well as expanded support for resource metrics.  The new HPA object is introduces in the API group "autoscaling/v1alpha1".

Note that the improved custom metric support currently is limited to per pod metrics from Heapster -- attempting to use the new "object metrics" will simply result in an error.  This will change once #34586 is merged and implemented.
2017-02-10 00:04:48 -08:00
Kubernetes Submit Queue 2bd777e9de Merge pull request #40502 from alindeman/etcd-false-positive
Automatic merge from submit-queue (batch tested with PRs 41121, 40048, 40502, 41136, 40759)

Match etcd process name exactly

A process named, e.g., etcd-operator, should not match



**What this PR does / why we need it**: Matches etcd process name exactly 

**Which issue this PR fixes**: fixes #40499 

**Special notes for your reviewer**: 👀 @lavalamp
2017-02-09 14:27:47 -08:00
Solly Ross 86c430b881 Introduce HPA v2 API Objects
This commit introduces the autoscaling/v2alpha1 API group, which
currently contains the first alpha of the new HorizontalPodAutoscaler
object.
2017-02-07 17:20:14 -05:00
Jordan Liggitt 09b5d7279f
install authentication.k8s.io/v1, add tests 2017-02-07 01:44:56 -05:00
Jordan Liggitt 8706bc9617
install authorization.k8s.io/v1, add tests
Use specific v1beta1 Authorization client

Add client expansions
2017-02-06 18:16:51 -05:00
Kubernetes Submit Queue 25de8ef641 Merge pull request #40551 from juanvallejo/jvallejo/only-output-no-resources-found-for-human-readable-printer
Automatic merge from submit-queue (batch tested with PRs 40691, 40551, 40683, 40700, 40702)

only output "No resources found." for human readable printers

**Release note**:
```release-note
release note none
```

This patch removes the message `No resources found` (currently printed through stderr) when printing through a generic / non-human-readable printer (json, yaml, jsonpath, custom-columns).

**Before***
```
$ kubectl get pods -o json
No resources found.
{
    "apiVersion": "v1",
    "items": [],
    "kind": "List",
    "metadata": {},
    "resourceVersion": "",
    "selfLink": ""
}
```

**After**
```
$ kubectl get pods -o json
{
    "apiVersion": "v1",
    "items": [],
    "kind": "List",
    "metadata": {},
    "resourceVersion": "",
    "selfLink": ""
}
```

cc @fabianofranz @stevekuznetsov
2017-01-30 19:14:41 -08:00
Lucas Käldström 6789d4e637
Workaround that we have two GOROOTs; we have to set the path for the go executable to EDGE_GOROOT/bin/go when using the edge version 2017-01-27 20:31:17 +02:00
juanvallejo 5ec2a4c3ca only output "No resources found." for human readable printers 2017-01-27 13:30:23 -05:00
Lucas Käldström 04bc44acf9
Remove the patched golang from the kube-cross image and upgrade to go1.8rc1 for arm and ppc64le instead. Reenable the ppc64le builds 2017-01-27 20:03:37 +02:00
Andy Lindeman 79d283896d
Match etcd process name exactly
A process named, e.g., etcd-operator, should not match
2017-01-25 22:52:37 -05:00
Jordan Liggitt a7f52b276f
Add test shell stack traces 2017-01-25 13:34:16 -05:00
Lucas Käldström 23d3451bfe
Add cloud-controller-manager to the CI/release builds 2017-01-20 10:51:36 +02:00
Mike Danese 96c146c8f2 promote certificates.k8s.io to beta 2017-01-19 13:13:20 -08:00
Kubernetes Submit Queue b29d9cdbcf Merge pull request #39898 from ixdy/bazel-release-tars
Automatic merge from submit-queue

Build release tars using bazel

**What this PR does / why we need it**: builds equivalents of the various kubernetes release tarballs, solely using bazel.

For example, you can now do
```console
$ make bazel-release
$ hack/e2e.go -v -up -test -down
```

**Special notes for your reviewer**: this is currently dependent on 3b29803eb5, which I have yet to turn into a pull request, since I'm still trying to figure out if this is the best approach.

Basically, the issue comes up with the way we generate the various server docker image tarfiles and load them on nodes:
* we `md5sum` the binary being encapsulated (e.g. kube-proxy) and save that to `$binary.docker_tag` in the server tarball
* we then build the docker image and tag using that md5sum (e.g. `gcr.io/google_containers/kube-proxy:$MD5SUM`)
* we `docker save` this image, which embeds the full tag in the `$binary.tar` file.
* on cluster startup, we `docker load` these tarballs, which are loaded with the tag that we'd created at build time. the nodes then use the `$binary.docker_tag` file to find the right image.

With the current bazel `docker_build` rule, the tag isn't saved in the docker image tar, so the node is unable to find the image after `docker load`ing it.

My changes to the rule save the tag in the docker image tar, though I don't know if there are subtle issues with it. (Maybe we want to only tag when `--stamp` is given?)

Also, the docker images produced by bazel have the timestamp set to the unix epoch, which is not great for debugging. Might be another thing to change with a `--stamp`.

Long story short, we probably need to follow up with bazel folks on the best way to solve this problem.

**Release note**:

```release-note
NONE
```
2017-01-18 14:24:48 -08:00
deads2k e74efe41a0 add rbac v1beta1 2017-01-18 09:49:33 -05:00
Clayton Coleman 5a5d31555b
Swagger doc generation needs to work on meta/v1 2017-01-17 16:17:19 -05:00
deads2k e100e8990b update generation bash to handle vendor dir 2017-01-17 09:06:34 -05:00
Jeff Grafton b9e060a630 Update scripts to look for binary artifacts in bazel-bin/ 2017-01-13 16:17:48 -08:00
Jeff Grafton bc4b6ac397 Build release tarballs in bazel and add `make bazel-release` rule 2017-01-13 16:17:44 -08:00
deads2k 98acd800da allow generated changes in readonly package 2017-01-11 08:37:03 -05:00
Kubernetes Submit Queue 609e3e3890 Merge pull request #39619 from deads2k/fed-20-rename
Automatic merge from submit-queue (batch tested with PRs 34488, 39511, 39619, 38342, 39491)

rename kubernetes-discovery to kube-aggregator

Rename `kubernetes-discovery` to `kube-aggregator`.  Move and bulk rename.

@kubernetes/sig-api-machinery-misc
2017-01-10 16:07:14 -08:00
deads2k 453651cbfc rename kubernetes-discovery to kube-aggregator 2017-01-10 12:27:42 -05:00
Dr. Stefan Schimanski 5a53dd859a Add hack/verify-readonly-packages 2017-01-09 17:25:16 +01:00
Tim Hockin 52c07683ef Merge pull request #39448 from bowei/remove-dns
Remove dns
2017-01-06 17:31:05 -08:00
Bowei Du 266bf80404 Remove kube-dns from golang.sh 2017-01-06 12:57:46 -08:00
Bowei Du 0992e2bfc9 Remove DNS code from the main repo (code is now in http://github.com/kubernetes/dns) 2017-01-06 12:57:45 -08:00
Jeff Grafton d5705a6f5f Generate a dummy BUILD file in _output/local/go to keep Bazel out of trouble 2017-01-05 22:05:17 -08:00
nikhiljindal 5424d50c03 Adding test-federation-cmd.sh to test kubectl with federation apiserver 2017-01-04 11:17:05 -08:00
Kubernetes Submit Queue e843f77c6a Merge pull request #38919 from brendandburns/fix
Automatic merge from submit-queue

Add a KUBERNETES_NODE_* section to build kubelet/kube-proxy for windows

@pires @ixdy 

Addresses https://github.com/kubernetes/kubernetes/issues/38785 (I hope)
2016-12-20 15:32:40 -08:00
deads2k 47073be356 create kuberentes-discovery image 2016-12-20 07:42:49 -05:00
Brendan Burns ab0e245bc6 Add a KUBERNETES_NODE_* section to build kubelet/kube-proxy for windows 2016-12-17 21:07:18 -08:00
Kubernetes Submit Queue 9a1c607673 Merge pull request #38713 from alejandroEsc/ae/localup1
Automatic merge from submit-queue (batch tested with PRs 37468, 36546, 38713, 38902, 38614)

local-up-cluster additions

**What this PR does / why we need it**:
Changes to local-cluster-up: These include: 1)  a simple additional help option. 2) additional error message to not being able to run `docker ps`. 3) fail faster when etcd is not found in path. Hopefully these make developing a bit more pleasant.

**Release note**:
```NONE
```
2016-12-16 18:55:32 -08:00
Madhusudan.C.S 6560825390 Bundle federation/develop directory in the test tarball for federation testing. 2016-12-16 11:10:16 -08:00
Alejandro Escobar 7d9c06f82d local-up-cluster changes: added help option, added error message for why docker ps fails and how to recover, added test to check if etcd is in your path to fail fast when not found.
from etcd.sh split the start process into validate fucntion + start function so that the validate piece can be reused elsewhere. the up-cluster script has been changed to remove duplicate docker logic to the one used in buid-tools/common.sh and the validate etcd function is now used here.

moved docker daemon check function to util.sh and made function name changes and upstream changes.
2016-12-16 07:41:35 -08:00
Jeff Grafton 27d096d27d Rename build-tools/ back to build/ 2016-12-14 13:42:15 -08:00
Dr. Stefan Schimanski 036df76242 make: don't preserve rsync time, conflicting with touch on generators 2016-12-13 15:12:45 +01:00
Kubernetes Submit Queue 74de0fdb63 Merge pull request #38135 from MHBauer/go-generate-flag-location
Automatic merge from submit-queue

goflags must be after subcommand

**What this PR does / why we need it**:
if GOFLAGS is set when calling make, kubernetes will fail to build

as an example, I often have `GOFLAGS=-v` so I can have some idea of progress during compilation

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

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2016-12-12 13:28:24 -08:00
deads2k 6421405d0e create hack/local-up-discovery.sh 2016-12-12 08:40:00 -05:00
deads2k bcb8d8b8bb extra discovery start and cert generation 2016-12-12 08:28:29 -05:00
Kubernetes Submit Queue 48cae78257 Merge pull request #36361 from ivan4th/build-container-rsync-optimizations
Automatic merge from submit-queue (batch tested with PRs 38277, 36361, 38452)

Add options for build container rsync optimization

KUBE_RSYNC_COMPRESS env var sets rsync compression level.
KUBE_RSYNC_GENERATED_TO_BUILD_CONTAINER env var disables rsyncing
generated files to build containers.

Why KUBE_RSYNC_COMPRESS is needed -- from rsync manual on `--compress` option (implied by non-zero `--compress-level`):
> Note that this option typically achieves better compression ratios than can be achieved by using a compressing remote shell or a compressing transport because it takes advantage of the implicit information in the matching data blocks that are not explicitly sent over  the connection.

Use case for `KUBE_RSYNC_GENERATED_TO_BUILD_CONTAINER`: when you sometimes build stuff locally (e.g. `make WHAT=cmd/kubectl`) and sometimes do it on remote docker (`build-tools/run.sh make WHAT=cmd/hyperkube`), local builds touch generated files which causes them to be rsynced to the build data container, which may slow down the builds. Still, I'm not sure whether local->remote rsync of generated files is useful (e.g. someone may want to edit generated files for debugging purposes?), so I made not rsyncing these files an option instead of forcing such behavior.
2016-12-11 13:02:53 -08:00
Lucas Käldström afefb19ac4 Fix the cross-build 2016-12-10 16:26:21 +02:00
Kubernetes Submit Queue 9e3fc8de9e Merge pull request #36050 from linux-on-ibm-z/master
Automatic merge from submit-queue (batch tested with PRs 37860, 38429, 38451, 36050, 38463)

[Part 2] Adding s390x cross-compilation support for gcr.io images in this repo

<!--  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 PR enables s390x support to kube-dns , pause, addon-manager, etcd, hyperkube, kube-discovery etc. This PR also includes the changes due to which it can be cross compiled on x86 host architecture.

**Which issue this PR fixes #34328

**Special notes for your reviewer**:  In existing file "build-tools/build-image/cross/Dockerfile" the repository mentioned for installing cross build tool chains for supporting architecture does not have a tool chain for s390x hence in my PR I am changing the repository so that it will be cross compiled for s390x.

**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`. 
-->
```
Allows cross compilation of Kubernetes on x86 host for s390x also enables s390x support to kube-dns , pause, addon-manager, etcd, hyperkube, kube-discovery etc  
```
2016-12-09 13:22:18 -08:00
gajju26 70b92aab45 PR-2 Making docker images availabe for s390x on gcr.io repository and enables s390x support to kube-dns , pause, addon-manager, etcd, hyperkube, kube-discovery modules 2016-12-09 14:38:02 +05:30
Kubernetes Submit Queue 8cf079bd74 Merge pull request #28458 from rbtcollins/master
Automatic merge from submit-queue (batch tested with PRs 38260, 32811, 28458, 33570, 37096)

Fix support for DNS in local-up-cluster.sh

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

The default appears to be gce now, so this tries to spawn a service in
gce... not the desired outcome for a local test setup.

We also need to sync the kubectl config in the script with the instructions for users, since if people don't test with DNS enabled, it bitrots (which this aims to fix).

To test manually, run something like
```
sudo KUBE_ENABLE_CLUSTER_DNS=true API_HOST_IP=0.0.0.0 ./hack/local-up-cluster.sh
```

The API_HOST_IP=0.0.0.0 is required, otherwise the master is not contactable by kubedns, and the dns pod will fail readychecking on the healthz pod.
2016-12-08 02:11:22 -08:00
Kubernetes Submit Queue 5e923ddc7d Merge pull request #38111 from henrynash/pipe141error
Automatic merge from submit-queue (batch tested with PRs 38111, 38121)

Prevent SIGPIPE errors causing the version check line to fail

The way we use pipe in hack/lib/etcd.sh when processing the version command can lead to
141 failues on some systems. Using a prefix of tail can prevent this.

Fixes #38109
2016-12-05 14:14:39 -08:00
Morgan Bauer 3114920d46
goflags must be after subcommand 2016-12-05 12:25:07 -08:00
henry.nash@uk.ibm.com ec33164686 Prevent SIGPIPE errors causing the version check line to fail
The use of pipe when process the version command can lead to
141 failues on some systems. Using a prefix of tail can prevent this.
2016-12-05 06:36:30 -08:00
Clayton Coleman 138267c876
Switch generator logic to use pkg/apis/meta/v1 2016-12-03 18:57:30 -05:00
Kubernetes Submit Queue 69170e7243 Merge pull request #37826 from danwinship/etcd-path
Automatic merge from submit-queue (batch tested with PRs 37094, 37663, 37442, 37808, 37826)

Fix the PATH that install-etcd.sh tells you to use

After you run install-etcd.sh, it tells you:

    etcd v3.0.14 installed. To use:
    export PATH=${PATH}:/home/danw/rh/go/src/k8s.io/kubernetes/third_party/etcd

which doesn't work if you have an older etcd installed in /usr/bin:

    danw@w541:kubernetes (master)> PATH=${PATH}:/home/danw/rh/go/src/k8s.io/kubernetes/third_party/etcd etcd --version
    etcd Version: 2.2.5

You need to put the local etcd dir first in PATH, not last.
2016-12-03 04:27:53 -08:00
Kubernetes Submit Queue 8bf1ae8313 Merge pull request #37094 from sjug/reshuffle_gobindata_dep
Automatic merge from submit-queue (batch tested with PRs 37094, 37663, 37442, 37808, 37826)

Moved gobindata, refactored ReadOrDie refs

**What this PR does / why we need it**: Having gobindata inside of test/e2e/framework prevents external projects from importing the framework. Moving it out and managing refs fixes this problem.

**Which issue this PR fixes**: fixes #37007
2016-12-03 04:27:46 -08:00
Kubernetes Submit Queue 7621ada226 Merge pull request #36700 from ingvagabund/move-export-flag-of-kubectl-to-get-subcommand
Automatic merge from submit-queue (batch tested with PRs 37997, 37939, 37990, 36700, 37258)

--export flag belongs to kubectl get, not kubectl

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

When running the kubectl via symlink to hyperkube, the ``--export`` flag is not delegated to `kubectl get` but to `kubectl` only. Ending with unrecognized flag.
2016-12-02 19:26:51 -08:00
Sebastian Jug 79202656bc - Moved gobindata, refactored ReadOrDie refs
- Remaining spaghetti untangled
- Missed bazel update and a few hardcoded refs
- New instance of framework.ReadOrDie reference removed post rebase
- Resolve new clientset rebase
- Fixed e2e/generated BUILD dep
- A space
- Missed gobindata ref in golang.sh
2016-12-02 12:57:03 -05:00
Kubernetes Submit Queue 7ec3be4c8e Merge pull request #36964 from ixdy/gobin-build
Automatic merge from submit-queue

Build vendored copy of go-bindata and use that in go generate step

**What this PR does / why we need it**: as the title says, uses the vendored version of `go-bindata` rather than expecting developers to `go get` it (when building outside docker).

**Which issue this PR fixes**: fixes #34067, partially addresses #36655

**Special notes for your reviewer**: we still call `go generate` far too many times:
```console
~/.../src/k8s.io/kubernetes $ which go-bindata
~/.../src/k8s.io/kubernetes $ make
+++ [1116 17:35:28] Building the toolchain targets:
    k8s.io/kubernetes/hack/cmd/teststale
    k8s.io/kubernetes/vendor/github.com/jteeuwen/go-bindata/go-bindata
+++ [1116 17:35:29] Generating bindata:
    test/e2e/framework/gobindata_util.go
+++ [1116 17:35:30] Building go targets for linux/amd64:
    cmd/libs/go2idl/deepcopy-gen
+++ [1116 17:35:35] Building the toolchain targets:
    k8s.io/kubernetes/hack/cmd/teststale
    k8s.io/kubernetes/vendor/github.com/jteeuwen/go-bindata/go-bindata
+++ [1116 17:35:35] Generating bindata:
    test/e2e/framework/gobindata_util.go
+++ [1116 17:35:36] Building go targets for linux/amd64:
    cmd/libs/go2idl/defaulter-gen
+++ [1116 17:35:41] Building the toolchain targets:
    k8s.io/kubernetes/hack/cmd/teststale
    k8s.io/kubernetes/vendor/github.com/jteeuwen/go-bindata/go-bindata
+++ [1116 17:35:41] Generating bindata:
    test/e2e/framework/gobindata_util.go
+++ [1116 17:35:42] Building go targets for linux/amd64:
    cmd/libs/go2idl/conversion-gen
+++ [1116 17:35:47] Building the toolchain targets:
    k8s.io/kubernetes/hack/cmd/teststale
    k8s.io/kubernetes/vendor/github.com/jteeuwen/go-bindata/go-bindata
+++ [1116 17:35:47] Generating bindata:
    test/e2e/framework/gobindata_util.go
+++ [1116 17:35:48] Building go targets for linux/amd64:
    cmd/libs/go2idl/openapi-gen
+++ [1116 17:35:56] Building the toolchain targets:
    k8s.io/kubernetes/hack/cmd/teststale
    k8s.io/kubernetes/vendor/github.com/jteeuwen/go-bindata/go-bindata
+++ [1116 17:35:56] Generating bindata:
    test/e2e/framework/gobindata_util.go
```
Fixing that is a separate effort, though.

cc @sebgoa @ZhangBanger
2016-12-02 07:29:01 -08:00
Jeff Grafton 38690ff7a7 build: don't call unset_platform_envs before building 2016-12-01 10:37:39 -08:00
Dan Winship b39ddf64f6 Fix the PATH that install-etcd.sh tells you to use
If you have an old etcd installed in /usr/bin then you need to add the
local etcd directory to the *start* of PATH, not the end.
2016-12-01 10:07:23 -05:00
Jeff Grafton 0d9d623f04 Build vendored copy of go-bindata and use that in go generate step
Additionally remove all instances of `go get`ing go-bindata
2016-11-30 22:23:40 -08:00
Jeff Grafton 9848d6cc8d build: clean platform envs to prevent cross-contamination 2016-11-29 16:35:45 -08:00
Ivan Shvedunov 2256b27f95 Add options for build container rsync optimization
KUBE_RSYNC_COMPRESS env var sets rsync compression level.
KUBE_RSYNC_GENERATED_TO_BUILD_CONTAINER env var disables rsyncing
generated files to build containers.
2016-11-23 05:40:39 +03:00
Robert Collins d388f3100f Fix support for DNS in local-up-cluster.sh
- Fix unbound variables in hack/local-up-cluster.sh

- explicitly set KUBERNETES_PROVIDER in local-up-cluster.
  The default appears to be gce now, so this tries to spawn a service
  in gce... not the desired outcome for a local test setup.

- Remove stale creation of kube-system: the kube-system namespace is
  built in these days.

- Pickup third party etcd automatically.

- Retab hack/local-up-cluster.sh for consistency

- Update hack-local-up's internal credentials to match the user
  instructions we give (which work).

- Note the CA root requirement in local-up-cluster

- Fix a dangling comment in local-up-cluster

To test manually, run something like:
```sudo KUBE_ENABLE_CLUSTER_DNS+true API_HOST_IP=0.0.0.0
   ./hack/local-up-cluster.sh```
The API_HOST_IP=0.0.0.0 is required otherwise kubedns cannot contact
the master and the dns pod will fail readychecking on the healthz
container.
2016-11-22 13:18:55 +13:00
Jan Chaloupka 7992123449 --export flag belongs to kubectl get, not kubectl
When running the kubectl via symlink to hyperkube, the --export is not delegated to 'kubectl get' but to 'kubectl' only.
Ending with unrecognized flag.
2016-11-17 15:45:55 +01:00
Wojciech Tyczynski b34ac6baef Bump etcd to 3.0.14 in tests 2016-11-07 08:41:17 +01:00
Kubernetes Submit Queue 47519962bf Merge pull request #35484 from smarterclayton/delete_warning
Automatic merge from submit-queue

Add --force to kubectl delete and explain force deletion

--force is required for --grace-period=0. --now is == --grace-period=1.
Improve command help to explain what graceful deletion is and warn about
force deletion.

Part of #34160 & #29033

```release-note
In order to bypass graceful deletion of pods (to immediately remove the pod from the API) the user must now provide the `--force` flag in addition to `--grace-period=0`.  This prevents users from accidentally force deleting pods without being aware of the consequences of force deletion.  Force deleting pods for resources like StatefulSets can result in multiple pods with the same name having running processes in the cluster, which may lead to data corruption or data inconsistency when using shared storage or common API endpoints.
```
2016-11-05 11:19:04 -07:00
Kubernetes Submit Queue 6a88de9fe1 Merge pull request #35648 from deads2k/api-32-reflective-checks
Automatic merge from submit-queue

add script to check for updates to the files for generation

Adds a verify script to help people writing APIs remember to wire all the individual pieces up.  Eventually it will be better to avoid this altogether, but this is a start.

@ncdc fyi
2016-11-04 01:16:52 -07:00
Marcin 26acced6d8 Add policy api version v1beta1 and disable v1alpha1 2016-11-03 13:26:27 +01:00
Kubernetes Submit Queue e817594648 Merge pull request #35731 from janetkuo/statefulset-v1beta1
Automatic merge from submit-queue

Move Statefulset (previously PetSet) to v1beta1

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

**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**: depends on #35663 (PetSet rename)
cc @erictune @foxish @kubernetes/sig-apps 

**Release note**:

``` release-note
v1beta1/StatefulSet replaces v1alpha1/PetSet.
```
2016-11-03 02:46:57 -07:00
Janet Kuo c15b9470f5 Replace apps/v1alpha1 with apps/v1beta1 and manually remove generated apps/v1alpha1 files
Manually remove generated apps/v1alpha1 types, protobuf, and api-reference doc files
Manually remove apps/v1alpha1 folder from 1.5 generated client
2016-11-02 15:16:23 -07:00
Clayton Coleman 6e25830378
Add --force to kubectl delete and explain force deletion
--force is required for --grace-period=0. --now is == --grace-period=1.
Improve command help to explain what graceful deletion is and warn about
force deletion.
2016-11-02 17:44:05 -04:00
Madhusudan.C.S 3c692ebd77 [Federation] Implement the `kubefed` command.
Also:
1. Add it to the client build targets list.
2. Register `kubefed join` and `kubefed unjoin` commands.
2016-11-02 12:48:20 -07:00
deads2k 4850314a5c add script to check for updates to the files for generation 2016-11-01 15:59:50 -04:00
Wojciech Tyczynski 543c2c20ac Update etcd in tests to 3.0.13 2016-10-27 15:06:08 +02:00
Kubernetes Submit Queue d9873f4556 Merge pull request #35644 from thockin/build-fix-rsync
Automatic merge from submit-queue

Build: Use checksum to rsync results

If dependencies are touched, the Makefile will detect that tools like
deepcopy-gen need to be rebuilt.  It will rebuild them, but if Go decides the
dependencies are not ACTUALLY updated (maybe it was a test file - known
limitation of the current Makefile), it does not touch the resulting binary.
The Makefile touches the result explicitly to mark that the dep change has
been handled.  But rsync blows away that change with the older file, and
helpfully preserves the timestamp.  This repeats on every build.

Now rsync ignores it if the checksum is the same.  Result = faster build.

@wojtek-t @gmarek
2016-10-26 12:42:42 -07:00
Tim Hockin 7aa91bbff6 Use checksum to rsync results
If dependencies are touched, the Makefile will detect that tools like
deepcopy-gen need to be rebuilt.  It will rebuild them, but Go decides the
dependencies are not actually updated (maybe it was a test file - known
limitation of the current Makefile) and does not touch the resulting binary.
Then the Makefile touches the result explicitly to mark thatthe dep change has
been handled.  Then rsync blows away that change with the older file, and
helpfully preserves the timestamp.

Now rsync ignores it if the checksum is the same.  Result = faster build.
2016-10-26 16:30:18 +02:00
mbohlool 75451b49f4 - Add GroupVersion as tags to OpenAPI spec
- Remove all end-point specs as they are not useful in light of GroupVersion tags in main spec
2016-10-25 14:27:48 -07:00
Mike Danese 27116c6818 rename build/ to build-tools/ 2016-10-24 14:41:56 -07:00
Kubernetes Submit Queue 29fc947cbb Merge pull request #34770 from lukaszo/curl_flake
Automatic merge from submit-queue

Retry curl when it failed during download

Fixes #34769

For now I'm adding retry only to etcd installation as I saw it recently to fail in one of my PRs. We may change it also in other places if it also happens.
2016-10-20 02:10:27 -07:00
Davanum Srinivas 20d1818d78 Enable local-up-cluster.sh to start with the secured port
Generate a kubeconfig for use with controller-manager, kubelet,
scheduler etc. This kubeconfig should use the secure https
port of the api server with appropriate ca cert for the components
to talk to api server.

With this change, one can set API_PORT=0 to completely switch off
insecure access for testing admission controllers etc.

Fixes #33375
2016-10-19 06:36:01 -04:00
Łukasz Oleś 1cda616a9b Retry curl when it failed during download
Fixes #34769
2016-10-19 11:04:49 +02:00
Kubernetes Submit Queue 2e5303d206 Merge pull request #34612 from jellonek/jell/fix_version_generation
Automatic merge from submit-queue

build: Fix version generation.

This PR provides update to version string generation procedure to handle additional case - working on branch delivered from release tag, instead of working on `-(alpha|beta).no` suffixed tag.

Reason of it is that actually if someone would start working on branch forked from release tag (`v1.4.1` for example), will add some commits and then would try to build k8s/run conformance tests - will end up with broken version string in form similar to `v1.4.1.X+YYYY` where `X` is a dictance/number of commits from base tag and `YYYY` will be first 14 characters from commit hash.
Such version - containing four dotted parts is rejected during conformance tests with error similar to:
```
/go/src/k8s.io/kubernetes/_output/dockerized/go/src/k8s.io/kubernetes/test/e2e/kubectl.go:843
Oct 11 12:38:33.726: Failed to get server version: Unable to parse server version "v1.4.1.5+somecommithash": Invalid character(s) found in patch number "1.5"
/go/src/k8s.io/kubernetes/_output/dockerized/go/src/k8s.io/kubernetes/test/e2e/framework/util.go:413
```

This PR provides a cure for this situation creating version string in form `v1.4.1-X+YYYY` which then should be readable for version validation checks. 

Release note:
```release-note
Fix version string generation for local version different from release and not based on `-alpha.no` or `-beta.no` suffixed tag.
```
2016-10-18 21:11:36 -07:00
Piotr Skamruk 66a85555a2 build: Fix version generation. 2016-10-17 09:13:22 +02:00
Jess Frazelle 3193174142
Remove go patches for darwin
Signed-off-by: Jess Frazelle <acidburn@google.com>
2016-10-13 21:12:15 -07:00
Kubernetes Submit Queue cfbb5e1040 Merge pull request #34150 from mbohlool/co2
Automatic merge from submit-queue

Fix a typo in openapi spec generation

A typo in util.sh resulted in the wrong spec stored in source tree. The commit should be explanatory.
2016-10-06 08:44:59 -07:00
Wojciech Tyczynski 19e50d56dc Run integration tests with 3.0.10 etcd underneath 2016-10-06 09:32:49 +02:00
mbohlool 4ed8328e8d Fix a typo in util.sh that resulted in wrong openapi spec generation 2016-10-05 15:59:38 -07:00
Joe Beda dd3ac00c7d Install test subpackages too
We weren't getting incremental builds because of new test only subpackages.  Our
voodoo combo of 'go install' and 'go test -c' didn't cache things like
'test/e2e_node/services'.  Add the '-i' flag to 'go test' to install test only
dependencies too.
2016-10-03 19:42:21 -07:00
Joe Beda 17454a04ac Remove support for boot2docker 2016-10-03 19:42:20 -07:00
Kubernetes Submit Queue 2628af06f8 Merge pull request #33803 from ixdy/go1.7-darwin-client-binaries
Automatic merge from submit-queue

Use patched golang1.7.1 for cross-builds targeting darwin

This PR extends #32517 to use the patched go1.7.1 introduced by that PR to build all darwin targets (e.g. kubectl).

This is necessary because binaries built with earlier versions of Go regularly segfault on macOS Sierra (see #32999 and #33070).

This solution is somewhat hacky, but we intend to cherry-pick this to 1.4, and switching all of 1.4 to build with go1.7.1 is very high risk.

I haven't yet pushed the cross build image yet, so this will fail to build. Will test locally and update with results.

First step of fixing #33801.

cc @luxas @pwittrock @david-mcmahon @liggitt @smarterclayton @jfrazelle @Starefossen @gerred
2016-09-30 12:29:18 -07:00
Jeff Grafton f769b02c8f Use patched go1.7.1 for cross-builds targeting darwin 2016-09-29 17:05:23 -07:00
mbohlool 35b5174bf1 Generate and verify openapi specs in source tree at api/openapi-spec 2016-09-29 17:03:31 -07:00
deads2k 06b1a9636d promote contrib/mesos to incubator 2016-09-28 10:58:09 -04:00
Kubernetes Submit Queue 83b4133ea8 Merge pull request #33496 from mikedanese/build-kubeadm-kubedisco
Automatic merge from submit-queue

build kube-discovery and kubeadm with release

This will start publishing binaries from our ci builds.

@errordeveloper @dgoodwin
2016-09-27 03:46:57 -07:00
Jeff Grafton 13a3313957 Bundle kubemark in test tarball instead of server tarball 2016-09-26 11:06:48 -07:00
Mike Danese b421bf4315 build kube-discovery and kubeadm with release 2016-09-26 10:20:04 -07:00
Lucas Käldström b17e107def Various improvements plus added a version command 2016-09-25 22:38:39 +03:00
Kubernetes Submit Queue a18bc2eb09 Merge pull request #33277 from mkumatag/genman_all
Automatic merge from submit-queue

Automatic generation of man pages

<!--  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**:
Currently genman supports only kubectl command, so this PR will enable genman to generate man pages for rest of the command like - kube-apiserver, kube-controller-manager, kube-proxy, kube-scheduler, kubelet
**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #
N/A
**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-24 02:10:19 -07:00
deads2k 7a8fa18116 update generation scripts to share API group version constants 2016-09-22 13:30:41 -04:00
Manjunath A Kumatagi 6047787fa3 Add support for generating all the manpages to genman 2016-09-22 20:09:22 +05:30
Kubernetes Submit Queue dae3bddf90 Merge pull request #32884 from Random-Liu/separate-build-for-node-e2e
Automatic merge from submit-queue

Add separate build process for node test.

This PR is part of https://github.com/kubernetes/kubernetes/pull/31093. However, because currently node e2e is built on `KUBE_TEST_PLATFORMS`, which includes linux/amd64, darwin/amd64, windows/amd64 and linux/arm, it caused #32251 to fail.

In fact, node e2e is running on the same node with kubelet, and it also has built-in apiserver, etcd and namespace controller. All of them are only built on `KUBE_SERVER_PLATFORMS`, so node e2e should also only be built on those platforms.
```
KUBE_SERVER_PLATFORMS=(
     linux/amd64
     linux/arm
     linux/arm64
   )
```

This PR added a separate build process for node e2e to address this.

@vishh Do you need this for v1.4? because this blocks your #32251. /cc @dchen1107
2016-09-16 14:16:57 -07:00
Random-Liu a67fec6419 Add separate build process for node test. 2016-09-16 11:17:49 -07:00
Lucas Käldström aa045f786e Use a patched golang version for building linux/arm, fixes kube-apiserver 2016-09-14 18:04:22 +03:00
Chao Xu 7e92025cfd stick to 2.2.1 etcd 2016-09-09 16:35:05 -07:00
Daniel Smith 279219ca89 Use etcd 2.3.7 (container already pushed) 2016-09-09 09:45:53 +02:00
Jordan Liggitt a869de61bd
Namespace certificates API group 2016-09-01 14:39:06 -04:00
nikhiljindal 209d544bed Adding a script to update federation API reference docs 2016-08-31 13:21:42 -07:00
nikhiljindal a954ff18e6 Adding update-federation-generated-swagger-docs to generate comment funcs for federation gvs 2016-08-30 14:15:21 -07:00
Dr. Stefan Schimanski f2f3a459d8 Use portable ln -snf instead of -sTf 2016-08-29 18:58:56 +02:00
Kubernetes Submit Queue 1e42723269 Merge pull request #31525 from dcbw/handle-existing-go_pkg_dir
Automatic merge from submit-queue

Don't error out if ${go_pkg_dir} already exists

I have 'make' aliased to 'make -j4' for various reasons, and that's always worked fine for Kubernetes in the past.  But it recently broke because EEXIST errors from this symlink creation are fatal.  So make them not fatal, because if the path already exists, why try to create it again?  It exists because two invocations of setup_env() are run in parallel due to the -j4, and they race to create the symlink and one obviously fails.

ln: failed to create symbolic link ‘/home/dcbw/Development/containers/kubernetes/_output/local/go/src/k8s.io/kubernetes’: File exists
Makefile.generated_files:285: recipe for target '_output/bin/deepcopy-gen' failed
make[1]: *** [_output/bin/deepcopy-gen] Error 1
make[1]: *** Waiting for unfinished jobs....
+++ [0826 10:18:02] Generating bindata:
    /home/dcbw/Development/containers/kubernetes/test/e2e/framework/gobindata_util.go
+++ [0826 10:18:02] Building the toolchain targets:
    k8s.io/kubernetes/hack/cmd/teststale
+++ [0826 10:18:03] Building go targets for linux/amd64:
    cmd/libs/go2idl/conversion-gen
Makefile:281: recipe for target 'generated_files' failed
make: *** [generated_files] Error 2
2016-08-28 13:57:32 -07:00
Dan Williams e063c760c2 Don't error out if ${go_pkg_dir} already exists
If it already exists, the world is OK and there's no need to panic.
2016-08-26 13:10:13 -05:00