API Overview

APIs provided by Cloud Container Instance (CCI) are classified into two types: proprietary APIs and Kubernetes-native APIs. With these APIs, you can use all functions provided by CCI, including creating Deployments and StatefulSets.

Type

Subtype

Description

CCI proprietary APIs

Network

Manage networks, including creating, querying, modifying, and deleting networks.

Network is a new object in CCI that defines the mapping relationship between a network of a namespace in Kubernetes and HUAWEI CLOUD VPC and subnet.

Extended PersistentVolumeClaim

Manage extended PersistentVolumeClaims (PVCs), including importing storage devices, querying imported PVCs, and unbinding storage devices.

Kubernetes-native APIs

Namespace

Manage namespaces, including creating, querying, modifying, and deleting namespaces.

A namespace provides a method of allocating resources among multiple users. When you have a large number of projects and personnel, you can define namespaces by project attributes, such as production, test, and development.

Pod

Manage pods, including querying pods.

A pod is the smallest and simplest unit in the Kubernetes object model that you create or deploy. A pod encapsulates one or more containers, storage resources, an independent network IP address, and a policy for managing container running.

Deployment

Manage Deployments, including creating, querying, modifying, and deleting Deployments.

Deployment is a type of pod controller. A Deployment can contain one or more pod replicas. Each pod replica has the same role. Therefore, the system automatically distributes requests to multiple pod replicas of a Deployment. All pod replicas in a Deployment share storage volumes.

StatefulSet

Manage StatefulSets, including creating, querying, modifying, and deleting StatefulSets.

StatefulSet is also a type of pod controller. A StatefulSet can contain one or more pod replicas. Different pod replicas have different roles and each of them has an independent access domain name. Therefore, you need to manually specify request distribution paths for these pod replicas. Different pod replicas in a StatefulSet do not share data. Therefore, each pod replica is allocated with an independent storage volume.

Job

Manage jobs, including creating, querying, modifying, and deleting jobs.

A job is a resource object that Kubernetes uses to control batch tasks. Jobs are different from long-term servo tasks (such as Deployments and StatefulSets). The former are started and terminated at specific times, while the latter run unceasingly unless being terminated. The pods managed by a job automatically exit after successfully completing the job based on user configurations.

Service

Manage Services, including creating, querying, modifying, and deleting Services.

A Service (sometimes referred to as a microservice) defines a logical set of pods and a policy to access them.

Ingress

Manage ingresses, such as creating, querying, modifying, and deleting ingresses.

An ingress is a set of rules that allow access from outside a cluster to Services within the cluster. You can configure externally-accessible URLs, load balancers, SSL, and name-based virtual hosts for an ingress.

ConfigMap

Manage ConfigMaps, including creating, querying, modifying, and deleting ConfigMaps.

Secret

Manage secrets, such as creating, querying, modifying, and deleting secrets.

PersistentVolumeClaim

Manage PVCs, including creating, querying, modifying, and deleting PVCs.

A PVC is a request for and claim to a PersistentVolume (PV). Similar to a pod that requests CPU and memory resources, a PVC requests storage resources.

Event

Manage events, such as querying events.

API Groups

Query API resources in each group.

Endpoint

Manage endpoints, including querying endpoints.

ReplicaSet

Manage ReplicaSets, including querying ReplicaSets.

VolcanoJob

Manage Volcano jobs, including creating, querying, modifying, and deleting Volcano jobs.

TFJob

TensorFlow Training (TFJob) is a TensorFlow-based Kubernetes custom resource that you can use to run standalone or distributed TensorFlow training jobs.

MXJob

MXNet job (MXJob) is an MXNet-based Kubernetes custom resource that you can use to run MXNet training jobs.

PyTorchJob

PyTorch job (PyTorchJob) is a PyTorch-based Kubernetes custom resource that you can use to run PyTorch training jobs.

RBAC

Authorize users or user groups to perform operations on different Kubernetes resources.

Network

API

Description

Creating a Network

Create a network.

Network is a new object in CCI that defines the mapping relationship between a network of a namespace in Kubernetes and HUAWEI CLOUD VPC and subnet.

Reading a Network

Query a network.

Listing Networks

List all networks under a specified namespace.

Reading the Status of a Network

Read the status of a specified network.

Deleting a Network

Delete a specified network.

Deleting All Networks

Delete all networks under a specified namespace.

Extended PersistentVolumeClaim

API

Description

Importing a Storage Device

Import the existing storage to a specified namespace.

