UNPKG

@pulumi/sdwan

Version:

A Pulumi package for managing resources on Cisco Catalyst SD-WAN.. Based on terraform-provider-sdwan: version v0.4.1

273 lines 12.3 kB
"use strict"; // *** 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.CiscoBgpFeatureTemplate = void 0; const pulumi = require("@pulumi/pulumi"); const utilities = require("./utilities"); /** * This resource can manage a Cisco BGP feature template. * - Minimum SD-WAN Manager version: `15.0.0` * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as sdwan from "@pulumi/sdwan"; * * const example = new sdwan.CiscoBgpFeatureTemplate("example", { * name: "Example", * description: "My Example", * deviceTypes: ["vedge-C8000V"], * asNumber: "65000", * shutdown: true, * routerId: "1.2.3.4", * propagateAspath: true, * propagateCommunity: true, * ipv4RouteTargets: [{ * vpnId: 1, * "export": [{ * asnIp: "10:100", * }], * "import": [{ * asnIp: "10:100", * }], * }], * ipv6RouteTargets: [{ * vpnId: 1, * "export": [{ * asnIp: "10:100", * }], * "import": [{ * asnIp: "10:100", * }], * }], * mplsInterfaces: [{ * interfaceName: "GigabitEthernet0", * }], * distanceExternal: 30, * distanceInternal: 210, * distanceLocal: 30, * keepalive: 90, * holdtime: 220, * alwaysCompareMed: true, * deterministicMed: true, * missingMedWorst: true, * compareRouterId: true, * multipathRelax: true, * addressFamilies: [{ * familyType: "ipv4-unicast", * ipv4AggregateAddresses: [{ * prefix: "10.0.0.0/8", * asSetPath: true, * summaryOnly: true, * }], * ipv4Networks: [{ * prefix: "10.2.2.0/24", * }], * maximumPaths: 8, * defaultInformationOriginate: true, * tableMapPolicy: "MAP1", * tableMapFilter: true, * redistributeRoutes: [{ * protocol: "ospf", * routePolicy: "POLICY1", * }], * }], * ipv4Neighbors: [{ * address: "10.2.2.2", * description: "My neighbor", * shutdown: true, * remoteAs: "65001", * keepalive: 30, * holdtime: 90, * sourceInterface: "GigabitEthernet1", * nextHopSelf: true, * sendCommunity: false, * sendExtCommunity: false, * ebgpMultihop: 10, * password: "cisco123", * sendLabel: true, * sendLabelExplicit: true, * asOverride: true, * allowAsIn: 5, * addressFamilies: [{ * familyType: "ipv4-unicast", * maximumPrefixes: 10000, * maximumPrefixesThreshold: 80, * maximumPrefixesRestart: 180, * maximumPrefixesWarningOnly: true, * routePolicies: [{ * direction: "in", * policyName: "POLICY1", * }], * }], * }], * ipv6Neighbors: [{ * address: "2001:1::1", * description: "My neighbor", * shutdown: true, * remoteAs: "65001", * keepalive: 30, * holdtime: 90, * sourceInterface: "GigabitEthernet1", * nextHopSelf: true, * sendCommunity: false, * sendExtCommunity: false, * ebgpMultihop: 10, * password: "cisco123", * sendLabel: true, * sendLabelExplicit: true, * asOverride: true, * allowAsIn: 5, * addressFamilies: [{ * familyType: "ipv6-unicast", * maximumPrefixes: 10000, * maximumPrefixesThreshold: 80, * maximumPrefixesRestart: 180, * maximumPrefixesWarningOnly: true, * routePolicies: [{ * direction: "in", * policyName: "POLICY1", * }], * }], * }], * }); * ``` * * ## Import * * The `pulumi import` command can be used, for example: * * ```sh * $ pulumi import sdwan:index/ciscoBgpFeatureTemplate:CiscoBgpFeatureTemplate example "f6b2c44c-693c-4763-b010-895aa3d236bd" * ``` */ class CiscoBgpFeatureTemplate extends pulumi.CustomResource { /** * Get an existing CiscoBgpFeatureTemplate 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 CiscoBgpFeatureTemplate(name, state, { ...opts, id: id }); } /** * Returns true if the given object is an instance of CiscoBgpFeatureTemplate. 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'] === CiscoBgpFeatureTemplate.__pulumiType; } constructor(name, argsOrState, opts) { let resourceInputs = {}; opts = opts || {}; if (opts.id) { const state = argsOrState; resourceInputs["addressFamilies"] = state?.addressFamilies; resourceInputs["alwaysCompareMed"] = state?.alwaysCompareMed; resourceInputs["alwaysCompareMedVariable"] = state?.alwaysCompareMedVariable; resourceInputs["asNumber"] = state?.asNumber; resourceInputs["asNumberVariable"] = state?.asNumberVariable; resourceInputs["compareRouterId"] = state?.compareRouterId; resourceInputs["compareRouterIdVariable"] = state?.compareRouterIdVariable; resourceInputs["description"] = state?.description; resourceInputs["deterministicMed"] = state?.deterministicMed; resourceInputs["deterministicMedVariable"] = state?.deterministicMedVariable; resourceInputs["deviceTypes"] = state?.deviceTypes; resourceInputs["distanceExternal"] = state?.distanceExternal; resourceInputs["distanceExternalVariable"] = state?.distanceExternalVariable; resourceInputs["distanceInternal"] = state?.distanceInternal; resourceInputs["distanceInternalVariable"] = state?.distanceInternalVariable; resourceInputs["distanceLocal"] = state?.distanceLocal; resourceInputs["distanceLocalVariable"] = state?.distanceLocalVariable; resourceInputs["holdtime"] = state?.holdtime; resourceInputs["holdtimeVariable"] = state?.holdtimeVariable; resourceInputs["ipv4Neighbors"] = state?.ipv4Neighbors; resourceInputs["ipv4RouteTargets"] = state?.ipv4RouteTargets; resourceInputs["ipv6Neighbors"] = state?.ipv6Neighbors; resourceInputs["ipv6RouteTargets"] = state?.ipv6RouteTargets; resourceInputs["keepalive"] = state?.keepalive; resourceInputs["keepaliveVariable"] = state?.keepaliveVariable; resourceInputs["missingMedWorst"] = state?.missingMedWorst; resourceInputs["missingMedWorstVariable"] = state?.missingMedWorstVariable; resourceInputs["mplsInterfaces"] = state?.mplsInterfaces; resourceInputs["multipathRelax"] = state?.multipathRelax; resourceInputs["multipathRelaxVariable"] = state?.multipathRelaxVariable; resourceInputs["name"] = state?.name; resourceInputs["propagateAspath"] = state?.propagateAspath; resourceInputs["propagateAspathVariable"] = state?.propagateAspathVariable; resourceInputs["propagateCommunity"] = state?.propagateCommunity; resourceInputs["propagateCommunityVariable"] = state?.propagateCommunityVariable; resourceInputs["routerId"] = state?.routerId; resourceInputs["routerIdVariable"] = state?.routerIdVariable; resourceInputs["shutdown"] = state?.shutdown; resourceInputs["shutdownVariable"] = state?.shutdownVariable; resourceInputs["templateType"] = state?.templateType; resourceInputs["version"] = state?.version; } else { const args = argsOrState; if (args?.description === undefined && !opts.urn) { throw new Error("Missing required property 'description'"); } if (args?.deviceTypes === undefined && !opts.urn) { throw new Error("Missing required property 'deviceTypes'"); } resourceInputs["addressFamilies"] = args?.addressFamilies; resourceInputs["alwaysCompareMed"] = args?.alwaysCompareMed; resourceInputs["alwaysCompareMedVariable"] = args?.alwaysCompareMedVariable; resourceInputs["asNumber"] = args?.asNumber; resourceInputs["asNumberVariable"] = args?.asNumberVariable; resourceInputs["compareRouterId"] = args?.compareRouterId; resourceInputs["compareRouterIdVariable"] = args?.compareRouterIdVariable; resourceInputs["description"] = args?.description; resourceInputs["deterministicMed"] = args?.deterministicMed; resourceInputs["deterministicMedVariable"] = args?.deterministicMedVariable; resourceInputs["deviceTypes"] = args?.deviceTypes; resourceInputs["distanceExternal"] = args?.distanceExternal; resourceInputs["distanceExternalVariable"] = args?.distanceExternalVariable; resourceInputs["distanceInternal"] = args?.distanceInternal; resourceInputs["distanceInternalVariable"] = args?.distanceInternalVariable; resourceInputs["distanceLocal"] = args?.distanceLocal; resourceInputs["distanceLocalVariable"] = args?.distanceLocalVariable; resourceInputs["holdtime"] = args?.holdtime; resourceInputs["holdtimeVariable"] = args?.holdtimeVariable; resourceInputs["ipv4Neighbors"] = args?.ipv4Neighbors; resourceInputs["ipv4RouteTargets"] = args?.ipv4RouteTargets; resourceInputs["ipv6Neighbors"] = args?.ipv6Neighbors; resourceInputs["ipv6RouteTargets"] = args?.ipv6RouteTargets; resourceInputs["keepalive"] = args?.keepalive; resourceInputs["keepaliveVariable"] = args?.keepaliveVariable; resourceInputs["missingMedWorst"] = args?.missingMedWorst; resourceInputs["missingMedWorstVariable"] = args?.missingMedWorstVariable; resourceInputs["mplsInterfaces"] = args?.mplsInterfaces; resourceInputs["multipathRelax"] = args?.multipathRelax; resourceInputs["multipathRelaxVariable"] = args?.multipathRelaxVariable; resourceInputs["name"] = args?.name; resourceInputs["propagateAspath"] = args?.propagateAspath; resourceInputs["propagateAspathVariable"] = args?.propagateAspathVariable; resourceInputs["propagateCommunity"] = args?.propagateCommunity; resourceInputs["propagateCommunityVariable"] = args?.propagateCommunityVariable; resourceInputs["routerId"] = args?.routerId; resourceInputs["routerIdVariable"] = args?.routerIdVariable; resourceInputs["shutdown"] = args?.shutdown; resourceInputs["shutdownVariable"] = args?.shutdownVariable; resourceInputs["templateType"] = undefined /*out*/; resourceInputs["version"] = undefined /*out*/; } opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts); super(CiscoBgpFeatureTemplate.__pulumiType, name, resourceInputs, opts); } } exports.CiscoBgpFeatureTemplate = CiscoBgpFeatureTemplate; /** @internal */ CiscoBgpFeatureTemplate.__pulumiType = 'sdwan:index/ciscoBgpFeatureTemplate:CiscoBgpFeatureTemplate'; //# sourceMappingURL=ciscoBgpFeatureTemplate.js.map