The cloud controller manager (CCM) can integrate Kubernetes with basic services of Alibaba Cloud, such as Classic Load Balancer (CLB). This topic describes how to install and use the CCM in a registered cluster.
Prerequisites
A registered cluster is created. For more information, see Create a registered cluster in the ACK console and Use onectl to create a registered cluster.
A kubectl client is connected to the registered cluster. For more information, see Obtain the kubeconfig file of a cluster and use kubectl to connect to the cluster.
Features
Manage CLB instances
If you set Type=LoadBalancer
for a Service, the CCM automatically creates a CLB instance for the Service, and configures listeners and vServer groups. When the CCM identifies endpoint changes in the vServer groups associated with a Service or cluster node changes, the CCM automatically updates the vServer groups.
The CLB vServer groups in this topic refer to nodes on Alibaba Cloud.
Install and use the CCM
Use onectl
Install onectl on your on-premises machine. For more information, see Use onectl to manage registered clusters.
Run the following command to install the CCM:
onectl addon install cloud-controller-manager
Expected output:
Addon cloud-controller-manager, version **** installed.
Use the console
Log on to the ACK console. In the left-side navigation pane, click Clusters.
On the Clusters page, click the name of the cluster that you want to manage and choose
in the left-side navigation pane.On the Add-ons page, click the Core Components tab, find the Cloud Controller Manager card, and click Install in the lower-right part of the card.
After the CCM is installed, you can use the CCM in the following ways.
The CCM automatically creates CLB instances for Services, and configures listeners and vServer groups. For more information, see Considerations for configuring a LoadBalancer type Service.
The CCM allows you to add annotations to Service configurations to customize load balancing. For more information, see Add annotations to the YAML file of a Service to configure CLB instances.