Reading Imported PVCs

Query PVCs under a specified namespace.

Unbinding a Storage Device

Unbind a storage device from a specified namespace. This API is an extension of the native API for deleting the storage. It has been added with two parameters that specify the storage class and whether to delete the volume, respectively.

Namespace

API

Description

Creating a Namespace

Create a namespace.

Reading a Namespace

Read the details about a specified namespace.

Listing Namespaces

List all namespaces of a user.

Deleting a Namespace

Delete a namespace.

Pod

API

Description

Creating a Pod

Create a pod.

Reading a Pod

Read the details about a specified pod.

Reading All Pods Under a Specified Namespace

Read the details about all pods under a specified namespace.

Reading the Status of a Pod

Read the status of a specified pod.

Reading Pod Logs

Read the logs of a specified pod.

Listing All Pods of a User

List all pods of a user.

Replacing a Pod

Replace a specified pod.

Updating a Pod

Update a specified pod.

Deleting a Pod

Delete a specified pod.

Deleting All Pods

Delete all pods under a specified namespace.

Deployment

API

Description

Creating a Deployment

Create a deployment.

Reading a Deployment

Read the details about a specified deployment.

Reading All Deployments Under a Namespace

Read the details about all Deployments under a specified namespace.

Reading the Status of a Deployment

Read the status of a specified Deployment.

Reading the Scaling Operation of a Specified Deployment

Read the scaling operation of a specified Deployment.

Listing All Deployments of a User

List all Deployments of a user.

Replacing a Deployment

Replace a specified Deployment.

Replacing the Scaling Operation of a Specified Deployment

Replace the scaling operation of a specified Deployment.

Updating a Deployment

Update a specified Deployment.

Updating the Scaling Operation of a Specified Deployment

Update the scaling operation of a specified Deployment.

Deleting a Deployment

Delete a specified Deployment.

Deleting All Deployments

Delete all Deployments under a specified namespace.

StatefulSet

API

Description

Creating a StatefulSet

Create a StatefulSet.

Reading a StatefulSet

Read the details about a specified StatefulSet.

Reading All StatefulSets Under a Specified Namespace

Read the details about all StatefulSets under a specified namespace.

Reading the Status of a StatefulSet

Read the status of a specified StatefulSet.

Listing All StatefulSets of a User

List all StatefulSets of a user.

Replacing a StatefulSet

Replace a specified StatefulSet.

Updating a StatefulSet

Update a specified StatefulSet.

Deleting a StatefulSet

Delete a specified StatefulSet.

Deleting All StatefulSets

Delete all StatefulSets under a specified namespace.

Job

API

Description

Creating a Job

Create a job.

Reading a Job

Read the details about a specified job.

Reading All Jobs Under a Specified Namespace

Read the details about all jobs under a specified namespace.

Reading the Status of a Job

Read the status of a specified job.

Listing All Jobs of a User

List all jobs of a user.

Replacing a Job

Replace a specified job.

Updating a Job

Update a specified job.

Deleting a Job

Delete a specified job.

Deleting All Jobs

Delete all jobs under a specified namespace.

Service

API

Description

Creating a Service

Create a Service.

Reading a Service

Read the details about a specified Service.

Listing Services

Read the details about all Services under a specified namespace.

Reading the Status of a Service

Read the status of a specified Service.

Deleting a Service

Delete a specified Service.

Ingress

API

Description

Creating an Ingress

Create an ingress.

Reading an Ingress

Read the details about a specified ingress.

Listing Ingresses

Read the details about all ingresses under a specified namespace.

Reading the Status of an Ingress

Read the status of a specified ingress.

Replacing an Ingress

Replace a specified ingress.

Updating an Ingress

Update a specified ingress.

Deleting an Ingress

Delete a specified ingress.

Deleting All Ingresses

Delete all ingresses under a specified namespace.

ConfigMap

API

Description

Creating a ConfigMap

This API is used to create a ConfigMap.

Reading a ConfigMap

Read the details about a specified ConfigMap.

Listing ConfigMaps

Read the details about all ConfigMaps under a specified namespace.

Replacing a ConfigMap

Replace a specified ConfigMap.

Updating a ConfigMap

Update a specified ConfigMap.

Deleting a ConfigMap

Delete a specified ConfigMap.

Deleting All ConfigMaps

Delete all ConfigMaps under a specified namespace.

Secret

API

Description

Creating a Secret

Create a secret.

Replacing a Secret

Replace a specified secret.

