@huaweicloudos/pulumi
Version:
A Pulumi package for creating and managing Huaweicloud cloud resources.
180 lines (179 loc) • 4.9 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
import { output as outputs } from "../types";
/**
* To get the specified node pool in a cluster.
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as huaweicloud from "@pulumi/huaweicloud";
*
* const config = new pulumi.Config();
* const clusterId = config.requireObject("clusterId");
* const nodePoolName = config.requireObject("nodePoolName");
* const nodePool = huaweicloud.Cce.getNodePool({
* clusterId: clusterId,
* name: nodePoolName,
* });
* ```
*/
export declare function getNodePool(args: GetNodePoolArgs, opts?: pulumi.InvokeOptions): Promise<GetNodePoolResult>;
/**
* A collection of arguments for invoking getNodePool.
*/
export interface GetNodePoolArgs {
/**
* Specifies the ID of container cluster.
*/
clusterId: string;
/**
* Specifies the name of the node pool.
*/
name?: string;
/**
* Specifies the ID of the node pool.
*/
nodePoolId?: string;
/**
* Specifies the region in which to obtain the CCE node pools.
* If omitted, the provider-level region will be used.
*/
region?: string;
/**
* Specifies the state of the node pool.
*/
status?: string;
}
/**
* A collection of values returned by getNodePool.
*/
export interface GetNodePoolResult {
/**
* The name of the available partition (AZ).
*/
readonly availabilityZone: string;
readonly clusterId: string;
/**
* Current number of nodes in the node pool.
*/
readonly currentNodeCount: number;
/**
* Represents the data disk to be created. Structure is documented below.
*/
readonly dataVolumes: outputs.Cce.GetNodePoolDataVolume[];
/**
* The enterprise project ID of the node pool.
*/
readonly enterpriseProjectId: string;
/**
* Extended parameter.
*/
readonly extendParam: {
[key: string]: string;
};
/**
* The flavor ID.
*/
readonly flavorId: string;
/**
* The hostname config of the kubernetes node.
* The object structure is documented below.
*/
readonly hostnameConfigs: outputs.Cce.GetNodePoolHostnameConfig[];
/**
* The provider-assigned unique ID for this managed resource.
*/
readonly id: string;
/**
* Initial number of nodes in the node pool.
*/
readonly initialNodeCount: number;
/**
* Key pair name when logging in to select the key pair mode.
*/
readonly keyPair: string;
/**
* Tags of a Kubernetes node, key/value pair format.
*/
readonly labels: {
[key: string]: string;
};
/**
* Maximum number of nodes allowed if auto scaling is enabled.
*/
readonly maxNodeCount: number;
/**
* The maximum number of instances a node is allowed to create.
*/
readonly maxPods: number;
/**
* Minimum number of nodes allowed if auto scaling is enabled.
*/
readonly minNodeCount: number;
readonly name: string;
readonly nodePoolId: string;
/**
* Operating System of the node.
*/
readonly os: string;
/**
* Weight of a node pool. A node pool with a higher weight has a higher priority during scaling.
*/
readonly priority: number;
readonly region: string;
/**
* It corresponds to the system disk related configuration. Structure is documented below.
*/
readonly rootVolumes: outputs.Cce.GetNodePoolRootVolume[];
/**
* Interval between two scaling operations, in minutes.
*/
readonly scaleDownCooldownTime: number;
/**
* Whether auto scaling is enabled.
*/
readonly scallEnable: boolean;
readonly status: string;
/**
* The ID of the subnet to which the NIC belongs.
*/
readonly subnetId: string;
/**
* Tags of a VM node, key/value pair format.
*/
readonly tags: {
[key: string]: string;
};
/**
* The hostname type of the kubernetes node.
*/
readonly type: string;
}
export declare function getNodePoolOutput(args: GetNodePoolOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output<GetNodePoolResult>;
/**
* A collection of arguments for invoking getNodePool.
*/
export interface GetNodePoolOutputArgs {
/**
* Specifies the ID of container cluster.
*/
clusterId: pulumi.Input<string>;
/**
* Specifies the name of the node pool.
*/
name?: pulumi.Input<string>;
/**
* Specifies the ID of the node pool.
*/
nodePoolId?: pulumi.Input<string>;
/**
* Specifies the region in which to obtain the CCE node pools.
* If omitted, the provider-level region will be used.
*/
region?: pulumi.Input<string>;
/**
* Specifies the state of the node pool.
*/
status?: pulumi.Input<string>;
}