UNPKG

@pulumi/openstack

Version:

A Pulumi package for creating and managing OpenStack cloud resources.

255 lines (254 loc) 8.35 kB
import * as pulumi from "@pulumi/pulumi"; /** * Manages a V2 flavor resource within OpenStack. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as openstack from "@pulumi/openstack"; * * const test_flavor = new openstack.compute.Flavor("test-flavor", { * name: "my-flavor", * ram: 8096, * vcpus: 2, * disk: 20, * extraSpecs: { * "hw:cpu_policy": "CPU-POLICY", * "hw:cpu_thread_policy": "CPU-THREAD-POLICY", * }, * }); * ``` * * ## Import * * Flavors can be imported using the `ID`, e.g. * * ```sh * $ pulumi import openstack:compute/flavor:Flavor my-flavor 4142e64b-1b35-44a0-9b1e-5affc7af1106 * ``` */ export declare class Flavor extends pulumi.CustomResource { /** * Get an existing Flavor resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state Any extra arguments used during the lookup. * @param opts Optional settings to control the behavior of the CustomResource. */ static get(name: string, id: pulumi.Input<pulumi.ID>, state?: FlavorState, opts?: pulumi.CustomResourceOptions): Flavor; /** * Returns true if the given object is an instance of Flavor. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj: any): obj is Flavor; /** * The description of the flavor. Changing this * updates the description of the flavor. Requires microversion >= 2.55. */ readonly description: pulumi.Output<string | undefined>; /** * The amount of disk space in GiB to use for the root * (/) partition. Changing this creates a new flavor. */ readonly disk: pulumi.Output<number>; /** * The amount of ephemeral in GiB. If unspecified, * the default is 0. Changing this creates a new flavor. */ readonly ephemeral: pulumi.Output<number | undefined>; /** * Key/Value pairs of metadata for the flavor. */ readonly extraSpecs: pulumi.Output<{ [key: string]: string; }>; /** * Unique ID (integer or UUID) of flavor to create. Changing * this creates a new flavor. */ readonly flavorId: pulumi.Output<string>; /** * Whether the flavor is public. Changing this creates * a new flavor. */ readonly isPublic: pulumi.Output<boolean | undefined>; /** * A unique name for the flavor. Changing this creates a new * flavor. */ readonly name: pulumi.Output<string>; /** * The amount of RAM to use, in megabytes. Changing this * creates a new flavor. */ readonly ram: pulumi.Output<number>; /** * The region in which to obtain the V2 Compute client. * Flavors are associated with accounts, but a Compute client is needed to * create one. If omitted, the `region` argument of the provider is used. * Changing this creates a new flavor. */ readonly region: pulumi.Output<string>; /** * RX/TX bandwith factor. The default is 1. Changing * this creates a new flavor. */ readonly rxTxFactor: pulumi.Output<number | undefined>; /** * The amount of disk space in megabytes to use. If * unspecified, the default is 0. Changing this creates a new flavor. */ readonly swap: pulumi.Output<number | undefined>; /** * The number of virtual CPUs to use. Changing this creates * a new flavor. */ readonly vcpus: pulumi.Output<number>; /** * Create a Flavor resource with the given unique name, arguments, and options. * * @param name The _unique_ name of the resource. * @param args The arguments to use to populate this resource's properties. * @param opts A bag of options that control this resource's behavior. */ constructor(name: string, args: FlavorArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering Flavor resources. */ export interface FlavorState { /** * The description of the flavor. Changing this * updates the description of the flavor. Requires microversion >= 2.55. */ description?: pulumi.Input<string>; /** * The amount of disk space in GiB to use for the root * (/) partition. Changing this creates a new flavor. */ disk?: pulumi.Input<number>; /** * The amount of ephemeral in GiB. If unspecified, * the default is 0. Changing this creates a new flavor. */ ephemeral?: pulumi.Input<number>; /** * Key/Value pairs of metadata for the flavor. */ extraSpecs?: pulumi.Input<{ [key: string]: pulumi.Input<string>; }>; /** * Unique ID (integer or UUID) of flavor to create. Changing * this creates a new flavor. */ flavorId?: pulumi.Input<string>; /** * Whether the flavor is public. Changing this creates * a new flavor. */ isPublic?: pulumi.Input<boolean>; /** * A unique name for the flavor. Changing this creates a new * flavor. */ name?: pulumi.Input<string>; /** * The amount of RAM to use, in megabytes. Changing this * creates a new flavor. */ ram?: pulumi.Input<number>; /** * The region in which to obtain the V2 Compute client. * Flavors are associated with accounts, but a Compute client is needed to * create one. If omitted, the `region` argument of the provider is used. * Changing this creates a new flavor. */ region?: pulumi.Input<string>; /** * RX/TX bandwith factor. The default is 1. Changing * this creates a new flavor. */ rxTxFactor?: pulumi.Input<number>; /** * The amount of disk space in megabytes to use. If * unspecified, the default is 0. Changing this creates a new flavor. */ swap?: pulumi.Input<number>; /** * The number of virtual CPUs to use. Changing this creates * a new flavor. */ vcpus?: pulumi.Input<number>; } /** * The set of arguments for constructing a Flavor resource. */ export interface FlavorArgs { /** * The description of the flavor. Changing this * updates the description of the flavor. Requires microversion >= 2.55. */ description?: pulumi.Input<string>; /** * The amount of disk space in GiB to use for the root * (/) partition. Changing this creates a new flavor. */ disk: pulumi.Input<number>; /** * The amount of ephemeral in GiB. If unspecified, * the default is 0. Changing this creates a new flavor. */ ephemeral?: pulumi.Input<number>; /** * Key/Value pairs of metadata for the flavor. */ extraSpecs?: pulumi.Input<{ [key: string]: pulumi.Input<string>; }>; /** * Unique ID (integer or UUID) of flavor to create. Changing * this creates a new flavor. */ flavorId?: pulumi.Input<string>; /** * Whether the flavor is public. Changing this creates * a new flavor. */ isPublic?: pulumi.Input<boolean>; /** * A unique name for the flavor. Changing this creates a new * flavor. */ name?: pulumi.Input<string>; /** * The amount of RAM to use, in megabytes. Changing this * creates a new flavor. */ ram: pulumi.Input<number>; /** * The region in which to obtain the V2 Compute client. * Flavors are associated with accounts, but a Compute client is needed to * create one. If omitted, the `region` argument of the provider is used. * Changing this creates a new flavor. */ region?: pulumi.Input<string>; /** * RX/TX bandwith factor. The default is 1. Changing * this creates a new flavor. */ rxTxFactor?: pulumi.Input<number>; /** * The amount of disk space in megabytes to use. If * unspecified, the default is 0. Changing this creates a new flavor. */ swap?: pulumi.Input<number>; /** * The number of virtual CPUs to use. Changing this creates * a new flavor. */ vcpus: pulumi.Input<number>; }