UNPKG

@pulumi/juniper-mist

Version:

A Pulumi package for creating and managing Juniper Mist resources.

112 lines 5.41 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.Network = void 0; const pulumi = require("@pulumi/pulumi"); const utilities = require("../utilities"); /** * This resource manages the WAN Assurance Networks. * * The Networks are used in the `servicePolicies` from the Gateway configuration, Gateway templates or HUB Profiles * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as junipermist from "@pulumi/juniper-mist"; * * const networkOne = new junipermist.org.Network("network_one", { * orgId: terraformTest.id, * name: "network_one", * subnet: "10.4.0.0/24", * disallowMistServices: false, * }); * ``` * * ## Import * * Using `pulumi import`, import `mist_org_network` with: * * Org Network can be imported by specifying the org_id and the network_id * * ```sh * $ pulumi import junipermist:org/network:Network network_one 17b46405-3a6d-4715-8bb4-6bb6d06f316a.d3c42998-9012-4859-9743-6b9bee475309 * ``` */ class Network extends pulumi.CustomResource { /** * Get an existing Network 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 Network(name, state, Object.assign(Object.assign({}, opts), { id: id })); } /** * Returns true if the given object is an instance of Network. 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'] === Network.__pulumiType; } constructor(name, argsOrState, opts) { let resourceInputs = {}; opts = opts || {}; if (opts.id) { const state = argsOrState; resourceInputs["disallowMistServices"] = state ? state.disallowMistServices : undefined; resourceInputs["gateway"] = state ? state.gateway : undefined; resourceInputs["gateway6"] = state ? state.gateway6 : undefined; resourceInputs["internalAccess"] = state ? state.internalAccess : undefined; resourceInputs["internetAccess"] = state ? state.internetAccess : undefined; resourceInputs["isolation"] = state ? state.isolation : undefined; resourceInputs["multicast"] = state ? state.multicast : undefined; resourceInputs["name"] = state ? state.name : undefined; resourceInputs["orgId"] = state ? state.orgId : undefined; resourceInputs["routedForNetworks"] = state ? state.routedForNetworks : undefined; resourceInputs["subnet"] = state ? state.subnet : undefined; resourceInputs["subnet6"] = state ? state.subnet6 : undefined; resourceInputs["tenants"] = state ? state.tenants : undefined; resourceInputs["vlanId"] = state ? state.vlanId : undefined; resourceInputs["vpnAccess"] = state ? state.vpnAccess : undefined; } else { const args = argsOrState; if ((!args || args.orgId === undefined) && !opts.urn) { throw new Error("Missing required property 'orgId'"); } if ((!args || args.subnet === undefined) && !opts.urn) { throw new Error("Missing required property 'subnet'"); } resourceInputs["disallowMistServices"] = args ? args.disallowMistServices : undefined; resourceInputs["gateway"] = args ? args.gateway : undefined; resourceInputs["gateway6"] = args ? args.gateway6 : undefined; resourceInputs["internalAccess"] = args ? args.internalAccess : undefined; resourceInputs["internetAccess"] = args ? args.internetAccess : undefined; resourceInputs["isolation"] = args ? args.isolation : undefined; resourceInputs["multicast"] = args ? args.multicast : undefined; resourceInputs["name"] = args ? args.name : undefined; resourceInputs["orgId"] = args ? args.orgId : undefined; resourceInputs["routedForNetworks"] = args ? args.routedForNetworks : undefined; resourceInputs["subnet"] = args ? args.subnet : undefined; resourceInputs["subnet6"] = args ? args.subnet6 : undefined; resourceInputs["tenants"] = args ? args.tenants : undefined; resourceInputs["vlanId"] = args ? args.vlanId : undefined; resourceInputs["vpnAccess"] = args ? args.vpnAccess : undefined; } opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts); super(Network.__pulumiType, name, resourceInputs, opts); } } exports.Network = Network; /** @internal */ Network.__pulumiType = 'junipermist:org/network:Network'; //# sourceMappingURL=network.js.map