meraki.devices.SwitchRoutingStaticRoutes
Explore with Pulumi AI
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as meraki from "@pulumi/meraki";
const example = new meraki.devices.SwitchRoutingStaticRoutes("example", {
advertiseViaOspfEnabled: false,
name: "My route",
nextHopIp: "1.2.3.4",
preferOverOspfRoutesEnabled: false,
serial: "string",
subnet: "192.168.1.0/24",
});
export const merakiDevicesSwitchRoutingStaticRoutesExample = example;
import pulumi
import pulumi_meraki as meraki
example = meraki.devices.SwitchRoutingStaticRoutes("example",
advertise_via_ospf_enabled=False,
name="My route",
next_hop_ip="1.2.3.4",
prefer_over_ospf_routes_enabled=False,
serial="string",
subnet="192.168.1.0/24")
pulumi.export("merakiDevicesSwitchRoutingStaticRoutesExample", example)
package main
import (
"github.com/pulumi/pulumi-meraki/sdk/go/meraki/devices"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
example, err := devices.NewSwitchRoutingStaticRoutes(ctx, "example", &devices.SwitchRoutingStaticRoutesArgs{
AdvertiseViaOspfEnabled: pulumi.Bool(false),
Name: pulumi.String("My route"),
NextHopIp: pulumi.String("1.2.3.4"),
PreferOverOspfRoutesEnabled: pulumi.Bool(false),
Serial: pulumi.String("string"),
Subnet: pulumi.String("192.168.1.0/24"),
})
if err != nil {
return err
}
ctx.Export("merakiDevicesSwitchRoutingStaticRoutesExample", example)
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Meraki = Pulumi.Meraki;
return await Deployment.RunAsync(() =>
{
var example = new Meraki.Devices.SwitchRoutingStaticRoutes("example", new()
{
AdvertiseViaOspfEnabled = false,
Name = "My route",
NextHopIp = "1.2.3.4",
PreferOverOspfRoutesEnabled = false,
Serial = "string",
Subnet = "192.168.1.0/24",
});
return new Dictionary<string, object?>
{
["merakiDevicesSwitchRoutingStaticRoutesExample"] = example,
};
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.meraki.devices.SwitchRoutingStaticRoutes;
import com.pulumi.meraki.devices.SwitchRoutingStaticRoutesArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var example = new SwitchRoutingStaticRoutes("example", SwitchRoutingStaticRoutesArgs.builder()
.advertiseViaOspfEnabled(false)
.name("My route")
.nextHopIp("1.2.3.4")
.preferOverOspfRoutesEnabled(false)
.serial("string")
.subnet("192.168.1.0/24")
.build());
ctx.export("merakiDevicesSwitchRoutingStaticRoutesExample", example);
}
}
resources:
example:
type: meraki:devices:SwitchRoutingStaticRoutes
properties:
advertiseViaOspfEnabled: false
name: My route
nextHopIp: 1.2.3.4
preferOverOspfRoutesEnabled: false
serial: string
subnet: 192.168.1.0/24
outputs:
merakiDevicesSwitchRoutingStaticRoutesExample: ${example}
Create SwitchRoutingStaticRoutes Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new SwitchRoutingStaticRoutes(name: string, args: SwitchRoutingStaticRoutesArgs, opts?: CustomResourceOptions);
@overload
def SwitchRoutingStaticRoutes(resource_name: str,
args: SwitchRoutingStaticRoutesArgs,
opts: Optional[ResourceOptions] = None)
@overload
def SwitchRoutingStaticRoutes(resource_name: str,
opts: Optional[ResourceOptions] = None,
serial: Optional[str] = None,
advertise_via_ospf_enabled: Optional[bool] = None,
name: Optional[str] = None,
next_hop_ip: Optional[str] = None,
prefer_over_ospf_routes_enabled: Optional[bool] = None,
static_route_id: Optional[str] = None,
subnet: Optional[str] = None)
func NewSwitchRoutingStaticRoutes(ctx *Context, name string, args SwitchRoutingStaticRoutesArgs, opts ...ResourceOption) (*SwitchRoutingStaticRoutes, error)
public SwitchRoutingStaticRoutes(string name, SwitchRoutingStaticRoutesArgs args, CustomResourceOptions? opts = null)
public SwitchRoutingStaticRoutes(String name, SwitchRoutingStaticRoutesArgs args)
public SwitchRoutingStaticRoutes(String name, SwitchRoutingStaticRoutesArgs args, CustomResourceOptions options)
type: meraki:devices:SwitchRoutingStaticRoutes
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args SwitchRoutingStaticRoutesArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args SwitchRoutingStaticRoutesArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args SwitchRoutingStaticRoutesArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args SwitchRoutingStaticRoutesArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args SwitchRoutingStaticRoutesArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var switchRoutingStaticRoutesResource = new Meraki.Devices.SwitchRoutingStaticRoutes("switchRoutingStaticRoutesResource", new()
{
Serial = "string",
AdvertiseViaOspfEnabled = false,
Name = "string",
NextHopIp = "string",
PreferOverOspfRoutesEnabled = false,
StaticRouteId = "string",
Subnet = "string",
});
example, err := devices.NewSwitchRoutingStaticRoutes(ctx, "switchRoutingStaticRoutesResource", &devices.SwitchRoutingStaticRoutesArgs{
Serial: pulumi.String("string"),
AdvertiseViaOspfEnabled: pulumi.Bool(false),
Name: pulumi.String("string"),
NextHopIp: pulumi.String("string"),
PreferOverOspfRoutesEnabled: pulumi.Bool(false),
StaticRouteId: pulumi.String("string"),
Subnet: pulumi.String("string"),
})
var switchRoutingStaticRoutesResource = new SwitchRoutingStaticRoutes("switchRoutingStaticRoutesResource", SwitchRoutingStaticRoutesArgs.builder()
.serial("string")
.advertiseViaOspfEnabled(false)
.name("string")
.nextHopIp("string")
.preferOverOspfRoutesEnabled(false)
.staticRouteId("string")
.subnet("string")
.build());
switch_routing_static_routes_resource = meraki.devices.SwitchRoutingStaticRoutes("switchRoutingStaticRoutesResource",
serial="string",
advertise_via_ospf_enabled=False,
name="string",
next_hop_ip="string",
prefer_over_ospf_routes_enabled=False,
static_route_id="string",
subnet="string")
const switchRoutingStaticRoutesResource = new meraki.devices.SwitchRoutingStaticRoutes("switchRoutingStaticRoutesResource", {
serial: "string",
advertiseViaOspfEnabled: false,
name: "string",
nextHopIp: "string",
preferOverOspfRoutesEnabled: false,
staticRouteId: "string",
subnet: "string",
});
type: meraki:devices:SwitchRoutingStaticRoutes
properties:
advertiseViaOspfEnabled: false
name: string
nextHopIp: string
preferOverOspfRoutesEnabled: false
serial: string
staticRouteId: string
subnet: string
SwitchRoutingStaticRoutes Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
The SwitchRoutingStaticRoutes resource accepts the following input properties:
- Serial string
- serial path parameter.
- Advertise
Via boolOspf Enabled - Option to advertise static routes via OSPF
- Name string
- The name or description of the layer 3 static route
- Next
Hop stringIp - The IP address of the router to which traffic for this destination network should be sent
- Prefer
Over boolOspf Routes Enabled - Option to prefer static routes over OSPF routes
- Static
Route stringId - The identifier of a layer 3 static route
- Subnet string
- The IP address of the subnetwork specified in CIDR notation (ex. 1.2.3.0/24)
- Serial string
- serial path parameter.
- Advertise
Via boolOspf Enabled - Option to advertise static routes via OSPF
- Name string
- The name or description of the layer 3 static route
- Next
Hop stringIp - The IP address of the router to which traffic for this destination network should be sent
- Prefer
Over boolOspf Routes Enabled - Option to prefer static routes over OSPF routes
- Static
Route stringId - The identifier of a layer 3 static route
- Subnet string
- The IP address of the subnetwork specified in CIDR notation (ex. 1.2.3.0/24)
- serial String
- serial path parameter.
- advertise
Via BooleanOspf Enabled - Option to advertise static routes via OSPF
- name String
- The name or description of the layer 3 static route
- next
Hop StringIp - The IP address of the router to which traffic for this destination network should be sent
- prefer
Over BooleanOspf Routes Enabled - Option to prefer static routes over OSPF routes
- static
Route StringId - The identifier of a layer 3 static route
- subnet String
- The IP address of the subnetwork specified in CIDR notation (ex. 1.2.3.0/24)
- serial string
- serial path parameter.
- advertise
Via booleanOspf Enabled - Option to advertise static routes via OSPF
- name string
- The name or description of the layer 3 static route
- next
Hop stringIp - The IP address of the router to which traffic for this destination network should be sent
- prefer
Over booleanOspf Routes Enabled - Option to prefer static routes over OSPF routes
- static
Route stringId - The identifier of a layer 3 static route
- subnet string
- The IP address of the subnetwork specified in CIDR notation (ex. 1.2.3.0/24)
- serial str
- serial path parameter.
- advertise_
via_ boolospf_ enabled - Option to advertise static routes via OSPF
- name str
- The name or description of the layer 3 static route
- next_
hop_ strip - The IP address of the router to which traffic for this destination network should be sent
- prefer_
over_ boolospf_ routes_ enabled - Option to prefer static routes over OSPF routes
- static_
route_ strid - The identifier of a layer 3 static route
- subnet str
- The IP address of the subnetwork specified in CIDR notation (ex. 1.2.3.0/24)
- serial String
- serial path parameter.
- advertise
Via BooleanOspf Enabled - Option to advertise static routes via OSPF
- name String
- The name or description of the layer 3 static route
- next
Hop StringIp - The IP address of the router to which traffic for this destination network should be sent
- prefer
Over BooleanOspf Routes Enabled - Option to prefer static routes over OSPF routes
- static
Route StringId - The identifier of a layer 3 static route
- subnet String
- The IP address of the subnetwork specified in CIDR notation (ex. 1.2.3.0/24)
Outputs
All input properties are implicitly available as output properties. Additionally, the SwitchRoutingStaticRoutes resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Id string
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
- id string
- The provider-assigned unique ID for this managed resource.
- id str
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing SwitchRoutingStaticRoutes Resource
Get an existing SwitchRoutingStaticRoutes resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: SwitchRoutingStaticRoutesState, opts?: CustomResourceOptions): SwitchRoutingStaticRoutes
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
advertise_via_ospf_enabled: Optional[bool] = None,
name: Optional[str] = None,
next_hop_ip: Optional[str] = None,
prefer_over_ospf_routes_enabled: Optional[bool] = None,
serial: Optional[str] = None,
static_route_id: Optional[str] = None,
subnet: Optional[str] = None) -> SwitchRoutingStaticRoutes
func GetSwitchRoutingStaticRoutes(ctx *Context, name string, id IDInput, state *SwitchRoutingStaticRoutesState, opts ...ResourceOption) (*SwitchRoutingStaticRoutes, error)
public static SwitchRoutingStaticRoutes Get(string name, Input<string> id, SwitchRoutingStaticRoutesState? state, CustomResourceOptions? opts = null)
public static SwitchRoutingStaticRoutes get(String name, Output<String> id, SwitchRoutingStaticRoutesState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Advertise
Via boolOspf Enabled - Option to advertise static routes via OSPF
- Name string
- The name or description of the layer 3 static route
- Next
Hop stringIp - The IP address of the router to which traffic for this destination network should be sent
- Prefer
Over boolOspf Routes Enabled - Option to prefer static routes over OSPF routes
- Serial string
- serial path parameter.
- Static
Route stringId - The identifier of a layer 3 static route
- Subnet string
- The IP address of the subnetwork specified in CIDR notation (ex. 1.2.3.0/24)
- Advertise
Via boolOspf Enabled - Option to advertise static routes via OSPF
- Name string
- The name or description of the layer 3 static route
- Next
Hop stringIp - The IP address of the router to which traffic for this destination network should be sent
- Prefer
Over boolOspf Routes Enabled - Option to prefer static routes over OSPF routes
- Serial string
- serial path parameter.
- Static
Route stringId - The identifier of a layer 3 static route
- Subnet string
- The IP address of the subnetwork specified in CIDR notation (ex. 1.2.3.0/24)
- advertise
Via BooleanOspf Enabled - Option to advertise static routes via OSPF
- name String
- The name or description of the layer 3 static route
- next
Hop StringIp - The IP address of the router to which traffic for this destination network should be sent
- prefer
Over BooleanOspf Routes Enabled - Option to prefer static routes over OSPF routes
- serial String
- serial path parameter.
- static
Route StringId - The identifier of a layer 3 static route
- subnet String
- The IP address of the subnetwork specified in CIDR notation (ex. 1.2.3.0/24)
- advertise
Via booleanOspf Enabled - Option to advertise static routes via OSPF
- name string
- The name or description of the layer 3 static route
- next
Hop stringIp - The IP address of the router to which traffic for this destination network should be sent
- prefer
Over booleanOspf Routes Enabled - Option to prefer static routes over OSPF routes
- serial string
- serial path parameter.
- static
Route stringId - The identifier of a layer 3 static route
- subnet string
- The IP address of the subnetwork specified in CIDR notation (ex. 1.2.3.0/24)
- advertise_
via_ boolospf_ enabled - Option to advertise static routes via OSPF
- name str
- The name or description of the layer 3 static route
- next_
hop_ strip - The IP address of the router to which traffic for this destination network should be sent
- prefer_
over_ boolospf_ routes_ enabled - Option to prefer static routes over OSPF routes
- serial str
- serial path parameter.
- static_
route_ strid - The identifier of a layer 3 static route
- subnet str
- The IP address of the subnetwork specified in CIDR notation (ex. 1.2.3.0/24)
- advertise
Via BooleanOspf Enabled - Option to advertise static routes via OSPF
- name String
- The name or description of the layer 3 static route
- next
Hop StringIp - The IP address of the router to which traffic for this destination network should be sent
- prefer
Over BooleanOspf Routes Enabled - Option to prefer static routes over OSPF routes
- serial String
- serial path parameter.
- static
Route StringId - The identifier of a layer 3 static route
- subnet String
- The IP address of the subnetwork specified in CIDR notation (ex. 1.2.3.0/24)
Import
$ pulumi import meraki:devices/switchRoutingStaticRoutes:SwitchRoutingStaticRoutes example "serial,static_route_id"
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- meraki pulumi/pulumi-meraki
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
meraki
Terraform Provider.