Commit Graph

2710 Commits

Author SHA1 Message Date
Eric Chiang
f2a9823316 client-go: make exec auth and auth provider mutually exclusive
Kubernetes-commit: d96fd39651a4182ceb016c879a17c6a237c87f53
2018-06-01 10:34:45 -07:00
Eric Chiang
45b15acf0b generated:
./hack/update-bazel.sh
	./hack/update-codegen.sh
	./hack/update-staging-godeps.sh

Kubernetes-commit: 206982723909944a2e68c3ffa9382f6b332e767a
2018-05-31 14:30:33 -07:00
Eric Chiang
c61cf26da4 client-go: promote exec plugin support to beta
Kubernetes-commit: 0a9164e73aedd898a535a64fcc992d3e50002d61
2018-05-31 14:28:27 -07:00
Eric Chiang
f58a8f4fd0 clientauthentication: add v1beta1 API version
Kubernetes-commit: 8952b8f7c99b75a9dc1aa47eb50770d218b2a8bf
2018-05-31 14:27:45 -07:00
Antoine Pelisse
d7b585cf00 Replace openapi Fake with kube-openapi version
There are two version of this fake class, let's just use that one
version.

Kubernetes-commit: 000510d9b73d5be870ebc763ea3606997107172c
2018-05-31 14:00:34 -07:00
Lucas Käldström
4d6c30f52a Move helper funcs and constants to the client-go Bootstrap Token package from kubeadm
Kubernetes-commit: 33f59e438e93b824492caff5d39fd143b43eac9a
2018-05-31 22:18:27 +03:00
Zhonghu Xu
b9ecec59bd remove inaccurate comment about watch timeout
Kubernetes-commit: 9561269d9308278018da0284638baed1d1c33144
2018-05-31 16:20:04 +08:00
Andrew Lytvynov
c669580288 Add TLS support to exec authenticator plugin
https://github.com/kubernetes/community/blob/master/contributors/design-proposals/auth/kubectl-exec-plugins.md#tls-client-certificate-support

Allows exec plugin to return raw TLS key/cert data. This data populates
transport.Config.TLS fields.
transport.Config.TLS propagates custom credentials using
tls.Config.GetClientCertificate callback.
On key/cert rotation, all connections using old credentials are
closed

Kubernetes-commit: cd89f9473faa60c15b8e9d223e5c4f9dab53627a
2018-05-30 14:03:32 -07:00
kgrygiel
c88b472871 Auto-generated code for the Vertical Pod Autoscaler API.
Kubernetes-commit: da65f30e2aca4ca8177fcf27e95909e2883b6e20
2018-05-30 16:54:03 +02:00
Guoliang Wang
5037893508 replace fmt.Sprintf(%s, i.Type()) with i.Type().String()
Kubernetes-commit: 17ad3eaa26b4ecf2759eadb01ab91af6ae292a3c
2018-05-30 18:18:58 +08:00
k8s-ci-robot
9a5fde770f
Merge pull request #423 from sttts/sttts-revert-dot-github-change
Revert non-staging change to .github/PULL_REQUEST_TEMPLATE.md
2018-05-29 01:52:32 -07:00
Dr. Stefan Schimanski
f4c1c0ae19 client-go: document README exception in .github/PULL_REQUEST_TEMPLATE.md
Kubernetes-commit: f6d4244c30060bcf6ebe4ad80ecec47e836aca30
2018-05-29 09:16:25 +02:00
Dr. Stefan Schimanski
52e5f114ac Revert non-staging change to .github/PULL_REQUEST_TEMPLATE.md 2018-05-29 09:10:52 +02:00
k8s-ci-robot
d7f4abc82c
Merge pull request #421 from mistyhacks/update-PR-guidelines
Document that changes to the README.md are done in this repo
2018-05-29 00:07:31 -07:00
Davanum Srinivas
edd1069068 Deprecate the in-tree keystone plugin
We now have the `client-keystone-auth` in cloud-provider-openstack
repository:
https://github.com/kubernetes/cloud-provider-openstack/blob/master/docs/using-client-keystone-auth.md

So let's drop the in-tree one, so we can remove it in 1.12

