1. Packages
  2. Fortios
  3. API Docs
  4. fmg
  5. SystemNetworkRoute
Fortios v0.0.6 published on Tuesday, Jul 9, 2024 by pulumiverse

fortios.fmg.SystemNetworkRoute

Explore with Pulumi AI

This resource supports updating system network route for FortiManager.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as fortios from "@pulumiverse/fortios";

const test1 = new fortios.fmg.SystemNetworkRoute("test1", {
    destination: "192.168.2.0 255.255.255.0",
    device: "port4",
    gateway: "192.168.2.1",
    routeId: 5,
});
Copy
import pulumi
import pulumiverse_fortios as fortios

test1 = fortios.fmg.SystemNetworkRoute("test1",
    destination="192.168.2.0 255.255.255.0",
    device="port4",
    gateway="192.168.2.1",
    route_id=5)
Copy
package main

import (
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
	"github.com/pulumiverse/pulumi-fortios/sdk/go/fortios/fmg"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := fmg.NewSystemNetworkRoute(ctx, "test1", &fmg.SystemNetworkRouteArgs{
			Destination: pulumi.String("192.168.2.0 255.255.255.0"),
			Device:      pulumi.String("port4"),
			Gateway:     pulumi.String("192.168.2.1"),
			RouteId:     pulumi.Int(5),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Fortios = Pulumiverse.Fortios;

return await Deployment.RunAsync(() => 
{
    var test1 = new Fortios.Fmg.SystemNetworkRoute("test1", new()
    {
        Destination = "192.168.2.0 255.255.255.0",
        Device = "port4",
        Gateway = "192.168.2.1",
        RouteId = 5,
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.fortios.fmg.SystemNetworkRoute;
import com.pulumi.fortios.fmg.SystemNetworkRouteArgs;
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 test1 = new SystemNetworkRoute("test1", SystemNetworkRouteArgs.builder()
            .destination("192.168.2.0 255.255.255.0")
            .device("port4")
            .gateway("192.168.2.1")
            .routeId(5)
            .build());

    }
}
Copy
resources:
  test1:
    type: fortios:fmg:SystemNetworkRoute
    properties:
      destination: 192.168.2.0 255.255.255.0
      device: port4
      gateway: 192.168.2.1
      routeId: 5
Copy

Create SystemNetworkRoute Resource

Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

Constructor syntax

new SystemNetworkRoute(name: string, args: SystemNetworkRouteArgs, opts?: CustomResourceOptions);
@overload
def SystemNetworkRoute(resource_name: str,
                       args: SystemNetworkRouteArgs,
                       opts: Optional[ResourceOptions] = None)

@overload
def SystemNetworkRoute(resource_name: str,
                       opts: Optional[ResourceOptions] = None,
                       destination: Optional[str] = None,
                       device: Optional[str] = None,
                       gateway: Optional[str] = None,
                       route_id: Optional[int] = None)
func NewSystemNetworkRoute(ctx *Context, name string, args SystemNetworkRouteArgs, opts ...ResourceOption) (*SystemNetworkRoute, error)
public SystemNetworkRoute(string name, SystemNetworkRouteArgs args, CustomResourceOptions? opts = null)
public SystemNetworkRoute(String name, SystemNetworkRouteArgs args)
public SystemNetworkRoute(String name, SystemNetworkRouteArgs args, CustomResourceOptions options)
type: fortios:fmg:SystemNetworkRoute
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. string
The unique name of the resource.
args This property is required. SystemNetworkRouteArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args This property is required. SystemNetworkRouteArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name This property is required. string
The unique name of the resource.
args This property is required. SystemNetworkRouteArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args This property is required. SystemNetworkRouteArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. SystemNetworkRouteArgs
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 systemNetworkRouteResource = new Fortios.Fmg.SystemNetworkRoute("systemNetworkRouteResource", new()
{
    Destination = "string",
    Device = "string",
    Gateway = "string",
    RouteId = 0,
});
Copy
example, err := fmg.NewSystemNetworkRoute(ctx, "systemNetworkRouteResource", &fmg.SystemNetworkRouteArgs{
	Destination: pulumi.String("string"),
	Device:      pulumi.String("string"),
	Gateway:     pulumi.String("string"),
	RouteId:     pulumi.Int(0),
})
Copy
var systemNetworkRouteResource = new SystemNetworkRoute("systemNetworkRouteResource", SystemNetworkRouteArgs.builder()
    .destination("string")
    .device("string")
    .gateway("string")
    .routeId(0)
    .build());
Copy
system_network_route_resource = fortios.fmg.SystemNetworkRoute("systemNetworkRouteResource",
    destination="string",
    device="string",
    gateway="string",
    route_id=0)
Copy
const systemNetworkRouteResource = new fortios.fmg.SystemNetworkRoute("systemNetworkRouteResource", {
    destination: "string",
    device: "string",
    gateway: "string",
    routeId: 0,
});
Copy
type: fortios:fmg:SystemNetworkRoute
properties:
    destination: string
    device: string
    gateway: string
    routeId: 0
Copy

SystemNetworkRoute Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

The SystemNetworkRoute resource accepts the following input properties:

Destination This property is required. string
Destination Ip/Mask.
Device This property is required. string
Gateway out interface.
Gateway This property is required. string
Gateway Ip.
RouteId This property is required. int
Route id.
Destination This property is required. string
Destination Ip/Mask.
Device This property is required. string
Gateway out interface.
Gateway This property is required. string
Gateway Ip.
RouteId This property is required. int
Route id.
destination This property is required. String
Destination Ip/Mask.
device This property is required. String
Gateway out interface.
gateway This property is required. String
Gateway Ip.
routeId This property is required. Integer
Route id.
destination This property is required. string
Destination Ip/Mask.
device This property is required. string
Gateway out interface.
gateway This property is required. string
Gateway Ip.
routeId This property is required. number
Route id.
destination This property is required. str
Destination Ip/Mask.
device This property is required. str
Gateway out interface.
gateway This property is required. str
Gateway Ip.
route_id This property is required. int
Route id.
destination This property is required. String
Destination Ip/Mask.
device This property is required. String
Gateway out interface.
gateway This property is required. String
Gateway Ip.
routeId This property is required. Number
Route id.

Outputs

All input properties are implicitly available as output properties. Additionally, the SystemNetworkRoute 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 SystemNetworkRoute Resource

Get an existing SystemNetworkRoute 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?: SystemNetworkRouteState, opts?: CustomResourceOptions): SystemNetworkRoute
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        destination: Optional[str] = None,
        device: Optional[str] = None,
        gateway: Optional[str] = None,
        route_id: Optional[int] = None) -> SystemNetworkRoute
func GetSystemNetworkRoute(ctx *Context, name string, id IDInput, state *SystemNetworkRouteState, opts ...ResourceOption) (*SystemNetworkRoute, error)
public static SystemNetworkRoute Get(string name, Input<string> id, SystemNetworkRouteState? state, CustomResourceOptions? opts = null)
public static SystemNetworkRoute get(String name, Output<String> id, SystemNetworkRouteState state, CustomResourceOptions options)
resources:  _:    type: fortios:fmg:SystemNetworkRoute    get:      id: ${id}
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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.
The following state arguments are supported:
Destination string
Destination Ip/Mask.
Device string
Gateway out interface.
Gateway string
Gateway Ip.
RouteId int
Route id.
Destination string
Destination Ip/Mask.
Device string
Gateway out interface.
Gateway string
Gateway Ip.
RouteId int
Route id.
destination String
Destination Ip/Mask.
device String
Gateway out interface.
gateway String
Gateway Ip.
routeId Integer
Route id.
destination string
Destination Ip/Mask.
device string
Gateway out interface.
gateway string
Gateway Ip.
routeId number
Route id.
destination str
Destination Ip/Mask.
device str
Gateway out interface.
gateway str
Gateway Ip.
route_id int
Route id.
destination String
Destination Ip/Mask.
device String
Gateway out interface.
gateway String
Gateway Ip.
routeId Number
Route id.

Package Details

Repository
fortios pulumiverse/pulumi-fortios
License
Apache-2.0
Notes
This Pulumi package is based on the fortios Terraform Provider.