cloudflare.StaticRoute
Explore with Pulumi AI
Example Usage
Coming soon!
Coming soon!
Coming soon!
Coming soon!
Coming soon!
resources:
exampleMagicWanStaticRoute:
type: cloudflare:MagicWanStaticRoute
name: example_magic_wan_static_route
properties:
accountId: 023e105f4ecef8ad9ca31a8372d0c353
nexthop: 203.0.113.1
prefix: 192.0.2.0/24
priority: 0
description: New route for new prefix 203.0.113.1
scope:
colo_names:
- den01
colo_regions:
- APAC
weight: 0
Create StaticRoute Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new StaticRoute(name: string, args: StaticRouteArgs, opts?: CustomResourceOptions);
@overload
def StaticRoute(resource_name: str,
args: StaticRouteArgs,
opts: Optional[ResourceOptions] = None)
@overload
def StaticRoute(resource_name: str,
opts: Optional[ResourceOptions] = None,
account_id: Optional[str] = None,
description: Optional[str] = None,
nexthop: Optional[str] = None,
prefix: Optional[str] = None,
priority: Optional[int] = None,
route: Optional[StaticRouteRouteArgs] = None,
scope: Optional[StaticRouteScopeArgs] = None,
weight: Optional[int] = None)
func NewStaticRoute(ctx *Context, name string, args StaticRouteArgs, opts ...ResourceOption) (*StaticRoute, error)
public StaticRoute(string name, StaticRouteArgs args, CustomResourceOptions? opts = null)
public StaticRoute(String name, StaticRouteArgs args)
public StaticRoute(String name, StaticRouteArgs args, CustomResourceOptions options)
type: cloudflare:StaticRoute
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 StaticRouteArgs
- 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 StaticRouteArgs
- 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 StaticRouteArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args StaticRouteArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args StaticRouteArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
StaticRoute 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 StaticRoute resource accepts the following input properties:
- Account
Id string - Identifier
- Nexthop string
- The next-hop IP Address for the static route.
- Prefix string
- IP Prefix in Classless Inter-Domain Routing format.
- Priority int
- Priority of the static route.
- Description string
- An optional human provided description of the static route.
- Route
Static
Route Route - Scope
Static
Route Scope - Used only for ECMP routes.
- Weight int
- Optional weight of the ECMP scope - if provided.
- Account
Id string - Identifier
- Nexthop string
- The next-hop IP Address for the static route.
- Prefix string
- IP Prefix in Classless Inter-Domain Routing format.
- Priority int
- Priority of the static route.
- Description string
- An optional human provided description of the static route.
- Route
Static
Route Route Args - Scope
Static
Route Scope Args - Used only for ECMP routes.
- Weight int
- Optional weight of the ECMP scope - if provided.
- account
Id String - Identifier
- nexthop String
- The next-hop IP Address for the static route.
- prefix String
- IP Prefix in Classless Inter-Domain Routing format.
- priority Integer
- Priority of the static route.
- description String
- An optional human provided description of the static route.
- route
Static
Route Route - scope
Static
Route Scope - Used only for ECMP routes.
- weight Integer
- Optional weight of the ECMP scope - if provided.
- account
Id string - Identifier
- nexthop string
- The next-hop IP Address for the static route.
- prefix string
- IP Prefix in Classless Inter-Domain Routing format.
- priority number
- Priority of the static route.
- description string
- An optional human provided description of the static route.
- route
Static
Route Route - scope
Static
Route Scope - Used only for ECMP routes.
- weight number
- Optional weight of the ECMP scope - if provided.
- account_
id str - Identifier
- nexthop str
- The next-hop IP Address for the static route.
- prefix str
- IP Prefix in Classless Inter-Domain Routing format.
- priority int
- Priority of the static route.
- description str
- An optional human provided description of the static route.
- route
Static
Route Route Args - scope
Static
Route Scope Args - Used only for ECMP routes.
- weight int
- Optional weight of the ECMP scope - if provided.
- account
Id String - Identifier
- nexthop String
- The next-hop IP Address for the static route.
- prefix String
- IP Prefix in Classless Inter-Domain Routing format.
- priority Number
- Priority of the static route.
- description String
- An optional human provided description of the static route.
- route Property Map
- scope Property Map
- Used only for ECMP routes.
- weight Number
- Optional weight of the ECMP scope - if provided.
Outputs
All input properties are implicitly available as output properties. Additionally, the StaticRoute resource produces the following output properties:
- Created
On string - When the route was created.
- Id string
- The provider-assigned unique ID for this managed resource.
- Modified bool
- Modified
On string - When the route was last modified.
- Modified
Route StaticRoute Modified Route
- Created
On string - When the route was created.
- Id string
- The provider-assigned unique ID for this managed resource.
- Modified bool
- Modified
On string - When the route was last modified.
- Modified
Route StaticRoute Modified Route
- created
On String - When the route was created.
- id String
- The provider-assigned unique ID for this managed resource.
- modified Boolean
- modified
On String - When the route was last modified.
- modified
Route StaticRoute Modified Route
- created
On string - When the route was created.
- id string
- The provider-assigned unique ID for this managed resource.
- modified boolean
- modified
On string - When the route was last modified.
- modified
Route StaticRoute Modified Route
- created_
on str - When the route was created.
- id str
- The provider-assigned unique ID for this managed resource.
- modified bool
- modified_
on str - When the route was last modified.
- modified_
route StaticRoute Modified Route
- created
On String - When the route was created.
- id String
- The provider-assigned unique ID for this managed resource.
- modified Boolean
- modified
On String - When the route was last modified.
- modified
Route Property Map
Look up Existing StaticRoute Resource
Get an existing StaticRoute 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?: StaticRouteState, opts?: CustomResourceOptions): StaticRoute
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
account_id: Optional[str] = None,
created_on: Optional[str] = None,
description: Optional[str] = None,
modified: Optional[bool] = None,
modified_on: Optional[str] = None,
modified_route: Optional[StaticRouteModifiedRouteArgs] = None,
nexthop: Optional[str] = None,
prefix: Optional[str] = None,
priority: Optional[int] = None,
route: Optional[StaticRouteRouteArgs] = None,
scope: Optional[StaticRouteScopeArgs] = None,
weight: Optional[int] = None) -> StaticRoute
func GetStaticRoute(ctx *Context, name string, id IDInput, state *StaticRouteState, opts ...ResourceOption) (*StaticRoute, error)
public static StaticRoute Get(string name, Input<string> id, StaticRouteState? state, CustomResourceOptions? opts = null)
public static StaticRoute get(String name, Output<String> id, StaticRouteState state, CustomResourceOptions options)
resources: _: type: cloudflare:StaticRoute get: id: ${id}
- 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.
- Account
Id string - Identifier
- Created
On string - When the route was created.
- Description string
- An optional human provided description of the static route.
- Modified bool
- Modified
On string - When the route was last modified.
- Modified
Route StaticRoute Modified Route - Nexthop string
- The next-hop IP Address for the static route.
- Prefix string
- IP Prefix in Classless Inter-Domain Routing format.
- Priority int
- Priority of the static route.
- Route
Static
Route Route - Scope
Static
Route Scope - Used only for ECMP routes.
- Weight int
- Optional weight of the ECMP scope - if provided.
- Account
Id string - Identifier
- Created
On string - When the route was created.
- Description string
- An optional human provided description of the static route.
- Modified bool
- Modified
On string - When the route was last modified.
- Modified
Route StaticRoute Modified Route Args - Nexthop string
- The next-hop IP Address for the static route.
- Prefix string
- IP Prefix in Classless Inter-Domain Routing format.
- Priority int
- Priority of the static route.
- Route
Static
Route Route Args - Scope
Static
Route Scope Args - Used only for ECMP routes.
- Weight int
- Optional weight of the ECMP scope - if provided.
- account
Id String - Identifier
- created
On String - When the route was created.
- description String
- An optional human provided description of the static route.
- modified Boolean
- modified
On String - When the route was last modified.
- modified
Route StaticRoute Modified Route - nexthop String
- The next-hop IP Address for the static route.
- prefix String
- IP Prefix in Classless Inter-Domain Routing format.
- priority Integer
- Priority of the static route.
- route
Static
Route Route - scope
Static
Route Scope - Used only for ECMP routes.
- weight Integer
- Optional weight of the ECMP scope - if provided.
- account
Id string - Identifier
- created
On string - When the route was created.
- description string
- An optional human provided description of the static route.
- modified boolean
- modified
On string - When the route was last modified.
- modified
Route StaticRoute Modified Route - nexthop string
- The next-hop IP Address for the static route.
- prefix string
- IP Prefix in Classless Inter-Domain Routing format.
- priority number
- Priority of the static route.
- route
Static
Route Route - scope
Static
Route Scope - Used only for ECMP routes.
- weight number
- Optional weight of the ECMP scope - if provided.
- account_
id str - Identifier
- created_
on str - When the route was created.
- description str
- An optional human provided description of the static route.
- modified bool
- modified_
on str - When the route was last modified.
- modified_
route StaticRoute Modified Route Args - nexthop str
- The next-hop IP Address for the static route.
- prefix str
- IP Prefix in Classless Inter-Domain Routing format.
- priority int
- Priority of the static route.
- route
Static
Route Route Args - scope
Static
Route Scope Args - Used only for ECMP routes.
- weight int
- Optional weight of the ECMP scope - if provided.
- account
Id String - Identifier
- created
On String - When the route was created.
- description String
- An optional human provided description of the static route.
- modified Boolean
- modified
On String - When the route was last modified.
- modified
Route Property Map - nexthop String
- The next-hop IP Address for the static route.
- prefix String
- IP Prefix in Classless Inter-Domain Routing format.
- priority Number
- Priority of the static route.
- route Property Map
- scope Property Map
- Used only for ECMP routes.
- weight Number
- Optional weight of the ECMP scope - if provided.
Supporting Types
StaticRouteModifiedRoute, StaticRouteModifiedRouteArgs
- Created
On string - When the route was created.
- Description string
- An optional human provided description of the static route.
- Id string
- Identifier
- Modified
On string - When the route was last modified.
- Nexthop string
- The next-hop IP Address for the static route.
- Prefix string
- IP Prefix in Classless Inter-Domain Routing format.
- Priority int
- Priority of the static route.
- Scope
Static
Route Modified Route Scope - Used only for ECMP routes.
- Weight int
- Optional weight of the ECMP scope - if provided.
- Created
On string - When the route was created.
- Description string
- An optional human provided description of the static route.
- Id string
- Identifier
- Modified
On string - When the route was last modified.
- Nexthop string
- The next-hop IP Address for the static route.
- Prefix string
- IP Prefix in Classless Inter-Domain Routing format.
- Priority int
- Priority of the static route.
- Scope
Static
Route Modified Route Scope - Used only for ECMP routes.
- Weight int
- Optional weight of the ECMP scope - if provided.
- created
On String - When the route was created.
- description String
- An optional human provided description of the static route.
- id String
- Identifier
- modified
On String - When the route was last modified.
- nexthop String
- The next-hop IP Address for the static route.
- prefix String
- IP Prefix in Classless Inter-Domain Routing format.
- priority Integer
- Priority of the static route.
- scope
Static
Route Modified Route Scope - Used only for ECMP routes.
- weight Integer
- Optional weight of the ECMP scope - if provided.
- created
On string - When the route was created.
- description string
- An optional human provided description of the static route.
- id string
- Identifier
- modified
On string - When the route was last modified.
- nexthop string
- The next-hop IP Address for the static route.
- prefix string
- IP Prefix in Classless Inter-Domain Routing format.
- priority number
- Priority of the static route.
- scope
Static
Route Modified Route Scope - Used only for ECMP routes.
- weight number
- Optional weight of the ECMP scope - if provided.
- created_
on str - When the route was created.
- description str
- An optional human provided description of the static route.
- id str
- Identifier
- modified_
on str - When the route was last modified.
- nexthop str
- The next-hop IP Address for the static route.
- prefix str
- IP Prefix in Classless Inter-Domain Routing format.
- priority int
- Priority of the static route.
- scope
Static
Route Modified Route Scope - Used only for ECMP routes.
- weight int
- Optional weight of the ECMP scope - if provided.
- created
On String - When the route was created.
- description String
- An optional human provided description of the static route.
- id String
- Identifier
- modified
On String - When the route was last modified.
- nexthop String
- The next-hop IP Address for the static route.
- prefix String
- IP Prefix in Classless Inter-Domain Routing format.
- priority Number
- Priority of the static route.
- scope Property Map
- Used only for ECMP routes.
- weight Number
- Optional weight of the ECMP scope - if provided.
StaticRouteModifiedRouteScope, StaticRouteModifiedRouteScopeArgs
- Colo
Names List<string> - List of colo names for the ECMP scope.
- Colo
Regions List<string> - List of colo regions for the ECMP scope.
- Colo
Names []string - List of colo names for the ECMP scope.
- Colo
Regions []string - List of colo regions for the ECMP scope.
- colo
Names List<String> - List of colo names for the ECMP scope.
- colo
Regions List<String> - List of colo regions for the ECMP scope.
- colo
Names string[] - List of colo names for the ECMP scope.
- colo
Regions string[] - List of colo regions for the ECMP scope.
- colo_
names Sequence[str] - List of colo names for the ECMP scope.
- colo_
regions Sequence[str] - List of colo regions for the ECMP scope.
- colo
Names List<String> - List of colo names for the ECMP scope.
- colo
Regions List<String> - List of colo regions for the ECMP scope.
StaticRouteRoute, StaticRouteRouteArgs
- Created
On string - When the route was created.
- Description string
- An optional human provided description of the static route.
- Id string
- Identifier
- Modified
On string - When the route was last modified.
- Nexthop string
- The next-hop IP Address for the static route.
- Prefix string
- IP Prefix in Classless Inter-Domain Routing format.
- Priority int
- Priority of the static route.
- Scope
Static
Route Route Scope - Used only for ECMP routes.
- Weight int
- Optional weight of the ECMP scope - if provided.
- Created
On string - When the route was created.
- Description string
- An optional human provided description of the static route.
- Id string
- Identifier
- Modified
On string - When the route was last modified.
- Nexthop string
- The next-hop IP Address for the static route.
- Prefix string
- IP Prefix in Classless Inter-Domain Routing format.
- Priority int
- Priority of the static route.
- Scope
Static
Route Route Scope - Used only for ECMP routes.
- Weight int
- Optional weight of the ECMP scope - if provided.
- created
On String - When the route was created.
- description String
- An optional human provided description of the static route.
- id String
- Identifier
- modified
On String - When the route was last modified.
- nexthop String
- The next-hop IP Address for the static route.
- prefix String
- IP Prefix in Classless Inter-Domain Routing format.
- priority Integer
- Priority of the static route.
- scope
Static
Route Route Scope - Used only for ECMP routes.
- weight Integer
- Optional weight of the ECMP scope - if provided.
- created
On string - When the route was created.
- description string
- An optional human provided description of the static route.
- id string
- Identifier
- modified
On string - When the route was last modified.
- nexthop string
- The next-hop IP Address for the static route.
- prefix string
- IP Prefix in Classless Inter-Domain Routing format.
- priority number
- Priority of the static route.
- scope
Static
Route Route Scope - Used only for ECMP routes.
- weight number
- Optional weight of the ECMP scope - if provided.
- created_
on str - When the route was created.
- description str
- An optional human provided description of the static route.
- id str
- Identifier
- modified_
on str - When the route was last modified.
- nexthop str
- The next-hop IP Address for the static route.
- prefix str
- IP Prefix in Classless Inter-Domain Routing format.
- priority int
- Priority of the static route.
- scope
Static
Route Route Scope - Used only for ECMP routes.
- weight int
- Optional weight of the ECMP scope - if provided.
- created
On String - When the route was created.
- description String
- An optional human provided description of the static route.
- id String
- Identifier
- modified
On String - When the route was last modified.
- nexthop String
- The next-hop IP Address for the static route.
- prefix String
- IP Prefix in Classless Inter-Domain Routing format.
- priority Number
- Priority of the static route.
- scope Property Map
- Used only for ECMP routes.
- weight Number
- Optional weight of the ECMP scope - if provided.
StaticRouteRouteScope, StaticRouteRouteScopeArgs
- Colo
Names List<string> - List of colo names for the ECMP scope.
- Colo
Regions List<string> - List of colo regions for the ECMP scope.
- Colo
Names []string - List of colo names for the ECMP scope.
- Colo
Regions []string - List of colo regions for the ECMP scope.
- colo
Names List<String> - List of colo names for the ECMP scope.
- colo
Regions List<String> - List of colo regions for the ECMP scope.
- colo
Names string[] - List of colo names for the ECMP scope.
- colo
Regions string[] - List of colo regions for the ECMP scope.
- colo_
names Sequence[str] - List of colo names for the ECMP scope.
- colo_
regions Sequence[str] - List of colo regions for the ECMP scope.
- colo
Names List<String> - List of colo names for the ECMP scope.
- colo
Regions List<String> - List of colo regions for the ECMP scope.
StaticRouteScope, StaticRouteScopeArgs
- Colo
Names List<string> - List of colo names for the ECMP scope.
- Colo
Regions List<string> - List of colo regions for the ECMP scope.
- Colo
Names []string - List of colo names for the ECMP scope.
- Colo
Regions []string - List of colo regions for the ECMP scope.
- colo
Names List<String> - List of colo names for the ECMP scope.
- colo
Regions List<String> - List of colo regions for the ECMP scope.
- colo
Names string[] - List of colo names for the ECMP scope.
- colo
Regions string[] - List of colo regions for the ECMP scope.
- colo_
names Sequence[str] - List of colo names for the ECMP scope.
- colo_
regions Sequence[str] - List of colo regions for the ECMP scope.
- colo
Names List<String> - List of colo names for the ECMP scope.
- colo
Regions List<String> - List of colo regions for the ECMP scope.
Import
$ pulumi import cloudflare:index/staticRoute:StaticRoute example '<account_id>/<route_id>'
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- Cloudflare pulumi/pulumi-cloudflare
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
cloudflare
Terraform Provider.