Skip to content

Commit a119d94

Browse files
authored
Merge pull request #2275 from cheftako/ccm-build
Fixing cloud provider KEP.
2 parents bb99405 + 9c79176 commit a119d94

File tree

2 files changed

+530
-5
lines changed

2 files changed

+530
-5
lines changed

keps/sig-cloud-provider/0002-cloud-controller-manager.md

Lines changed: 36 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,27 @@ replaces:
5555
- [Process Goals](#process-goals)
5656
- [Implementation History](#implementation-history)
5757
- [Alternatives](#alternatives)
58+
59+
## Terms
60+
61+
- **CCM**: Cloud Controller Manager - The controller manager responsible for running cloud provider dependent logic,
62+
such as the service and route controllers.
63+
- **KCM**: Kubernetes Controller Manager - The controller manager responsible for running generic Kubernetes logic,
64+
such as job and node_lifecycle controllers.
65+
- **KAS**: Kubernetes API Server - The core api server responsible for handling all API requests for the Kubernetes
66+
control plane. This includes things like namespace, node, pod and job resources.
67+
- **K8s/K8s**: The core kubernetes github repository.
68+
- **K8s/cloud-provider**: Any or all of the repos for each cloud provider. Examples include [cloud-provider-gcp](https://github.com/kubernetes/cloud-provider-gcp),
69+
[cloud-provider-aws](https://github.com/kubernetes/cloud-provider-aws) and [cloud-provider-azure](https://github.com/kubernetes/cloud-provider-azure).
70+
We have created these repos for each of the in-tree cloud providers. This document assumes in various places that the
71+
cloud providers will place the relevant code in these repos. Whether this is a long-term solution to which additional
72+
cloud providers will be added, or an incremental step toward moving out of the Kubernetes org is out of scope of this
73+
document, and merits discussion in a broader forum and input from SIG-Architecture and Steering Committee.
74+
- **K8s SIGs/library**: Any SIG owned repository.
75+
- **Staging**: Staging: Separate repositories which are currently visible under the K8s/K8s repo, which contain code
76+
considered to be safe to be vendored outside of the K8s/K8s repo and which should eventually be fully separated from
77+
the K8s/K8s repo. Contents of Staging are prevented from depending on code in K8s/K8s which are not in Staging.
78+
Controlled by [publishing kubernetes-rules-configmap](https://github.com/kubernetes/publishing-bot/blob/master/configs/kubernetes-rules-configmap.yaml)
5879

5980
## Summary
6081

@@ -154,7 +175,8 @@ easily, therefore, this will be addressed with Flex Volumes (Discussed under a s
154175

155176
The kube-controller-manager has many controller loops. [See NewControllerInitializers](https://github.com/kubernetes/kubernetes/blob/release-1.9/cmd/kube-controller-manager/app/controllermanager.go#L332)
156177

157-
- [nodeController](https://github.com/kubernetes/kubernetes/tree/release-1.9/pkg/controller/node)
178+
- [nodeIpamController](https://github.com/kubernetes/kubernetes/tree/release-1.10/pkg/controller/nodeipam)
179+
- [nodeLifecycleController](https://github.com/kubernetes/kubernetes/tree/release-1.10/pkg/controller/nodelifecycle)
158180
- [volumeController](https://github.com/kubernetes/kubernetes/tree/release-1.9/pkg/controller/volume)
159181
- [routeController](https://github.com/kubernetes/kubernetes/tree/release-1.9/pkg/controller/route)
160182
- [serviceController](https://github.com/kubernetes/kubernetes/tree/release-1.9/pkg/controller/service)
@@ -167,14 +189,23 @@ The kube-controller-manager has many controller loops. [See NewControllerInitial
167189

168190
Among these controller loops, the following are cloud provider dependent.
169191

170-
- [nodeController](https://github.com/kubernetes/kubernetes/tree/release-1.9/pkg/controller/node)
192+
- [nodeIpamController](https://github.com/kubernetes/kubernetes/tree/release-1.10/pkg/controller/nodeipam)
193+
- [nodeLifecycleController](https://github.com/kubernetes/kubernetes/tree/release-1.10/pkg/controller/nodelifecycle)
171194
- [volumeController](https://github.com/kubernetes/kubernetes/tree/release-1.9/pkg/controller/volume)
172195
- [routeController](https://github.com/kubernetes/kubernetes/tree/release-1.9/pkg/controller/route)
173196
- [serviceController](https://github.com/kubernetes/kubernetes/tree/release-1.9/pkg/controller/service)
174197

175-
The nodeController uses the cloudprovider to check if a node has been deleted from the cloud. If cloud provider reports
176-
a node as deleted, then this controller immediately deletes the node from kubernetes. This check removes the need to
177-
wait for a specific amount of time to conclude that an inactive node is actually dead.
198+
The nodeIpamController uses the cloudprovider to handle cloud specific CIDR assignment of a node. Currently the only
199+
cloud provider using this functionality is GCE. So the current plan is to break this functionality out of the common
200+
verion of the nodeIpamController. Most cloud providers can just run the default version of this controller. However any
201+
cloud provider which needs cloud specific version of this functionality and disable the default version running in the
202+
KCM and run their own version in the CCM.
203+
204+
The nodeLifecycleController uses the cloudprovider to check if a node has been deleted from/exists in the cloud.
205+
If cloud provider reports a node as deleted, then this controller immediately deletes the node from kubernetes.
206+
This check removes the need to wait for a specific amount of time to conclude that an inactive node is actually dead.
207+
The current plan is to move this functionality into its own controller, allowing the nodeIpamController to remain in
208+
K8s/K8s and the Kube Controller Manager.
178209

179210
The volumeController uses the cloudprovider to create, delete, attach and detach volumes to nodes. For instance, the
180211
logic for provisioning, attaching, and detaching a EBS volume resides in the AWS cloudprovider. The volumeController

0 commit comments

Comments
 (0)