Kubernetes-commit: ffe817fcababca46d4989ff3982807468645d2ea
2018-05-25 15:55:49 -07:00
Misty Stanley-Jones
12a6e5ed0a Document that changes to the README.md are done in this repo
Signed-off-by: Misty Stanley-Jones <mistyhacks@google.com>
2018-05-25 10:32:46 -07:00
Dr. Stefan Schimanski
dd9316d8bf client-go: start fresh with owner file
Kubernetes-commit: 11f65b2a30be2bfc014c563dc7a8e98ec3ccc1ff
2018-05-25 15:49:44 +02:00
k8s-ci-robot
9126b42c46
Merge pull request #420 from mistyhacks/419_rewording
Rewording for clarity
2018-05-25 05:35:33 -07:00
Misty Stanley-Jones
ae6749452b Rewording for clarity
Signed-off-by: Misty Stanley-Jones <mistyhacks@google.com>
2018-05-24 12:51:22 -07:00
jennybuckley
8ad25042a9 Run hack/update-all.sh
Kubernetes-commit: 349fbdfe9fbcad91fcecbfe4e71fa91d235dad6d
2018-05-24 09:55:33 -07:00
Jess Frazelle
1ea562b7b9 add PST to main SECURITY_CONTACTS as formality
Add the Product Security Team as the security contacts for the main
repository and they can use the OWNERS files in each subsystem/dir to find
the correct owners.

Signed-off-by: Jess Frazelle <acidburn@microsoft.com>

Kubernetes-commit: ac015892e4e2ab641a7761ab79f8cf986e1fa266
2018-05-24 09:33:43 -04:00
wojtekt
aee33a8197 Autogenerated stuff
Kubernetes-commit: 0950084137a5abf5cd731bbda46ccb441499801d
2018-05-24 13:02:08 +02:00
David Ashpole
55b7c99dca add metadata to kubelet eviction event annotations
Kubernetes-commit: fd1f19fc423880b2b292d6f9e6fca1e941e87994
2018-05-23 16:12:54 -07:00
David Eads
1088d9ef09 prevent zero for leader election timeouts
Kubernetes-commit: 7288e8828f5bf659d41e71760f9d9923e405e2e4
2018-05-23 15:00:37 -04:00
Kubernetes Publisher
e1b1ad3518 Merge pull request #60464 from roycaihw/loadconfig
Automatic merge from submit-queue (batch tested with PRs 63598, 63913, 63459, 63963, 60464). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Client-go raises error on duplicated name in kubeconfig

(for NamedCluster, NamedContext, NamedUser, NamedExtension)

**What this PR does / why we need it**:
Client should detect duplicated name when loading `name-value` based lists in kubeconfig: `users`, `clusters`, `contexts`. Currently if there are multiple value with same name, `client-python` will pick the first one, while `client-go` will pick the last.

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
ref: kubernetes-client/python#445, kubernetes-client/python-base#47

**Special notes for your reviewer**:

**Release note**:

```release-note
kubectl and client-go now detects duplicated name for user, cluster and context when loading kubeconfig and reports error
```

/sig api-machinery

cc @brendandburns @mbohlool

Kubernetes-commit: 7909712ca574c536901bc7858dfbf72a3a6ee7dd
2018-05-19 14:28:34 +00:00
Kubernetes Publisher
fd323869ad Merge pull request #63913 from deads2k/controller-10-event
Automatic merge from submit-queue (batch tested with PRs 63598, 63913, 63459, 63963, 60464). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

fix event ref determination for apigroups

The event ref determination was never updated to handle apigroups so it has been returning only a group (not a version).

@kubernetes/sig-apps-bugs

```release-note
event object references with apiversion will now report an apiversion.
```

Kubernetes-commit: 4810b9ba679f4fb9cc39f3a83bbcd23b3e4accce
2018-05-19 14:28:13 +00:00
Kubernetes Publisher
d9cf977510 Merge pull request #60012 from atlassian/dial-with-context
Automatic merge from submit-queue (batch tested with PRs 60012, 63692, 63977, 63960, 64008). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Use Dial with context

**What this PR does / why we need it**:
`net/http/Transport.Dial` field is deprecated:
```go
// DialContext specifies the dial function for creating unencrypted TCP connections.
// If DialContext is nil (and the deprecated Dial below is also nil),
// then the transport dials using package net.
DialContext func(ctx context.Context, network, addr string) (net.Conn, error)

// Dial specifies the dial function for creating unencrypted TCP connections.
//
// Deprecated: Use DialContext instead, which allows the transport
// to cancel dials as soon as they are no longer needed.
// If both are set, DialContext takes priority.
Dial func(network, addr string) (net.Conn, error)
```
This PR switches all `Dial` usages to `DialContext`. Fixes #63455.

**Special notes for your reviewer**:
Also related: https://github.com/kubernetes/kubernetes/pull/59287 https://github.com/kubernetes/kubernetes/pull/58532 https://github.com/kubernetes/kubernetes/issues/815 https://github.com/kubernetes/community/pull/1166 https://github.com/kubernetes/kubernetes/pull/58677 https://github.com/kubernetes/kubernetes/pull/57932

**Release note**:
```release-note
HTTP transport now uses `context.Context` to cancel dial operations. k8s.io/client-go/transport/Config struct has been updated to accept a function with a `context.Context` parameter. This is a breaking change if you use this field in your code.
```
/sig api-machinery
/kind enhancement
/cc @sttts

