Help Center/ Cloud Container Engine/ Skill Reference/ Huawei Cloud Cloud-Native Skill Best Practices/ Scheduling CCE Workloads to CCI 2.0 Using AI CLI and Skills
Updated on 2026-06-05 GMT+08:00

Scheduling CCE Workloads to CCI 2.0 Using AI CLI and Skills

CCE Cloud Bursting Engine for CCI is a virtual kubelet that extends Kubernetes APIs to CCI. It allows CCE workloads to be created on CCI 2.0 in short-term high-load scenarios. This section describes how to use AI CLI to load cce-cci-bursting-deployer and complete the entire process from cluster pre-check to scaling verification with a single prompt.

Constraints

Environment and Function Constraints

  • Only CCE standard and CCE Turbo clusters that use the VPC network model are supported.
  • The subnet where a cluster is located cannot overlap with 10.247.0.0/16, or the subnet conflicts with the Service CIDR block in the CCI namespace.
  • DaemonSets are not supported.
  • After the CCE Cloud Bursting Engine for CCI add-on is installed, a namespace named bursting-{cluster-ID} will be created in CCI and managed by the add-on. Do not use this namespace directly in CCI.
  • For details about the Kubernetes versions and constraints, see Functions of CCE Cloud Bursting Engine for CCI.

IAM Permission Requirements

API Action

Permission

Purpose

cce:cluster:get

Obtaining cluster details

Read cluster network specifications (VPC, subnet, and ENI).

cce:addon:list

Listing add-ons

Check the installation status of virtual-kubelet.

cce:addon:create

Creating an add-on

Install the virtual-kubelet add-on.

cce:addon:update

Updating an add-on

Configure bursting parameters.

vpcep:endpoint:create

Creating VPC endpoints

Create VPC endpoints for SWR and OBS.

vpcep:endpoint:list

Listing VPC endpoints

Check existing VPC endpoints.

vpcep:service:list

Listing VPCEP services

Discover public service details.

vpc:subnet:list

Listing subnets

Verify subnet IDs.

vpc:routetable:list

Listing route tables

Query the ID of the OBS gateway route table.

Prerequisites

  • Before using the CCE Cloud Bursting Engine for CCI add-on, you have granted CCI permissions to use CCE on the CCI console.
  • If you use CCI 2.0 to interconnect with the CCE Cloud Bursting Engine for CCI add-on, purchase VPC endpoints. For details, see Environment Configuration.
  • You have installed AI CLI and configured the Huawei Cloud credential environment variables HUAWEI_AK, HUAWEI_SK, and HUAWEI_PROJECT_ID.
  • You have created a CCE standard or CCE Turbo cluster that uses the VPC network model. The Kubernetes version is 1.21 or later.
  • You have obtained the OBS VPCEP service name. The VPC endpoint for OBS requires accurate obs_endpoint_service_name. The value needs to be obtained from the Huawei Cloud service ticket and cannot be inferred from the public service name in a similar region. If this value is not provided in advance, the configuration process will be interrupted during VPC endpoint creation and will only continue after you provide the value. Before the configuration, obtain and record the information through a service ticket to avoid process interruption.

Procedure

Step 1: Create a CCE Turbo Cluster

Create a CCE Turbo cluster and record the cluster ID and region. If a cluster that meets the requirements already exists, skip this step.

Step 2: Enable Auto Scaling Using AI CLI

cce-cci-bursting-deployer uses a preview-first design. Read operations (precheck, verify, discover, and diagnose) can be executed immediately, while a preview solution of write operations (VPC endpoint creation, add-on installation, and workload deployment) is returned first. The write operations are executed only after user confirmation.

Enter the following prompt in AI CLI to start the entire process:

I need to enable auto scaling of CCI 2.0 for my CCE cluster (cluster ID: xxx, region: cn-north-4).
Please follow the complete process: precheck → VPC endpoint creation → add-on installation → smoke test deployment → verification.
Preview each write operation before executing it.

