Commit Graph

367 Commits (8e98f1dfec9d1f3a100fe9af9588bcbedc0ab801)

Author SHA1 Message Date
Clayton Coleman 784e3ae5fa
Switch the tokens controller to use shared informers
Tokens controller previously needed a bit of extra help in order to be
safe for concurrent use. The new MutationCache allows it to keep a local
cache and still use a shared informer. The filtering event handler lets
it only see changes to secrets it cares about.
2017-05-20 14:19:49 -04:00
Nick Sardo 87a5edd2cd Initialize cloud providers with a K8s clientBuilder 2017-05-17 14:38:25 -07:00
Kubernetes Submit Queue 7f92d35f1c Merge pull request #45739 from timothysc/cm_lock
Automatic merge from submit-queue (batch tested with PRs 45374, 44537, 45739, 44474, 45888)

Allow kcm and scheduler to lock on ConfigMaps.

**What this PR does / why we need it**:
Plumbs through the ability to lock on ConfigMaps through the kcm and scheduler.  

**Which issue this PR fixes** 
Fixes: #44857
Addresses issues with: #45415

**Special notes for your reviewer**:

**Release note**:

```
Add leader-election-resource-lock support to kcm and scheduler to allow for locking on ConfigMaps as well as Endpoints(default) 
```
/cc @kubernetes/sig-cluster-lifecycle-pr-reviews @jamiehannaford @bsalamat @mikedanese
2017-05-16 18:10:57 -07:00
Kubernetes Submit Queue c924414b1f Merge pull request #45548 from justinsb/fix_typo_ss_controller
Automatic merge from submit-queue (batch tested with PRs 45826, 45747, 45548, 45606, 41766)

Fix typo in name of ss controller
2017-05-15 11:39:24 -07:00
Timothy St. Clair 1173c84ad9 Update to plumb through configurable locking on different resource types. 2017-05-15 10:01:46 -05:00
Jamie Hannaford a2248a2bcd Add lock type flags for controller-manager leadership election 2017-05-15 08:42:15 -05:00
Hemant Kumar 9a1a9cbe08 detach the volume when pod is terminated
Make sure volume is detached when pod is terminated because
of any reason and not deleted from api server.
2017-05-11 22:18:22 -04:00
Justin Santa Barbara a88a0abbdb Fix typo in name of ss controller
Typo, but I presume also we're intending to allow control of individual
controllers, so the name does matter.
2017-05-09 11:31:06 -04:00
deads2k b7161a02b2 expose controller initializers 2017-05-08 14:34:18 -04:00
Jan Safranek 9d0c47f1db Use storage.v1 instead of v1beta1
storage.v1beta1 was used to work around GKE which does not expose v1. Now that
GKE is updated, we can switch everything to v1.
2017-04-25 10:13:38 +02:00
Andy Goldstein e63fcf708d Make controller Run methods consistent
- startup/shutdown logging
- wait for cache sync logging
- defer utilruntime.HandleCrash()
- wait for stop channel before exiting
2017-04-14 07:27:45 -04:00
Kubernetes Submit Queue d32668b0be Merge pull request #43277 from StudyNick/zte-20170315
Automatic merge from submit-queue (batch tested with PRs 44447, 44456, 43277, 41779, 43942)

variable 'controller' collides with imported package name

variable 'controller' collides with imported package name,
 'controller'  modify 'ctrl'
2017-04-13 15:01:58 -07:00
NickrenREN e0ef5bfd40 Exit from NewController() for PersistentVolumeController when InitPlugins() failed just like NewAttachDetachController() does 2017-04-12 13:43:09 +08:00
Kubernetes Submit Queue ceccd305ce Merge pull request #42147 from bowei/ip-alias-2
Automatic merge from submit-queue

Add support for IP aliases for pod IPs (GCP alpha feature)