Kubernetes-commit: ddf551c24b7d88454f8332ce6855e53281440958
2018-05-19 10:28:06 +00:00
Mikhail Mazurskiy
4a75b93cb4 Use Dial with context
Kubernetes-commit: 5e8e570dbda6ed89af9bc2e0a05e3d94bfdfcb61
2018-05-19 08:14:37 +10:00
Kubernetes Publisher
4bb327ea2f Merge pull request #63936 from awly/extract-connwatch
Automatic merge from submit-queue (batch tested with PRs 63865, 57849, 63932, 63930, 63936). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Extract connection rotating dialer into a package

**What this PR does / why we need it**: This will be re-used for exec auth plugin to rotate connections on
credential change.

**Special notes for your reviewer**: this was split from https://github.com/kubernetes/kubernetes/pull/61803 to simplify review

**Release note**:
```release-note
NONE
```

Kubernetes-commit: da8e25c63dbc48f35065f5790f2f522bbe0c3641
2018-05-17 00:28:30 -07:00
Kubernetes Publisher
ea16f6128e Merge pull request #63875 from deads2k/client-10-timeout
Automatic merge from submit-queue (batch tested with PRs 63875, 63817). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

make TestGetServerGroupsWithTimeout more reliable

Stops overriding a global variable in a test and tolerates a different kind of timeout message you can see.

/assign @soltysh

Kubernetes-commit: baad3d4159db43927e250d4b3f23d6e083b01294
2018-05-16 18:32:14 +00:00
Andrew Lytvynov
6c082e8151 Extract connection rotating dialer into a package
This will be re-used for exec auth plugin to rotate connections on
credential change.

Kubernetes-commit: 85a61ff3aa7df8d83af304ebffab780fabd028a8
2018-05-16 10:30:53 -07:00
David Eads
acfb32b7e4 fix event ref determination for apigroups
Kubernetes-commit: b2be8953b147d4c386768b0bdd3d9a93a47a625b
2018-05-16 08:08:20 -04:00
Kubernetes Publisher
79540301d5 Merge pull request #63861 from deads2k/client-09-clean
Automatic merge from submit-queue (batch tested with PRs 63589, 63644, 63861, 63872, 63847). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

remove service.deletecollection since the server doesn't support it

Updates the generated service client to match the API available.

@kubernetes/sig-api-machinery-pr-reviews
@kubernetes/api-reviewers

```release-note
NONE
```

Kubernetes-commit: 49e9322d4f62cda83e3eac815e202967dc1a0333
2018-05-16 02:29:53 +00:00
Jeff Grafton
4e14588875 Update to gazelle 0.12.0 and run hack/update-bazel.sh
Kubernetes-commit: a725660640fead200892bcfd07b1d319da5d3c09
2018-05-15 17:22:27 -07:00
Kubernetes Publisher
f9b6f71f0a Merge pull request #63800 from wojtek-t/fix_fake_listers
Automatic merge from submit-queue (batch tested with PRs 63658, 63509, 63800, 63586, 63840). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Fix List in fake clients to propagate ListMeta

Kubernetes-commit: 765c49db41dbe067cfca5d83cf438fb02b3468b8
2018-05-15 14:23:16 -07:00
Kubernetes Publisher
690cda5361 Merge pull request #63550 from juanvallejo/jvallejo/move-cached-discovery
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

move cached_discovery to client-go/discovery

**Release note**:
```release-note
NONE
```

Moves the cmd/util CachedDiscoveryClient to client-go

cc @soltysh @deads2k

Kubernetes-commit: f2ea83bef88f9d2783abe0c00de563db13ec04f4
2018-05-15 18:30:59 +00:00
David Eads
ef648e2917 make TestGetServerGroupsWithTimeout more reliable
Kubernetes-commit: e7620e814aebca184160f2ae5ef243f5dcd1f409
2018-05-15 12:47:23 -04:00
David Eads
10b605faab generated
Kubernetes-commit: eb438b088ccf2800e58c37aa8aefe6ce6482aacb
2018-05-15 09:00:50 -04:00
Kubernetes Publisher
988feb35af Merge pull request #63100 from ravisantoshgudimetla/priority-beta-api
Automatic merge from submit-queue (batch tested with PRs 55511, 63372, 63400, 63100, 63769). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Create pkg/scheduling/apis/v1beta1 and move priorityClass to beta

**What this PR does / why we need it**:
This is for creating pkg/apis/scheduling/v1beta1 so that priorityClasses could be moved to beta.

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

**Special notes for your reviewer**:
/cc @bsalamat @aveshagarwal

**Release note**:

```release-note
The `PriorityClass` API is promoted to `scheduling.k8s.io/v1beta1`
```

