UNPKG

@cuemby/equinix

Version:

A Pulumi package for creating and managing equinix cloud resources.

189 lines 9.85 kB
"use strict"; // *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. *** // *** Do not edit by hand unless you're certain you know what you are doing! *** Object.defineProperty(exports, "__esModule", { value: true }); exports.ECXL2Serviceprofile = void 0; const pulumi = require("@pulumi/pulumi"); const utilities = require("./utilities"); /** * Resource `equinix.ECXL2Serviceprofile` is used to manage layer 2 service profiles * in Equinix Fabric. * * This resource relies on the Equinix Fabric API. The parameters * and attributes available map to the fields described at * <https://developer.equinix.com/catalog/sellerv3#operation/getProfileByIdOrNameUsingGET>. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as equinix from "@pulumi/equinix"; * * const private_profile = new equinix.ECXL2Serviceprofile("private-profile", { * bandwidthThresholdNotifications: [ * "John.Doe@example.com", * "Marry.Doe@example.com", * ], * connectionNameLabel: "Connection", * description: "my private profile", * features: { * allowRemoteConnections: true, * testProfile: false, * }, * ports: [ * { * metroCode: "NY", * uuid: "a867f685-422f-22f7-6de0-320a5c00abdd", * }, * { * metroCode: "NY", * uuid: "a867f685-4231-2317-6de0-320a5c00abdd", * }, * ], * private: true, * privateUserEmails: [ * "John.Doe@example.com", * "Marry.Doe@example.com", * ], * profileStatuschangeNotifications: [ * "John.Doe@example.com", * "Marry.Doe@example.com", * ], * speedBands: [ * { * speed: 1000, * speedUnit: "MB", * }, * { * speed: 500, * speedUnit: "MB", * }, * { * speed: 100, * speedUnit: "MB", * }, * ], * vcStatuschangeNotifications: [ * "John.Doe@example.com", * "Marry.Doe@example.com", * ], * }); * ``` * * ## Import * * This resource can be imported using an existing ID * * ```sh * $ pulumi import equinix:index/eCXL2Serviceprofile:ECXL2Serviceprofile example {existing_id} * ``` */ class ECXL2Serviceprofile extends pulumi.CustomResource { constructor(name, argsOrState, opts) { let resourceInputs = {}; opts = opts || {}; if (opts.id) { const state = argsOrState; resourceInputs["apiIntegration"] = state ? state.apiIntegration : undefined; resourceInputs["authkeyLabel"] = state ? state.authkeyLabel : undefined; resourceInputs["bandwidthAlertThreshold"] = state ? state.bandwidthAlertThreshold : undefined; resourceInputs["bandwidthThresholdNotifications"] = state ? state.bandwidthThresholdNotifications : undefined; resourceInputs["connectionNameLabel"] = state ? state.connectionNameLabel : undefined; resourceInputs["ctagLabel"] = state ? state.ctagLabel : undefined; resourceInputs["description"] = state ? state.description : undefined; resourceInputs["equinixManagedPortVlan"] = state ? state.equinixManagedPortVlan : undefined; resourceInputs["features"] = state ? state.features : undefined; resourceInputs["integrationId"] = state ? state.integrationId : undefined; resourceInputs["name"] = state ? state.name : undefined; resourceInputs["oversubscription"] = state ? state.oversubscription : undefined; resourceInputs["oversubscriptionAllowed"] = state ? state.oversubscriptionAllowed : undefined; resourceInputs["ports"] = state ? state.ports : undefined; resourceInputs["private"] = state ? state.private : undefined; resourceInputs["privateUserEmails"] = state ? state.privateUserEmails : undefined; resourceInputs["profileStatuschangeNotifications"] = state ? state.profileStatuschangeNotifications : undefined; resourceInputs["redundancyRequired"] = state ? state.redundancyRequired : undefined; resourceInputs["secondaryVlanFromPrimary"] = state ? state.secondaryVlanFromPrimary : undefined; resourceInputs["servicekeyAutogenerated"] = state ? state.servicekeyAutogenerated : undefined; resourceInputs["speedBands"] = state ? state.speedBands : undefined; resourceInputs["speedCustomizationAllowed"] = state ? state.speedCustomizationAllowed : undefined; resourceInputs["speedFromApi"] = state ? state.speedFromApi : undefined; resourceInputs["state"] = state ? state.state : undefined; resourceInputs["tagType"] = state ? state.tagType : undefined; resourceInputs["uuid"] = state ? state.uuid : undefined; resourceInputs["vcStatuschangeNotifications"] = state ? state.vcStatuschangeNotifications : undefined; } else { const args = argsOrState; if ((!args || args.bandwidthThresholdNotifications === undefined) && !opts.urn) { throw new Error("Missing required property 'bandwidthThresholdNotifications'"); } if ((!args || args.features === undefined) && !opts.urn) { throw new Error("Missing required property 'features'"); } if ((!args || args.ports === undefined) && !opts.urn) { throw new Error("Missing required property 'ports'"); } if ((!args || args.profileStatuschangeNotifications === undefined) && !opts.urn) { throw new Error("Missing required property 'profileStatuschangeNotifications'"); } if ((!args || args.vcStatuschangeNotifications === undefined) && !opts.urn) { throw new Error("Missing required property 'vcStatuschangeNotifications'"); } resourceInputs["apiIntegration"] = args ? args.apiIntegration : undefined; resourceInputs["authkeyLabel"] = args ? args.authkeyLabel : undefined; resourceInputs["bandwidthAlertThreshold"] = args ? args.bandwidthAlertThreshold : undefined; resourceInputs["bandwidthThresholdNotifications"] = args ? args.bandwidthThresholdNotifications : undefined; resourceInputs["connectionNameLabel"] = args ? args.connectionNameLabel : undefined; resourceInputs["ctagLabel"] = args ? args.ctagLabel : undefined; resourceInputs["description"] = args ? args.description : undefined; resourceInputs["equinixManagedPortVlan"] = args ? args.equinixManagedPortVlan : undefined; resourceInputs["features"] = args ? args.features : undefined; resourceInputs["integrationId"] = args ? args.integrationId : undefined; resourceInputs["name"] = args ? args.name : undefined; resourceInputs["oversubscription"] = args ? args.oversubscription : undefined; resourceInputs["oversubscriptionAllowed"] = args ? args.oversubscriptionAllowed : undefined; resourceInputs["ports"] = args ? args.ports : undefined; resourceInputs["private"] = args ? args.private : undefined; resourceInputs["privateUserEmails"] = args ? args.privateUserEmails : undefined; resourceInputs["profileStatuschangeNotifications"] = args ? args.profileStatuschangeNotifications : undefined; resourceInputs["redundancyRequired"] = args ? args.redundancyRequired : undefined; resourceInputs["secondaryVlanFromPrimary"] = args ? args.secondaryVlanFromPrimary : undefined; resourceInputs["servicekeyAutogenerated"] = args ? args.servicekeyAutogenerated : undefined; resourceInputs["speedBands"] = args ? args.speedBands : undefined; resourceInputs["speedCustomizationAllowed"] = args ? args.speedCustomizationAllowed : undefined; resourceInputs["speedFromApi"] = args ? args.speedFromApi : undefined; resourceInputs["tagType"] = args ? args.tagType : undefined; resourceInputs["vcStatuschangeNotifications"] = args ? args.vcStatuschangeNotifications : undefined; resourceInputs["state"] = undefined /*out*/; resourceInputs["uuid"] = undefined /*out*/; } opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts); super(ECXL2Serviceprofile.__pulumiType, name, resourceInputs, opts); } /** * Get an existing ECXL2Serviceprofile 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 ECXL2Serviceprofile(name, state, Object.assign(Object.assign({}, opts), { id: id })); } /** * Returns true if the given object is an instance of ECXL2Serviceprofile. 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'] === ECXL2Serviceprofile.__pulumiType; } } exports.ECXL2Serviceprofile = ECXL2Serviceprofile; /** @internal */ ECXL2Serviceprofile.__pulumiType = 'equinix:index/eCXL2Serviceprofile:ECXL2Serviceprofile'; //# sourceMappingURL=ecxl2serviceprofile.js.map