```release-note
Adds support for allocation of pod IPs via IP aliases.

# Adds KUBE_GCE_ENABLE_IP_ALIASES flag to the cluster up scripts (`kube-{up,down}.sh`).

KUBE_GCE_ENABLE_IP_ALIASES=true will enable allocation of PodCIDR ips
using the ip alias mechanism rather than using routes. This feature is currently
only available on GCE.

## Usage
$ CLUSTER_IP_RANGE=10.100.0.0/16 KUBE_GCE_ENABLE_IP_ALIASES=true bash -x cluster/kube-up.sh

# Adds CloudAllocator to the node CIDR allocator (kubernetes-controller manager).

If CIDRAllocatorType is set to `CloudCIDRAllocator`, then allocation
of CIDR allocation instead is done by the external cloud provider and
the node controller is only responsible for reflecting the allocation
into the node spec.

- Splits off the rangeAllocator from the cidr_allocator.go file.
- Adds cloudCIDRAllocator, which is used when the cloud provider allocates
  the CIDR ranges externally. (GCE support only)
- Updates RBAC permission for node controller to include PATCH
```
2017-04-11 22:09:24 -07:00
Kubernetes Submit Queue e60cc6ee3d Merge pull request #44090 from NickrenREN/remove-alpha-pv
Automatic merge from submit-queue

Remove alphaProvisioner in PVController and AlphaStorageClassAnnotation

remove alpha annotation and alphaProvisioner 

**Release note**:

```release-note
NONE
```
2017-04-11 20:41:40 -07:00
Bowei Du f61590c221 Adds support for PodCIDR allocation from the GCE cloud provider
If CIDRAllocatorType is set to `CloudCIDRAllocator`, then allocation
of CIDR allocation instead is done by the external cloud provider and
the node controller is only responsible for reflecting the allocation
into the node spec.

- Splits off the rangeAllocator from the cidr_allocator.go file.
- Adds cloudCIDRAllocator, which is used when the cloud provider allocates
  the CIDR ranges externally. (GCE support only)
- Updates RBAC permission for node controller to include PATCH
2017-04-11 14:07:54 -07:00
NickrenREN fa7bd44966 Remove alphaProvisioner in PVController and AlphaStorageClassAnnotation 2017-04-10 17:09:40 +08:00
NickrenREN 780eae7633 Extract ParseCIDR and modify serviceControllerName 2017-04-08 13:32:22 +08:00
StudyNick 89a987bf40 variable 'controller' collides with imported package name 2017-03-17 14:25:10 +08:00
deads2k 0a2cd24f9d don't start controllers against unhealthy master 2017-03-16 14:06:18 -04:00
gmarek 48d784272e Move taint eviction feature flag to feature-gates 2017-03-08 10:04:18 +01:00
Kubernetes Submit Queue 5bc7387b3c Merge pull request #42169 from ncdc/pprof-trace
Automatic merge from submit-queue (batch tested with PRs 42692, 42169, 42173)

Add pprof trace support

Add support for `/debug/pprof/trace`

Can wait for master to reopen for 1.7.

cc @smarterclayton @wojtek-t @gmarek @timothysc @jeremyeder @kubernetes/sig-scalability-pr-reviews
2017-03-07 20:10:26 -08:00
Andy Goldstein b011529d8a Add pprof trace support
Add pprof trace support and --enable-contention-profiling to those
components that don't already have it.
2017-03-07 10:10:42 -05:00
deads2k 8be9a216d4 make all controllers obey the disable flags 2017-03-06 15:58:08 -05:00
Andy Goldstein 4cd38b863f Remove references to pkg/controller/informers 2017-02-27 06:47:59 -05:00
Jordan Liggitt 41c88e0455
Revert "Merge pull request #40088 from jsafrane/storage-ga-v1"
This reverts commit 5984607cb9, reversing
changes made to 067f92e789.
2017-02-25 22:35:15 -05:00
Jan Safranek 3f6caca97a Add storage.k8s.io/v1 2017-02-24 13:34:18 +01:00
gmarek d88af7806c NodeController sets NodeTaints instead of deleting Pods 2017-02-24 09:24:33 +01:00
Kubernetes Submit Queue af41d2f57c Merge pull request #41661 from liggitt/satoken
Automatic merge from submit-queue

Make controller-manager resilient to stale serviceaccount tokens

Now that the controller manager is spinning up controller loops using service accounts, we need to be more proactive in making sure the clients will actually work.

