@pulumi/aws-native
Version:
The Pulumi AWS Cloud Control Provider enables you to build, deploy, and manage [any AWS resource that's supported by the AWS Cloud Control API](https://github.com/pulumi/pulumi-aws-native/blob/master/provider/cmd/pulumi-gen-aws-native/supported-types.txt)
160 lines • 5.67 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.GlobalNetwork = void 0;
const pulumi = require("@pulumi/pulumi");
const utilities = require("../utilities");
/**
* The AWS::NetworkManager::GlobalNetwork type specifies a global network of the user's account
*
* ## Example Usage
* ### Example
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as aws_native from "@pulumi/aws-native";
*
* const globalNetwork = new aws_native.networkmanager.GlobalNetwork("globalNetwork", {});
* const site = new aws_native.networkmanager.Site("site", {
* globalNetworkId: globalNetwork.id,
* location: {
* address: "227 W Monroe St, Chicago, IL 60606",
* latitude: "41.8",
* longitude: "-87.6",
* },
* });
* const link = new aws_native.networkmanager.Link("link", {
* description: "Broadband link",
* globalNetworkId: globalNetwork.id,
* siteId: site.siteId,
* bandwidth: {
* downloadSpeed: 20,
* uploadSpeed: 20,
* },
* provider: "AnyCompany",
* type: "Broadband",
* tags: [{
* key: "Name",
* value: "broadband-link-1",
* }],
* });
* const device = new aws_native.networkmanager.Device("device", {
* description: "Chicago office device",
* globalNetworkId: globalNetwork.id,
* siteId: site.siteId,
* tags: [{
* key: "Network",
* value: "north-america",
* }],
* });
* const linkAssociation = new aws_native.networkmanager.LinkAssociation("linkAssociation", {
* globalNetworkId: globalNetwork.id,
* linkId: link.linkId,
* deviceId: device.deviceId,
* });
*
* ```
* ### Example
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as aws_native from "@pulumi/aws-native";
*
* const globalNetwork = new aws_native.networkmanager.GlobalNetwork("globalNetwork", {});
* const site = new aws_native.networkmanager.Site("site", {
* globalNetworkId: globalNetwork.id,
* location: {
* address: "227 W Monroe St, Chicago, IL 60606",
* latitude: "41.8",
* longitude: "-87.6",
* },
* });
* const link = new aws_native.networkmanager.Link("link", {
* description: "Broadband link",
* globalNetworkId: globalNetwork.id,
* siteId: site.siteId,
* bandwidth: {
* downloadSpeed: 20,
* uploadSpeed: 20,
* },
* provider: "AnyCompany",
* type: "Broadband",
* tags: [{
* key: "Name",
* value: "broadband-link-1",
* }],
* });
* const device = new aws_native.networkmanager.Device("device", {
* description: "Chicago office device",
* globalNetworkId: globalNetwork.id,
* siteId: site.siteId,
* tags: [{
* key: "Network",
* value: "north-america",
* }],
* });
* const linkAssociation = new aws_native.networkmanager.LinkAssociation("linkAssociation", {
* globalNetworkId: globalNetwork.id,
* linkId: link.linkId,
* deviceId: device.deviceId,
* });
*
* ```
*/
class GlobalNetwork extends pulumi.CustomResource {
/**
* Get an existing GlobalNetwork 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 opts Optional settings to control the behavior of the CustomResource.
*/
static get(name, id, opts) {
return new GlobalNetwork(name, undefined, { ...opts, id: id });
}
/**
* Returns true if the given object is an instance of GlobalNetwork. 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'] === GlobalNetwork.__pulumiType;
}
/**
* Create a GlobalNetwork 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, args, opts) {
let resourceInputs = {};
opts = opts || {};
if (!opts.id) {
resourceInputs["createdAt"] = args?.createdAt;
resourceInputs["description"] = args?.description;
resourceInputs["state"] = args?.state;
resourceInputs["tags"] = args?.tags;
resourceInputs["arn"] = undefined /*out*/;
resourceInputs["awsId"] = undefined /*out*/;
}
else {
resourceInputs["arn"] = undefined /*out*/;
resourceInputs["awsId"] = undefined /*out*/;
resourceInputs["createdAt"] = undefined /*out*/;
resourceInputs["description"] = undefined /*out*/;
resourceInputs["state"] = undefined /*out*/;
resourceInputs["tags"] = undefined /*out*/;
}
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
super(GlobalNetwork.__pulumiType, name, resourceInputs, opts);
}
}
exports.GlobalNetwork = GlobalNetwork;
/** @internal */
GlobalNetwork.__pulumiType = 'aws-native:networkmanager:GlobalNetwork';
//# sourceMappingURL=globalNetwork.js.map