@pulumi/scm
Version:
A Pulumi package for managing resources on Strata Cloud Manager.. Based on terraform-provider-scm: version v0.2.1
134 lines (133 loc) • 4.57 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
import * as inputs from "./types/input";
import * as outputs from "./types/output";
/**
* BandwidthAllocation resource
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as scm from "@pulumi/scm";
*
* //#######################################################
* // Create
* //#######################################################
* // 1000 mbps leads to 1 spn (eg: taiwan-raspberry)
* // >1000 mbps leads to 2 spns (eg: taiwan-raspberry, taiwan-larch)
* // >2000 mbps leads to 3 spns and so on. (eg: taiwan-raspberry, taiwan-larch, taiwan-peng)
* // The API is smart enough to generate these spn's and return to us.
* // To create with qos use following example
* // resource "scm_bandwidth_allocation" "example" {
* // name = "taiwan"
* // allocated_bandwidth = 50 # In Mbps
* //
* // qos = {
* // enabled = true
* // customized = false # Set to true if using a custom profile
* // profile = "Default Profile" # Name of the QoS Profile
* // guaranteed_ratio = 20 # 20% guaranteed bandwidth ratio. API seems to accept only round integers
* // }
* //}
* // When creating, we never specify an spn_name_list. That is purely during update
* const example = new scm.BandwidthAllocation("example", {
* name: "taiwan",
* allocatedBandwidth: 50,
* });
* ```
*
* ## Import
*
* The following command can be used to import a resource not managed by Terraform:
*
* bash
*
* ```sh
* $ pulumi import scm:index/bandwidthAllocation:BandwidthAllocation example <name_value_of_the_resource>
* ```
*/
export declare class BandwidthAllocation extends pulumi.CustomResource {
/**
* Get an existing BandwidthAllocation 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?: BandwidthAllocationState, opts?: pulumi.CustomResourceOptions): BandwidthAllocation;
/**
* Returns true if the given object is an instance of BandwidthAllocation. 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 BandwidthAllocation;
/**
* bandwidth to allocate in Mbps
*/
readonly allocatedBandwidth: pulumi.Output<number>;
/**
* name of the aggregated bandwidth region
*/
readonly name: pulumi.Output<string>;
/**
* Qos
*/
readonly qos: pulumi.Output<outputs.BandwidthAllocationQos | undefined>;
/**
* Spn name list
*/
readonly spnNameLists: pulumi.Output<string[]>;
readonly tfid: pulumi.Output<string>;
/**
* Create a BandwidthAllocation 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: BandwidthAllocationArgs, opts?: pulumi.CustomResourceOptions);
}
/**
* Input properties used for looking up and filtering BandwidthAllocation resources.
*/
export interface BandwidthAllocationState {
/**
* bandwidth to allocate in Mbps
*/
allocatedBandwidth?: pulumi.Input<number>;
/**
* name of the aggregated bandwidth region
*/
name?: pulumi.Input<string>;
/**
* Qos
*/
qos?: pulumi.Input<inputs.BandwidthAllocationQos>;
/**
* Spn name list
*/
spnNameLists?: pulumi.Input<pulumi.Input<string>[]>;
tfid?: pulumi.Input<string>;
}
/**
* The set of arguments for constructing a BandwidthAllocation resource.
*/
export interface BandwidthAllocationArgs {
/**
* bandwidth to allocate in Mbps
*/
allocatedBandwidth: pulumi.Input<number>;
/**
* name of the aggregated bandwidth region
*/
name?: pulumi.Input<string>;
/**
* Qos
*/
qos?: pulumi.Input<inputs.BandwidthAllocationQos>;
/**
* Spn name list
*/
spnNameLists?: pulumi.Input<pulumi.Input<string>[]>;
}