@pulumi/gcp
Version:
A Pulumi package for creating and managing Google Cloud Platform resources.
116 lines • 4.64 kB
JavaScript
// *** WARNING: this file was generated by pulumi-language-nodejs. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
Object.defineProperty(exports, "__esModule", { value: true });
exports.InterconnectGroup = void 0;
const pulumi = require("@pulumi/pulumi");
const utilities = require("../utilities");
/**
* An interconnect group resource allows customers to create, analyze, and
* expand their redundant connections.
*
* To get more information about InterconnectGroup, see:
*
* * [API documentation](https://cloud.google.com/compute/docs/reference/rest/v1/interconnects)
* * How-to Guides
* * [Create a Dedicated Interconnect](https://cloud.google.com/network-connectivity/docs/interconnect/concepts/dedicated-overview)
*
* ## Example Usage
*
* ### Interconnect Group Basic
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as gcp from "@pulumi/gcp";
*
* const example_interconnect_group = new gcp.compute.InterconnectGroup("example-interconnect-group", {
* name: "example-interconnect-group",
* intent: {
* topologyCapability: "NO_SLA",
* },
* });
* ```
*
* ## Import
*
* InterconnectGroup can be imported using any of these accepted formats:
*
* * `projects/{{project}}/global/interconnectGroups/{{name}}`
*
* * `{{project}}/{{name}}`
*
* * `{{name}}`
*
* When using the `pulumi import` command, InterconnectGroup can be imported using one of the formats above. For example:
*
* ```sh
* $ pulumi import gcp:compute/interconnectGroup:InterconnectGroup default projects/{{project}}/global/interconnectGroups/{{name}}
* ```
*
* ```sh
* $ pulumi import gcp:compute/interconnectGroup:InterconnectGroup default {{project}}/{{name}}
* ```
*
* ```sh
* $ pulumi import gcp:compute/interconnectGroup:InterconnectGroup default {{name}}
* ```
*/
class InterconnectGroup extends pulumi.CustomResource {
/**
* Get an existing InterconnectGroup 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, id, state, opts) {
return new InterconnectGroup(name, state, { ...opts, id: id });
}
/**
* Returns true if the given object is an instance of InterconnectGroup. This is designed to work even
* when multiple copies of the Pulumi SDK have been loaded into the same process.
*/
static isInstance(obj) {
if (obj === undefined || obj === null) {
return false;
}
return obj['__pulumiType'] === InterconnectGroup.__pulumiType;
}
constructor(name, argsOrState, opts) {
let resourceInputs = {};
opts = opts || {};
if (opts.id) {
const state = argsOrState;
resourceInputs["configureds"] = state?.configureds;
resourceInputs["creationTimestamp"] = state?.creationTimestamp;
resourceInputs["description"] = state?.description;
resourceInputs["intent"] = state?.intent;
resourceInputs["interconnects"] = state?.interconnects;
resourceInputs["name"] = state?.name;
resourceInputs["physicalStructures"] = state?.physicalStructures;
resourceInputs["project"] = state?.project;
}
else {
const args = argsOrState;
if (args?.intent === undefined && !opts.urn) {
throw new Error("Missing required property 'intent'");
}
resourceInputs["description"] = args?.description;
resourceInputs["intent"] = args?.intent;
resourceInputs["interconnects"] = args?.interconnects;
resourceInputs["name"] = args?.name;
resourceInputs["project"] = args?.project;
resourceInputs["configureds"] = undefined /*out*/;
resourceInputs["creationTimestamp"] = undefined /*out*/;
resourceInputs["physicalStructures"] = undefined /*out*/;
}
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
super(InterconnectGroup.__pulumiType, name, resourceInputs, opts);
}
}
exports.InterconnectGroup = InterconnectGroup;
/** @internal */
InterconnectGroup.__pulumiType = 'gcp:compute/interconnectGroup:InterconnectGroup';
//# sourceMappingURL=interconnectGroup.js.map
;