Updating a Secret

Update some information about a specified secret.

Deleting a Secret

Delete a specified secret.

Deleting All Secrets

Delete all secrets under a specified namespace.

PersistentVolumeClaim

API

Description

Creating a PersistentVolumeClaim

Create a PersistentVolumeClaim.

Reading a PersistentVolumeClaim

Read a specified PersistentVolumeClaim.

Listing PersistentVolumeClaims

List all PersistentVolumeClaims under a specified namespace.

Deleting a PersistentVolumeClaim

Delete a Persistent Volume Claim.

Event

API

Description

Reading an Event

Read the details about a specified event.

Listing All Events

Read the details about all events under a specified namespace.

Deleting an Event

Delete a specified event.

API Groups

API

Description

Listing APIVersions

List all API versions.

Listing APIGroups

List all API groups.

Listing APIResources of GroupVersion extensions/v1beta1

List all APIs of the extensions/v1beata1 version.

Listing APIResources of GroupVersion apps/v1

List all APIs of the apps/v1 version.

Listing APIResources of GroupVersion apps/v1beta1

List all APIs of the apps/v1beata1 version.

Listing APIResources of GroupVersion batch/v1

List all APIs of the batch/v1 version.

Listing APIResources of GroupVersion networking.cci.io/v1beta1

List all APIs of the networwking.cci.io/v1beata1 version.

Listing APIResources of GroupVersion v1

List all APIs of the v1 version.

Endpoint

API

Description

Reading a Specified Endpoint

Read a specified endpoint.

Listing All Endpoints

List all endpoints.

ReplicaSet

API

Description

Listing All ReplicaSets

List all ReplicaSets.

VolcanoJob

API

Description

Reading All Volcano Jobs Under a Namespace

Read all Volcano jobs under a specified namespace.

Creating a Volcano Job

Create a Volcano job.

Deleting All Volcano Jobs Under a Namespace

Delete all Volcano jobs under a specified namespace.

Reading the Details of a Volcano Job

Read the details about a specified Volcano job.

Replacing a Volcano Job

Replace a specified Volcano job.

Deleting a Volcano Job

Delete a specified Volcano job.

Updating a Volcano Job

Update a specified Volcano job.

TFJob

API

Description

Creating a TFJob

Create a TFJob.

Reading a TFJob

Read the details about a specified TFJob.

Reading All TFJobs Under a Specified Namespace

Read the details about all TFJobs under a specified namespace.

Deleting All TFJobs Under a Namespace

Delete all TFJobs under a specified namespace.

Deleting a TFJob

Delete a specified TFJob.

Updating a TFJob

Update a specified TFJob.

Replacing a TFJob

Replace a specified TFJob.

MXJob

API

Description

Creating an MXJob

Create an MXJob.

Reading an MXJob

Read the details about a specified MXJob.

Reading All MXJobs Under a Specified Namespace

Read the details about all MXJobs under a specified namespace.

Deleting All MXJobs Under a Namespace

Delete all MXJobs under a specified namespace.

Deleting an MXJob

Delete a specified MXJob.

Updating an MXJob

Update a specified MXJob.

Replacing an MXJob

Replace a specified MXJob file.

PyTorchJob

API

Description

Creating a PyTorchJob

Create a PyTorchJob.

Reading a PyTorchJob

Read the details about a specified PyTorchJob.

Reading All MXJobs Under a Specified Namespace

Read the details about all PyTorchJobs under a specified namespace.

Deleting All PyTorchJobs Under a Namespace

Delete all PyTorchJobs under a specified namespace.

Deleting a PyTorchJob

Delete a specified PyTorchJob.

Updating a PyTorchJob

Update a specified PyTorchJob.

Replacing a PyTorchJob

Replace a specified PyTorchJob.

RBAC

Table 1 RBAC

API

Description

Reading a Specified ClusterRole

Read a specified ClusterRole.

Reading the ClusterRole List

Obtain the ClusterRole list.

Creating a RoleBinding

Create a RoleBinding.

Updating a Specified RoleBinding

Partially update a specified RoleBinding.

Replacing a Specified RoleBinding

Replace a specified RoleBinding.

Deleting a Specified RoleBinding

Delete a specified RoleBinding.

Reading a Specified RoleBinding

Read a specified RoleBinding.

Obtaining the RoleBinding List Under a Specified Namespace

Obtain the list of RoleBindings in a specified namespace.

Obtaining the RoleBinding List

Obtain the RoleBinding list.