Docs
api
UK8S Service(UK8S)
AddUK8SUHostNode

Add Node (UHost) - AddUK8SUHostNode

Overview

Add a Node node to the UK8S cluster, the machine type is UHost.

Definition

Public Parameters

Parameter NameTypeDescription InformationRequired
ActionstringCorresponding API command name, the current API is AddUK8SUHostNode.Yes
PublicKeystringThe user’s public key can be obtained from ConsoleYes
SignaturestringUser signature generated based on public key and API command, see Signature AlgorithmYes

Request Parameters

Parameter NameTypeDescription InformationRequired
ZonestringAvailability Zone. See Availability Zone ListYes
ProjectIdstringProject ID. If not filled in, the default project is used, sub-accounts must be filled in. Please refer to the GetProjectList interface.No
RegionstringRegion. See List of Regions and Availability ZonesYes
ClusterIdstringUK8S Cluster ID. Can be obtained from the UK8S control panel.Yes
CPUintNumber of virtual CPU cores. Optional parameters: 2-64 (refer to the console for the specific relationship between the machine type and CPU). Default value: 4.Yes
CountintCreate Node node quantity, the value range is [1,50].Yes
PasswordstringNode node password. Please set the password according to the field specification. The password needs to be encoded with base64, as follows: # echo -n Password1 | base64Yes
MemintMemory size. Unit: MB. Range: [4096, 262144], multiples of 1024 (optional range refer to the console). Default value: 8192Yes
ChargeTypestringBilling Mode. Enumeration values are:

> Year, pay annually;

> Month, pay monthly;

> Dynamic, prepaid hourly;

> Postpay, postpaid hourly (supports no charge when shut down, currently only supported in some available zones, please contact your customer manager)

Default is monthly payment.
Yes
BootDiskTypestringDisk type. Please refer to Disk Type. The default is SSD cloud disk.No
BootDiskSizeintSystem disk size, in GB. Default is 40. Range: [40, 500]. Please note that SSD local disk cannot be adjusted.No
DataDiskTypestringDisk type. Please refer to Disk Type. The default is SSD cloud disk.No
DataDiskSizeintData disk size, in GB. Default is 0. Range: [20, 1000]No
QuantityintPurchase duration. Default: 1. This parameter is not required when purchasing hourly (Dynamic). When paying monthly, pass this parameter as 0, which represents purchase until the end of the month.No
MachineTypestringCloud host machine type. Enumeration values [“N”, “C”, “G”, “O”, “OS”]. Refer to Cloud host machine type description.No
GpuTypestringGPU type, enumeration values [“K80”, “P40”, “V100”,], required when MachineType is GNo
GPUintNumber of GPU card cores. Only GPU models support this field (optional range related to MachineType+GpuType).No
LabelsstringNode labels. In the form of key=value, multiple groups are separated by ”,”, up to 5 groups. For example, env=pro,type=gameNo
MaxPodsintDefault is 110, it is recommended to be less than or equal to 110 in the production environment.No
IsolationGroupstringIsolation Group ID for hardware. Can be obtained through DescribeIsolationGroup.No
ImageIdstringImage Id, if not filled, the backend program will automatically select an available Image Id. It supports user-defined images, and user-defined images must be based on basic images.No
SubnetIdstringSubnet ID. The default is the subnet ID filled in when the cluster is created, or you can fill in the subnet ID within the same VPC as the cluster.No
DisableSchedulebooleanIndicates whether to temporarily disable the node after adding it. Enter “true” to disable, enter anything else or leave it blank to not disable.No
UserDatastringUser-defined data. This field can be filled when the image supports the Cloud-init Feature. Note: 1. The total data size does not exceed 16K; 2. Use base64 encoding.No
InitScriptstringUser-defined Shell script. The difference from UserData is that InitScript is executed after the node initialization is completed, while UserData is executed during the initialization of the cloud host.No
MinimalCpuPlatformstringLowest CPU platform, enumeration values [“Intel/Auto”, “Intel/IvyBridge”, “Intel/Haswell”, “Intel/Broadwell”, “Intel/Skylake”, “Intel/Cascadelake”, “Intel/CascadelakeR”, “Amd/Epyc2”, “Amd/Auto”], the default value is “Intel/Auto”.No
TaintsstringNode taints, in the form of key=value:effect, multiple taints are separated by ”,”, up to five groups are supported.No
TagstringBusiness GroupNo
NodeGroupIdstringNode Pool IDNo

Response Field

Field NameTypeDescription InformationRequired
RetCodeintReturn status code. If it is 0, it means successful return. If it is not 0, it means failure.Yes
ActionstringOperation command name.Yes
MessagestringReturns an error message, providing detailed description when RetCode is non-zero.No
NodeIdsarray[string]Collection of Node Instance IdsNo

Example

Request Example

https://api.dezai.com/?Action=AddUK8SUHostNode
&Zone=HjafOmlI
&ProjectId=QhySZaWP
&Region=ofGfDPlB
&ClusterId=PDncjlGz
&NodeCpu=3
&NodeNum=4
&Password=immkVITW
&NodeMem=4
&ChargeType=GLtOpVbU
&NodeUHostType=fjbWacib
&NodeBootDiskType=BcUliGXM
&NodeDataDiskType=HkETvOPs
&NodeDataDiskSize=axIciunR
&NodeDiskType=kFeAdCpF
&NodeDiskSize=5
&Quantity=2
&MachineType=MpjsOzvE
&MinmalCpuPlatform=mdRRKIma
&GpuType=PaxzMqMa
&GPU=cXzHPXgm
&Labels=vUeEMXvc
&Kubelet.MaxPods=8
&IsolationGroup=wuiIQmnd
&SubnetId=GziWrdTB
&ImageId=XyBBPJwo
&DisableSchedule=CYWxsWrP
&UserData=hOaOlcSE
&InitScript=QqwXgCtj
&Taints=AySpTyWA
&Tag=madApXSs
&NodeGroupId=ypaIEiSw
&BootDiskSize=9

Response Example

{
  "Action": "AddUK8SUHostNodeResponse",
  "Message": "XcuSztKl",
  "NodeId": [
    "dKbhpRvd"
  ],
  "NodeIds": [
    "WoyWlKQx"
  ],
  "RetCode": 0
}