UNPKG

@pulumi/gcp

Version:

A Pulumi package for creating and managing Google Cloud Platform resources.

91 lines (90 loc) 3.25 kB
import * as pulumi from "@pulumi/pulumi"; /** * Provides available node types for Compute Engine sole-tenant nodes in a zone * for a given project. For more information, see [the official documentation](https://cloud.google.com/compute/docs/nodes/#types) and [API](https://cloud.google.com/compute/docs/reference/rest/v1/nodeTypes). * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as gcp from "@pulumi/gcp"; * * const central1b = gcp.compute.getNodeTypes({ * zone: "us-central1-b", * }); * const tmpl = new gcp.compute.NodeTemplate("tmpl", { * name: "test-tmpl", * region: "us-central1", * nodeType: types.names[0], * }); * ``` */ export declare function getNodeTypes(args?: GetNodeTypesArgs, opts?: pulumi.InvokeOptions): Promise<GetNodeTypesResult>; /** * A collection of arguments for invoking getNodeTypes. */ export interface GetNodeTypesArgs { /** * ID of the project to list available node types for. * Should match the project the nodes of this type will be deployed to. * Defaults to the project that the provider is authenticated with. */ project?: string; /** * The zone to list node types for. Should be in zone of intended node groups and region of referencing node template. If `zone` is not specified, the provider-level zone must be set and is used * instead. */ zone?: string; } /** * A collection of values returned by getNodeTypes. */ export interface GetNodeTypesResult { /** * The provider-assigned unique ID for this managed resource. */ readonly id: string; /** * A list of node types available in the given zone and project. */ readonly names: string[]; readonly project: string; readonly zone: string; } /** * Provides available node types for Compute Engine sole-tenant nodes in a zone * for a given project. For more information, see [the official documentation](https://cloud.google.com/compute/docs/nodes/#types) and [API](https://cloud.google.com/compute/docs/reference/rest/v1/nodeTypes). * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as gcp from "@pulumi/gcp"; * * const central1b = gcp.compute.getNodeTypes({ * zone: "us-central1-b", * }); * const tmpl = new gcp.compute.NodeTemplate("tmpl", { * name: "test-tmpl", * region: "us-central1", * nodeType: types.names[0], * }); * ``` */ export declare function getNodeTypesOutput(args?: GetNodeTypesOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output<GetNodeTypesResult>; /** * A collection of arguments for invoking getNodeTypes. */ export interface GetNodeTypesOutputArgs { /** * ID of the project to list available node types for. * Should match the project the nodes of this type will be deployed to. * Defaults to the project that the provider is authenticated with. */ project?: pulumi.Input<string>; /** * The zone to list node types for. Should be in zone of intended node groups and region of referencing node template. If `zone` is not specified, the provider-level zone must be set and is used * instead. */ zone?: pulumi.Input<string>; }