Future additional work:
* make a controller that reaps invalid service account tokens (c.f. https://github.com/kubernetes/kubernetes/issues/20165)
* allow updating the client held by a controller with a new token while the controller is running (c.f. https://github.com/kubernetes/kubernetes/issues/4672)
2017-02-20 08:39:31 -08:00
Jordan Liggitt b83e6f7d91
Make controller-manager resilient to stale serviceaccount tokens 2017-02-17 23:59:00 -05:00
Kubernetes Submit Queue 58ec5cce28 Merge pull request #41355 from ncdc/shared-informers-09-service
Automatic merge from submit-queue

Switch service controller to shared informers

Originally part of #40097 

cc @deads2k @smarterclayton @gmarek @wojtek-t @timothysc @sttts @liggitt @kubernetes/sig-scalability-pr-reviews
2017-02-17 09:04:28 -08:00
Matthew Wong 33f98d4db3 Switch pv controller to shared informers 2017-02-16 10:08:23 -05:00
Shyam JVS 2ed7acfbcc Revert "Remove alpha provisioning" 2017-02-16 13:53:55 +01:00
Kubernetes Submit Queue 8faa9b5d4e Merge pull request #40000 from jsafrane/storage-ga-remove-alpha
Automatic merge from submit-queue

Remove alpha provisioning

This is the first part of https://github.com/kubernetes/features/issues/36

@kubernetes/sig-storage-misc 

**Release note**:
```release-note
Alpha version of dynamic volume provisioning is removed in this release. Annotation
"volume.alpha.kubernetes.io/storage-class" does not have any special meaning. A default storage class
and  DefaultStorageClass admission plugin can be used to preserve similar behavior of Kubernetes cluster,
see https://kubernetes.io/docs/user-guide/persistent-volumes/#class-1 for details.
```
2017-02-16 01:02:06 -08:00
Andy Goldstein 726f18524b Switch service controller to shared informers 2017-02-15 11:21:01 -05:00
Andy Goldstein effde6b8dd Switch route controller to shared informers 2017-02-13 15:21:33 -05:00
deads2k fd34b11e13 react to informer updates 2017-02-13 09:18:32 -05:00
Joe Beda 415e20877e
Wire in bootstrap and token controllers.
This adds these to the list of controllers the Controller Manager can start.  But as these are alpha, they are also currently disabled by default.
2017-02-10 12:49:23 -08:00
Kubernetes Submit Queue a7a74b56da Merge pull request #40355 from gmarek/nc-taint-handling
Automatic merge from submit-queue (batch tested with PRs 39418, 41175, 40355, 41114, 32325)

TaintController

```release-note
This PR adds a manager to NodeController that is responsible for removing Pods from Nodes tainted with NoExecute Taints. This feature is beta (as the rest of taints) and enabled by default. It's gated by controller-manager enable-taint-manager flag.
```
2017-02-10 04:50:42 -08:00
Kubernetes Submit Queue a9dc65675b Merge pull request #41175 from StudyNick/zte-20170209
Automatic merge from submit-queue (batch tested with PRs 39418, 41175, 40355, 41114, 32325)

ResyncPeriod Comment

ResyncPeriod Comment:
// ResyncPeriod returns a function which generates a duration each time it is
// invoked; this is so that multiple controllers don't get into lock-step and all
// hammer the apiserver with list requests simultaneously.
2017-02-10 04:50:41 -08:00
gmarek 2f0e436677 Taint controller - first commit 2017-02-10 02:13:45 +01:00
Wojciech Tyczynski 3aebc4c003 Implement ttl controller 2017-02-09 13:53:32 +01:00
zte-20170208 4f19bcb3f0 ResyncPeriod Comment 2017-02-09 10:02:55 +08:00
Andy Goldstein 70c6087600 Replace hand-written informers with generated ones
Replace existing uses of hand-written informers with generated ones.
 Follow-up commits will switch the use of one-off informers to shared
 informers.
2017-02-06 13:49:27 -05:00
Jan Safranek 587eb199e0 Remove alpha provisioning 2017-02-01 14:51:54 +01:00
deads2k 8a12000402 move client/record 2017-01-31 19:14:13 -05:00
deads2k 2734f8f892 move dynamic and discovery clients 2017-01-26 08:37:06 -05:00
deads2k 5a8f075197 move authoritative client-go utils out of pkg 2017-01-24 08:59:18 -05:00
deads2k 335ef747d6 mechanical 2017-01-23 10:03:55 -05:00
deads2k ee6752ef20 find and replace 2017-01-20 08:04:53 -05:00