@pulumi/hcloud
Version:
A Pulumi package for creating and managing hcloud cloud resources.
137 lines (136 loc) • 3.47 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
/**
* Provides details about a specific Hetzner Cloud Server Type.
*
* Use this resource to get detailed information about specific Server Type.
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as hcloud from "@pulumi/hcloud";
*
* const byId = hcloud.getServerType({
* id: 22,
* });
* const byName = hcloud.getServerType({
* name: "cx22",
* });
* const main = new hcloud.Server("main", {
* name: "my-server",
* location: "fsn1",
* image: "debian-12",
* serverType: byName.then(byName => byName.name),
* });
* ```
*/
export declare function getServerType(args?: GetServerTypeArgs, opts?: pulumi.InvokeOptions): Promise<GetServerTypeResult>;
/**
* A collection of arguments for invoking getServerType.
*/
export interface GetServerTypeArgs {
/**
* ID of the Server Type.
*/
id?: number;
/**
* Name of the Server Type.
*/
name?: string;
}
/**
* A collection of values returned by getServerType.
*/
export interface GetServerTypeResult {
/**
* Architecture of the cpu for a Server of this type.
*/
readonly architecture: string;
/**
* Number of cpu cores for a Server of this type.
*/
readonly cores: number;
/**
* Type of cpu for a Server of this type.
*/
readonly cpuType: string;
/**
* Date of the Server Type deprecation announcement.
*/
readonly deprecationAnnounced: string;
/**
* Description of the Server Type.
*/
readonly description: string;
/**
* Disk size in GB for a Server of this type.
*/
readonly disk: number;
/**
* ID of the Server Type.
*/
readonly id?: number;
/**
* @deprecated The field is deprecated and will always report 0 after 2024-08-05.
*/
readonly includedTraffic: number;
/**
* Whether the Server Type is deprecated.
*/
readonly isDeprecated: boolean;
/**
* Memory in GB for a Server of this type.
*/
readonly memory: number;
/**
* Name of the Server Type.
*/
readonly name?: string;
/**
* Type of boot drive for a Server of this type.
*/
readonly storageType: string;
/**
* Date of the Server Type removal. After this date, the Server Type cannot be used anymore.
*/
readonly unavailableAfter: string;
}
/**
* Provides details about a specific Hetzner Cloud Server Type.
*
* Use this resource to get detailed information about specific Server Type.
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as hcloud from "@pulumi/hcloud";
*
* const byId = hcloud.getServerType({
* id: 22,
* });
* const byName = hcloud.getServerType({
* name: "cx22",
* });
* const main = new hcloud.Server("main", {
* name: "my-server",
* location: "fsn1",
* image: "debian-12",
* serverType: byName.then(byName => byName.name),
* });
* ```
*/
export declare function getServerTypeOutput(args?: GetServerTypeOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output<GetServerTypeResult>;
/**
* A collection of arguments for invoking getServerType.
*/
export interface GetServerTypeOutputArgs {
/**
* ID of the Server Type.
*/
id?: pulumi.Input<number>;
/**
* Name of the Server Type.
*/
name?: pulumi.Input<string>;
}