@pulumi/juniper-mist
Version:
A Pulumi package for creating and managing Juniper Mist resources.
420 lines (419 loc) • 16.9 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
import * as inputs from "../types/input";
import * as outputs from "../types/output";
/**
* This resource managed the Org Network Templates (Switch templates).
*
* A network template is a predefined configuration that provides a consistent and reusable set of network settings for devices within an organization. It includes various parameters such as ip addressing, vlan configurations, routing protocols, security policies, and other network-specific settings.\
* Network templates simplify the deployment and management of switches by ensuring consistent configurations across multiple devices and sites. They help enforce standardization, reduce human error, and streamline troubleshooting and maintenance tasks.
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as junipermist from "@pulumi/juniper-mist";
*
* const networktemplateOne = new junipermist.org.Networktemplate("networktemplate_one", {
* name: "networktemplate_one",
* orgId: terraformTest.id,
* dnsServers: [
* "8.8.8.8",
* "1.1.1.1",
* ],
* dnsSuffixes: ["mycorp.com"],
* ntpServers: ["pool.ntp.org"],
* additionalConfigCmds: [
* "set system hostname test",
* "set system services ssh root-login allow",
* ],
* networks: {
* network_one: {
* vlanId: "10",
* },
* network_two: {
* vlanId: "11",
* },
* },
* portUsages: {
* trunk: {
* allNetworks: true,
* enableQos: true,
* mode: "port_usage_one",
* portNetwork: "network_one",
* },
* },
* radiusConfig: {
* acctInterimInterval: 60,
* coaEnabled: true,
* network: "network_one",
* acctServers: [{
* host: "1.2.3.4",
* secret: "secret",
* }],
* authServers: [{
* host: "1.2.3.4",
* secret: "secret",
* }],
* },
* switchMatching: {
* enable: true,
* rules: [{
* name: "switch_rule_one",
* matchName: "corp",
* matchNameOffset: 3,
* matchRole: "core",
* portConfig: {
* "ge-0/0/0-10": {
* usage: "port_usage_one",
* },
* },
* }],
* },
* });
* ```
*
* ## Import
*
* Using `pulumi import`, import `mist_org_networktemplate` with:
*
* Org Network Template can be imported by specifying the org_id and the networktemplate_id
*
* ```sh
* $ pulumi import junipermist:org/networktemplate:Networktemplate networktemplate_one 17b46405-3a6d-4715-8bb4-6bb6d06f316a.d3c42998-9012-4859-9743-6b9bee475309
* ```
*/
export declare class Networktemplate extends pulumi.CustomResource {
/**
* Get an existing Networktemplate 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: string, id: pulumi.Input<pulumi.ID>, state?: NetworktemplateState, opts?: pulumi.CustomResourceOptions): Networktemplate;
/**
* Returns true if the given object is an instance of Networktemplate. This is designed to work even
* when multiple copies of the Pulumi SDK have been loaded into the same process.
*/
static isInstance(obj: any): obj is Networktemplate;
readonly aclPolicies: pulumi.Output<outputs.org.NetworktemplateAclPolicy[] | undefined>;
/**
* ACL Tags to identify traffic source or destination. Key name is the tag name
*/
readonly aclTags: pulumi.Output<{
[key: string]: outputs.org.NetworktemplateAclTags;
} | undefined>;
/**
* additional CLI commands to append to the generated Junos config. **Note**: no check is done
*/
readonly additionalConfigCmds: pulumi.Output<string[] | undefined>;
readonly bgpConfig: pulumi.Output<{
[key: string]: outputs.org.NetworktemplateBgpConfig;
} | undefined>;
readonly dhcpSnooping: pulumi.Output<outputs.org.NetworktemplateDhcpSnooping | undefined>;
/**
* Global dns settings. To keep compatibility, dns settings in `ipConfig` and `oobIpConfig` will overwrite this setting
*/
readonly dnsServers: pulumi.Output<string[]>;
/**
* Global dns settings. To keep compatibility, dns settings in `ipConfig` and `oobIpConfig` will overwrite this setting
*/
readonly dnsSuffixes: pulumi.Output<string[]>;
/**
* Property key is the destination CIDR (e.g. "10.0.0.0/8")
*/
readonly extraRoutes: pulumi.Output<{
[key: string]: outputs.org.NetworktemplateExtraRoutes;
} | undefined>;
/**
* Property key is the destination CIDR (e.g. "2a02:1234:420a:10c9::/64")
*/
readonly extraRoutes6: pulumi.Output<{
[key: string]: outputs.org.NetworktemplateExtraRoutes6;
} | undefined>;
/**
* Enable mistNac to use RadSec
*/
readonly mistNac: pulumi.Output<outputs.org.NetworktemplateMistNac | undefined>;
readonly name: pulumi.Output<string>;
/**
* Property key is network name
*/
readonly networks: pulumi.Output<{
[key: string]: outputs.org.NetworktemplateNetworks;
} | undefined>;
/**
* List of NTP servers specific to this device. By default, those in Site Settings will be used
*/
readonly ntpServers: pulumi.Output<string[]>;
readonly orgId: pulumi.Output<string>;
/**
* Junos OSPF areas. Property key is the OSPF Area (Area should be a number (0-255) / IP address)
*/
readonly ospfAreas: pulumi.Output<{
[key: string]: outputs.org.NetworktemplateOspfAreas;
} | undefined>;
/**
* Property key is the port mirroring instance name. `portMirroring` can be added under device/site settings. It takes interface and ports as input for ingress, interface as input for egress and can take interface and port as output. A maximum 4 mirroring ports is allowed
*/
readonly portMirroring: pulumi.Output<{
[key: string]: outputs.org.NetworktemplatePortMirroring;
} | undefined>;
/**
* Property key is the port usage name. Defines the profiles of port configuration configured on the switch
*/
readonly portUsages: pulumi.Output<{
[key: string]: outputs.org.NetworktemplatePortUsages;
} | undefined>;
/**
* Junos Radius config
*/
readonly radiusConfig: pulumi.Output<outputs.org.NetworktemplateRadiusConfig | undefined>;
readonly remoteSyslog: pulumi.Output<outputs.org.NetworktemplateRemoteSyslog | undefined>;
/**
* By default, only the configuration generated by Mist is cleaned up during the configuration process. If `true`, all the existing configuration will be removed.
*/
readonly removeExistingConfigs: pulumi.Output<boolean | undefined>;
/**
* Property key is the routing policy name
*/
readonly routingPolicies: pulumi.Output<{
[key: string]: outputs.org.NetworktemplateRoutingPolicies;
} | undefined>;
readonly snmpConfig: pulumi.Output<outputs.org.NetworktemplateSnmpConfig | undefined>;
/**
* Defines custom switch configuration based on different criteria
*/
readonly switchMatching: pulumi.Output<outputs.org.NetworktemplateSwitchMatching | undefined>;
/**
* Switch settings
*/
readonly switchMgmt: pulumi.Output<outputs.org.NetworktemplateSwitchMgmt | undefined>;
readonly vrfConfig: pulumi.Output<outputs.org.NetworktemplateVrfConfig | undefined>;
/**
* Property key is the network name
*/
readonly vrfInstances: pulumi.Output<{
[key: string]: outputs.org.NetworktemplateVrfInstances;
} | undefined>;
/**
* Create a Networktemplate 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: string, args: NetworktemplateArgs, opts?: pulumi.CustomResourceOptions);
}
/**
* Input properties used for looking up and filtering Networktemplate resources.
*/
export interface NetworktemplateState {
aclPolicies?: pulumi.Input<pulumi.Input<inputs.org.NetworktemplateAclPolicy>[]>;
/**
* ACL Tags to identify traffic source or destination. Key name is the tag name
*/
aclTags?: pulumi.Input<{
[key: string]: pulumi.Input<inputs.org.NetworktemplateAclTags>;
}>;
/**
* additional CLI commands to append to the generated Junos config. **Note**: no check is done
*/
additionalConfigCmds?: pulumi.Input<pulumi.Input<string>[]>;
bgpConfig?: pulumi.Input<{
[key: string]: pulumi.Input<inputs.org.NetworktemplateBgpConfig>;
}>;
dhcpSnooping?: pulumi.Input<inputs.org.NetworktemplateDhcpSnooping>;
/**
* Global dns settings. To keep compatibility, dns settings in `ipConfig` and `oobIpConfig` will overwrite this setting
*/
dnsServers?: pulumi.Input<pulumi.Input<string>[]>;
/**
* Global dns settings. To keep compatibility, dns settings in `ipConfig` and `oobIpConfig` will overwrite this setting
*/
dnsSuffixes?: pulumi.Input<pulumi.Input<string>[]>;
/**
* Property key is the destination CIDR (e.g. "10.0.0.0/8")
*/
extraRoutes?: pulumi.Input<{
[key: string]: pulumi.Input<inputs.org.NetworktemplateExtraRoutes>;
}>;
/**
* Property key is the destination CIDR (e.g. "2a02:1234:420a:10c9::/64")
*/
extraRoutes6?: pulumi.Input<{
[key: string]: pulumi.Input<inputs.org.NetworktemplateExtraRoutes6>;
}>;
/**
* Enable mistNac to use RadSec
*/
mistNac?: pulumi.Input<inputs.org.NetworktemplateMistNac>;
name?: pulumi.Input<string>;
/**
* Property key is network name
*/
networks?: pulumi.Input<{
[key: string]: pulumi.Input<inputs.org.NetworktemplateNetworks>;
}>;
/**
* List of NTP servers specific to this device. By default, those in Site Settings will be used
*/
ntpServers?: pulumi.Input<pulumi.Input<string>[]>;
orgId?: pulumi.Input<string>;
/**
* Junos OSPF areas. Property key is the OSPF Area (Area should be a number (0-255) / IP address)
*/
ospfAreas?: pulumi.Input<{
[key: string]: pulumi.Input<inputs.org.NetworktemplateOspfAreas>;
}>;
/**
* Property key is the port mirroring instance name. `portMirroring` can be added under device/site settings. It takes interface and ports as input for ingress, interface as input for egress and can take interface and port as output. A maximum 4 mirroring ports is allowed
*/
portMirroring?: pulumi.Input<{
[key: string]: pulumi.Input<inputs.org.NetworktemplatePortMirroring>;
}>;
/**
* Property key is the port usage name. Defines the profiles of port configuration configured on the switch
*/
portUsages?: pulumi.Input<{
[key: string]: pulumi.Input<inputs.org.NetworktemplatePortUsages>;
}>;
/**
* Junos Radius config
*/
radiusConfig?: pulumi.Input<inputs.org.NetworktemplateRadiusConfig>;
remoteSyslog?: pulumi.Input<inputs.org.NetworktemplateRemoteSyslog>;
/**
* By default, only the configuration generated by Mist is cleaned up during the configuration process. If `true`, all the existing configuration will be removed.
*/
removeExistingConfigs?: pulumi.Input<boolean>;
/**
* Property key is the routing policy name
*/
routingPolicies?: pulumi.Input<{
[key: string]: pulumi.Input<inputs.org.NetworktemplateRoutingPolicies>;
}>;
snmpConfig?: pulumi.Input<inputs.org.NetworktemplateSnmpConfig>;
/**
* Defines custom switch configuration based on different criteria
*/
switchMatching?: pulumi.Input<inputs.org.NetworktemplateSwitchMatching>;
/**
* Switch settings
*/
switchMgmt?: pulumi.Input<inputs.org.NetworktemplateSwitchMgmt>;
vrfConfig?: pulumi.Input<inputs.org.NetworktemplateVrfConfig>;
/**
* Property key is the network name
*/
vrfInstances?: pulumi.Input<{
[key: string]: pulumi.Input<inputs.org.NetworktemplateVrfInstances>;
}>;
}
/**
* The set of arguments for constructing a Networktemplate resource.
*/
export interface NetworktemplateArgs {
aclPolicies?: pulumi.Input<pulumi.Input<inputs.org.NetworktemplateAclPolicy>[]>;
/**
* ACL Tags to identify traffic source or destination. Key name is the tag name
*/
aclTags?: pulumi.Input<{
[key: string]: pulumi.Input<inputs.org.NetworktemplateAclTags>;
}>;
/**
* additional CLI commands to append to the generated Junos config. **Note**: no check is done
*/
additionalConfigCmds?: pulumi.Input<pulumi.Input<string>[]>;
bgpConfig?: pulumi.Input<{
[key: string]: pulumi.Input<inputs.org.NetworktemplateBgpConfig>;
}>;
dhcpSnooping?: pulumi.Input<inputs.org.NetworktemplateDhcpSnooping>;
/**
* Global dns settings. To keep compatibility, dns settings in `ipConfig` and `oobIpConfig` will overwrite this setting
*/
dnsServers?: pulumi.Input<pulumi.Input<string>[]>;
/**
* Global dns settings. To keep compatibility, dns settings in `ipConfig` and `oobIpConfig` will overwrite this setting
*/
dnsSuffixes?: pulumi.Input<pulumi.Input<string>[]>;
/**
* Property key is the destination CIDR (e.g. "10.0.0.0/8")
*/
extraRoutes?: pulumi.Input<{
[key: string]: pulumi.Input<inputs.org.NetworktemplateExtraRoutes>;
}>;
/**
* Property key is the destination CIDR (e.g. "2a02:1234:420a:10c9::/64")
*/
extraRoutes6?: pulumi.Input<{
[key: string]: pulumi.Input<inputs.org.NetworktemplateExtraRoutes6>;
}>;
/**
* Enable mistNac to use RadSec
*/
mistNac?: pulumi.Input<inputs.org.NetworktemplateMistNac>;
name?: pulumi.Input<string>;
/**
* Property key is network name
*/
networks?: pulumi.Input<{
[key: string]: pulumi.Input<inputs.org.NetworktemplateNetworks>;
}>;
/**
* List of NTP servers specific to this device. By default, those in Site Settings will be used
*/
ntpServers?: pulumi.Input<pulumi.Input<string>[]>;
orgId: pulumi.Input<string>;
/**
* Junos OSPF areas. Property key is the OSPF Area (Area should be a number (0-255) / IP address)
*/
ospfAreas?: pulumi.Input<{
[key: string]: pulumi.Input<inputs.org.NetworktemplateOspfAreas>;
}>;
/**
* Property key is the port mirroring instance name. `portMirroring` can be added under device/site settings. It takes interface and ports as input for ingress, interface as input for egress and can take interface and port as output. A maximum 4 mirroring ports is allowed
*/
portMirroring?: pulumi.Input<{
[key: string]: pulumi.Input<inputs.org.NetworktemplatePortMirroring>;
}>;
/**
* Property key is the port usage name. Defines the profiles of port configuration configured on the switch
*/
portUsages?: pulumi.Input<{
[key: string]: pulumi.Input<inputs.org.NetworktemplatePortUsages>;
}>;
/**
* Junos Radius config
*/
radiusConfig?: pulumi.Input<inputs.org.NetworktemplateRadiusConfig>;
remoteSyslog?: pulumi.Input<inputs.org.NetworktemplateRemoteSyslog>;
/**
* By default, only the configuration generated by Mist is cleaned up during the configuration process. If `true`, all the existing configuration will be removed.
*/
removeExistingConfigs?: pulumi.Input<boolean>;
/**
* Property key is the routing policy name
*/
routingPolicies?: pulumi.Input<{
[key: string]: pulumi.Input<inputs.org.NetworktemplateRoutingPolicies>;
}>;
snmpConfig?: pulumi.Input<inputs.org.NetworktemplateSnmpConfig>;
/**
* Defines custom switch configuration based on different criteria
*/
switchMatching?: pulumi.Input<inputs.org.NetworktemplateSwitchMatching>;
/**
* Switch settings
*/
switchMgmt?: pulumi.Input<inputs.org.NetworktemplateSwitchMgmt>;
vrfConfig?: pulumi.Input<inputs.org.NetworktemplateVrfConfig>;
/**
* Property key is the network name
*/
vrfInstances?: pulumi.Input<{
[key: string]: pulumi.Input<inputs.org.NetworktemplateVrfInstances>;
}>;
}