Kubernetes-commit: a1b54f3c99f2ae4d7d10c269939e5c0bb6d03e6f
2018-05-14 22:30:03 +00:00
wojtekt
41a5bc501f Autogenerated code
Kubernetes-commit: c69165d50386d12c8644bd6de974a9d2fdfc876c
2018-05-14 16:14:53 +02:00
Kubernetes Publisher
421cf66e41 Merge pull request #63446 from deads2k/client-08-remove-old
Automatic merge from submit-queue (batch tested with PRs 63367, 63718, 63446, 63723, 63720). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

finish new dynamic client and deprecate old dynamic client

Builds on a couple other pulls.  This completes the transition to the new dynamic client.

@kubernetes/sig-api-machinery-pr-reviews 
@caesarxuchao @sttts 

```release-note
The old dynamic client has been replaced by a new one.  The previous dynamic client will exist for one release in `client-go/deprecated-dynamic`.  Switch as soon as possible.
```

Kubernetes-commit: 92ba95c39c6f7192502c3d907006c8828dd7b32c
2018-05-11 14:49:16 -07:00
juanvallejo
a0e8687452 restore old cached client behavior
Kubernetes-commit: 57f308ae60875e90004dca592d47cbf6bce390ba
2018-05-11 15:50:13 -04:00
Kubernetes Publisher
b4efb2d46b Merge pull request #59727 from wgliang/master.time
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

should use time.Since instead of time.Now().Sub

**What this PR does / why we need it**:
should use time.Since instead of time.Now().Sub

**Special notes for your reviewer**:

Kubernetes-commit: 7eb88f11d23d2be7dc3a91f727a1a77a0abac5e8
2018-05-11 14:29:34 +00:00
zhengjiajin
7d6d732419 enhance leaderelection code
Kubernetes-commit: 9fe2a5a430055657186491c23e85cc489e401bc7
2018-05-11 13:29:41 +08:00
Kubernetes Publisher
cf2db96347 Merge pull request #63613 from deads2k/cli-52-builderclient
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

 construct resource.Builder from kubeconfig flags

updates the resource.Builder to be constructed from the kubeconfig flags struct/interface that we now have.

@kubernetes/sig-cli-maintainers
@juanvallejo @soltysh

```release-note
NONE
```

Kubernetes-commit: 7e75a09db6dc13218b4f5e06493115ae96f83774
2018-05-10 18:29:26 +00:00
Kubernetes Publisher
b2243688f8 Merge pull request #60200 from dixudx/clientgo_openstack_config
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

read openstack auth config from client config

**What this PR does / why we need it**:
> // TODO: read/persist client configuration(OS_XXX env vars) in config

/sig openstack

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

**Special notes for your reviewer**:
/assign @dims
**Release note**:

```release-note
read openstack auth config from client config
```

Kubernetes-commit: 9dcbdc3d459ec6b2bb149a9f4f3c0d1348113e4a
2018-05-10 18:29:03 +00:00
Kubernetes Publisher
638bb430f4 Merge pull request #61976 from atlassian/ticker-with-stop
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Stop() for Ticker to enable leak-free code

**What this PR does / why we need it**:
I wanted to use the clock package but the `Ticker` without a `Stop()` method is a deal breaker for me.

**Release note**:
```release-note
NONE
```
/kind enhancement
/sig api-machinery

Kubernetes-commit: d42df4561a6c754120e9b46b37c032a57ca92a9a
2018-05-10 06:27:21 +00:00
Kubernetes Publisher
9cabba1998 Merge pull request #63602 from deads2k/cli-54-categories
Automatic merge from submit-queue (batch tested with PRs 59284, 63602). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

 category expansion can only come from the server

A couple release ago we moved category expansion to the server instead of hardcoding it in the client.  Similar to restmappings, there is no valid client-side expansion anymore, so this removes the code that hardcoded the list and moves the category expansion to the same package as our discovery based restmappers.

@kubernetes/sig-cli-maintainers

```release-note
NONE
```

Kubernetes-commit: ca92b73a659bf92c3051765a6ea5bc8c12069975
2018-05-09 22:27:11 +00:00
Jordan Liggitt
212413e762 Collapse memcached discovery client onto parallelized discovery method
Kubernetes-commit: af7d3b21f85d12e3296d8b237c7181d515ee530c
2018-05-09 18:00:12 -04:00
Kubernetes Publisher
de3c9b6cf8 Merge pull request #63502 from liggitt/parallel-discovery
Automatic merge from submit-queue (batch tested with PRs 62354, 62934, 63502). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Run resource discovery in parallel

best viewed ignoring whitespace (https://github.com/kubernetes/kubernetes/pull/63502/files?w=1)

on high-latency connections, serializing resource discovery requests across group versions can take significant amounts of time. this parallelizes the network request portion of the discovery call

xref #63368

```release-note
NONE
```

Kubernetes-commit: 234939dced42952045fc2a42b74a805affcff965
2018-05-09 18:27:48 +00:00