The Skill will automatically proceed in the following sequence: (Each step involving a write operation will be paused for confirmation.)

  1. Cluster precheck

    The Skill invokes huawei_precheck_cce_cci_bursting to automatically parse the cluster network topology, distinguishes the subnet roles of cci_subnet_id (Neutron UUID) and vpcep_subnet_id (VPC UUID), checks the status of the virtual-kubelet add-on, and performs NodeCheck to check the physical node's addon headroom.

  2. Node capacity check (NodeCheck)

    If the precheck report indicates that physical node resources are insufficient, the Skill invokes huawei_check_cce_cci_node_capacity to view capacity details and preview the node pool scale-out solution. After user confirmation, the scale-out is performed.

  3. VPC endpoint creation

    The Skill invokes huawei_ensure_cce_cci_vpcep to automatically discover and create VPC endpoints compatible with SWR and OBS. Existing VPC endpoints are automatically reused and will not be created again.

    The VPC endpoint for OBS requires accurate obs_endpoint_service_name. The value needs to be obtained from the Huawei Cloud service ticket and cannot be inferred from the public service name in a similar region. If this value is not obtained in advance, the Skill will be interrupted in this step and prompt you to provide the value. After obs_endpoint_service_name is added, the Skill continues to create the VPC endpoint for OBS and resumes the subsequent process.

  4. Add-on installation

    The Skill invokes huawei_setup_cce_cci_bursting to install or update the virtual-kubelet add-on after confirming that the VPC endpoint dependencies are ready. It automatically parses and writes the region project ID. This operation is idempotent. The existing add-on is only updated, and will not be uninstalled and reinstalled.

  5. Auto scaling readiness verification

    The Skill invokes huawei_verify_cce_cci_bursting to check whether the virtual-kubelet add-on and the bursting-node are ready. If the verification fails, the Skill invokes huawei_diagnose_cce_cci_bursting_addon to return a structured diagnosis report.

  6. Smoke test deployment

    The Skill invokes huawei_discover_cce_cci_smoke_images to discover the tenant's image in SWR Basic Edition and then invokes huawei_deploy_cce_cci_smoke_workload to create a Deployment. The Deployment automatically adds the bursting.cci.io/burst-to-cci: enforce label to forcibly schedule the workload to CCI. If the image parameter is not specified, the discovered tenant image is automatically used.

  7. Final verification

    The Skill invokes huawei_verify_cce_cci_bursting again to ensure that all pods are in the Running state on the CCI virtual node and are visible on the CCE console.

Step 3: Configure a ScheduleProfile Policy

After the basic auto scaling configuration is complete, you can create a ScheduleProfile to control workload scheduling.

Scheduling Policy

Description

Scenario

localPrefer

Workloads are preferentially scheduled to CCE. If resources are insufficient, workloads are scheduled to CCI.

Routine scale-out

enforce

Workloads are forcibly scheduled to CCI.

Test verification and temporary CI/CD tasks

auto

Workloads will be scheduled to the CCE cluster or CCI based on the scoring results provided by the scheduler.

Flexible scheduling

Enter the following prompt in AI CLI to create a ScheduleProfile:

Help me create a ScheduleProfile in the default namespace.
Match the app=nginx label and set the policy to localPrefer.
The maximum number of local instances is 20, and the CCI scale-in priority is 10.

The label policy has a higher priority than the ScheduleProfile. If a pod has both the bursting.cci.io/burst-to-cci: off label and the enforce profile, the pod will not be scheduled to CCI.

The auto scaling configuration and scheduling policy for scheduling CCE workloads to CCI 2.0 are complete.

Common Issues and Diagnosis Methods

If you encounter any issues during auto scaling configuration, you can describe the issue in AI CLI. The Skill will invoke the corresponding diagnosis tool to return a structured report.

Symptom

Diagnosis Prompt

CCI Pod ImagePullBackOff or image pull timeout

Failed to pull the CCI pod image. Please diagnose.

Virtual node not ready

The virtual node is not ready. Please diagnose the add-on.

addon Pod Pending or repeatedly restarting

The add-on pod is pending. Help me check the node capacity

"region mismatch" in the add-on log

The add-on log reports a region mismatch. Please diagnose.

IAM denied or project ID missing in the add-on log

The add-on reports IAM denied. Please diagnose.

OBS gateway node failed; VPC endpoint creation failed

Failed to create the VPC endpoint for OBS. Use the service name (actual obs_endpoint_service_name) obtained from the Huawei Cloud service ticket to try again.