1. Packages
  2. Outscale Provider
  3. API Docs
  4. RouteTableLink
outscale 1.1.0 published on Thursday, Apr 3, 2025 by outscale

outscale.RouteTableLink

Explore with Pulumi AI

Manages a route table link.

For more information on this resource, see the User Guide.
For more information on this resource actions, see the API documentation.

Example Usage

Required resources

import * as pulumi from "@pulumi/pulumi";
import * as outscale from "@pulumi/outscale";

const net01 = new outscale.Net("net01", {ipRange: "10.0.0.0/16"});
const subnet01 = new outscale.Subnet("subnet01", {
    netId: net01.netId,
    ipRange: "10.0.0.0/18",
});
const routeTable01 = new outscale.RouteTable("routeTable01", {netId: net01.netId});
Copy
import pulumi
import pulumi_outscale as outscale

net01 = outscale.Net("net01", ip_range="10.0.0.0/16")
subnet01 = outscale.Subnet("subnet01",
    net_id=net01.net_id,
    ip_range="10.0.0.0/18")
route_table01 = outscale.RouteTable("routeTable01", net_id=net01.net_id)
Copy
package main

import (
	"github.com/pulumi/pulumi-terraform-provider/sdks/go/outscale/outscale"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		net01, err := outscale.NewNet(ctx, "net01", &outscale.NetArgs{
			IpRange: pulumi.String("10.0.0.0/16"),
		})
		if err != nil {
			return err
		}
		_, err = outscale.NewSubnet(ctx, "subnet01", &outscale.SubnetArgs{
			NetId:   net01.NetId,
			IpRange: pulumi.String("10.0.0.0/18"),
		})
		if err != nil {
			return err
		}
		_, err = outscale.NewRouteTable(ctx, "routeTable01", &outscale.RouteTableArgs{
			NetId: net01.NetId,
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Outscale = Pulumi.Outscale;

return await Deployment.RunAsync(() => 
{
    var net01 = new Outscale.Net("net01", new()
    {
        IpRange = "10.0.0.0/16",
    });

    var subnet01 = new Outscale.Subnet("subnet01", new()
    {
        NetId = net01.NetId,
        IpRange = "10.0.0.0/18",
    });

    var routeTable01 = new Outscale.RouteTable("routeTable01", new()
    {
        NetId = net01.NetId,
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.outscale.Net;
import com.pulumi.outscale.NetArgs;
import com.pulumi.outscale.Subnet;
import com.pulumi.outscale.SubnetArgs;
import com.pulumi.outscale.RouteTable;
import com.pulumi.outscale.RouteTableArgs;
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 net01 = new Net("net01", NetArgs.builder()
            .ipRange("10.0.0.0/16")
            .build());

        var subnet01 = new Subnet("subnet01", SubnetArgs.builder()
            .netId(net01.netId())
            .ipRange("10.0.0.0/18")
            .build());

        var routeTable01 = new RouteTable("routeTable01", RouteTableArgs.builder()
            .netId(net01.netId())
            .build());

    }
}
Copy
resources:
  net01:
    type: outscale:Net
    properties:
      ipRange: 10.0.0.0/16
  subnet01:
    type: outscale:Subnet
    properties:
      netId: ${net01.netId}
      ipRange: 10.0.0.0/18
  routeTable01:
    type: outscale:RouteTable
    properties:
      netId: ${net01.netId}
Copy
import * as pulumi from "@pulumi/pulumi";
import * as outscale from "@pulumi/outscale";

const routeTableLink01 = new outscale.RouteTableLink("routeTableLink01", {
    subnetId: outscale_subnet.subnet01.subnet_id,
    routeTableId: outscale_route_table.route_table01.route_table_id,
});
Copy
import pulumi
import pulumi_outscale as outscale

route_table_link01 = outscale.RouteTableLink("routeTableLink01",
    subnet_id=outscale_subnet["subnet01"]["subnet_id"],
    route_table_id=outscale_route_table["route_table01"]["route_table_id"])
Copy
package main

import (
	"github.com/pulumi/pulumi-terraform-provider/sdks/go/outscale/outscale"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := outscale.NewRouteTableLink(ctx, "routeTableLink01", &outscale.RouteTableLinkArgs{
			SubnetId:     pulumi.Any(outscale_subnet.Subnet01.Subnet_id),
			RouteTableId: pulumi.Any(outscale_route_table.Route_table01.Route_table_id),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Outscale = Pulumi.Outscale;

return await Deployment.RunAsync(() => 
{
    var routeTableLink01 = new Outscale.RouteTableLink("routeTableLink01", new()
    {
        SubnetId = outscale_subnet.Subnet01.Subnet_id,
        RouteTableId = outscale_route_table.Route_table01.Route_table_id,
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.outscale.RouteTableLink;
import com.pulumi.outscale.RouteTableLinkArgs;
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 routeTableLink01 = new RouteTableLink("routeTableLink01", RouteTableLinkArgs.builder()
            .subnetId(outscale_subnet.subnet01().subnet_id())
            .routeTableId(outscale_route_table.route_table01().route_table_id())
            .build());

    }
}
Copy
resources:
  routeTableLink01:
    type: outscale:RouteTableLink
    properties:
      subnetId: ${outscale_subnet.subnet01.subnet_id}
      routeTableId: ${outscale_route_table.route_table01.route_table_id}
Copy

Create RouteTableLink Resource

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

Constructor syntax

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

@overload
def RouteTableLink(resource_name: str,
                   opts: Optional[ResourceOptions] = None,
                   route_table_id: Optional[str] = None,
                   subnet_id: Optional[str] = None,
                   route_table_link_id: Optional[str] = None)
func NewRouteTableLink(ctx *Context, name string, args RouteTableLinkArgs, opts ...ResourceOption) (*RouteTableLink, error)
public RouteTableLink(string name, RouteTableLinkArgs args, CustomResourceOptions? opts = null)
public RouteTableLink(String name, RouteTableLinkArgs args)
public RouteTableLink(String name, RouteTableLinkArgs args, CustomResourceOptions options)
type: outscale:RouteTableLink
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. RouteTableLinkArgs
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. RouteTableLinkArgs
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. RouteTableLinkArgs
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. RouteTableLinkArgs
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. RouteTableLinkArgs
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 routeTableLinkResource = new Outscale.RouteTableLink("routeTableLinkResource", new()
{
    RouteTableId = "string",
    SubnetId = "string",
    RouteTableLinkId = "string",
});
Copy
example, err := outscale.NewRouteTableLink(ctx, "routeTableLinkResource", &outscale.RouteTableLinkArgs{
RouteTableId: pulumi.String("string"),
SubnetId: pulumi.String("string"),
RouteTableLinkId: pulumi.String("string"),
})
Copy
var routeTableLinkResource = new RouteTableLink("routeTableLinkResource", RouteTableLinkArgs.builder()
    .routeTableId("string")
    .subnetId("string")
    .routeTableLinkId("string")
    .build());
Copy
route_table_link_resource = outscale.RouteTableLink("routeTableLinkResource",
    route_table_id="string",
    subnet_id="string",
    route_table_link_id="string")
Copy
const routeTableLinkResource = new outscale.RouteTableLink("routeTableLinkResource", {
    routeTableId: "string",
    subnetId: "string",
    routeTableLinkId: "string",
});
Copy
type: outscale:RouteTableLink
properties:
    routeTableId: string
    routeTableLinkId: string
    subnetId: string
Copy

RouteTableLink 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 RouteTableLink resource accepts the following input properties:

RouteTableId This property is required. string
The ID of the route table.
SubnetId This property is required. string
The ID of the Net.
RouteTableLinkId string
RouteTableId This property is required. string
The ID of the route table.
SubnetId This property is required. string
The ID of the Net.
RouteTableLinkId string
routeTableId This property is required. String
The ID of the route table.
subnetId This property is required. String
The ID of the Net.
routeTableLinkId String
routeTableId This property is required. string
The ID of the route table.
subnetId This property is required. string
The ID of the Net.
routeTableLinkId string
route_table_id This property is required. str
The ID of the route table.
subnet_id This property is required. str
The ID of the Net.
route_table_link_id str
routeTableId This property is required. String
The ID of the route table.
subnetId This property is required. String
The ID of the Net.
routeTableLinkId String

Outputs

All input properties are implicitly available as output properties. Additionally, the RouteTableLink resource produces the following output properties:

Id string
The provider-assigned unique ID for this managed resource.
LinkRouteTableId string
The ID of the association between the route table and the Subnet.
Main bool
If true, the route table is the main one.
RequestId string
Id string
The provider-assigned unique ID for this managed resource.
LinkRouteTableId string
The ID of the association between the route table and the Subnet.
Main bool
If true, the route table is the main one.
RequestId string
id String
The provider-assigned unique ID for this managed resource.
linkRouteTableId String
The ID of the association between the route table and the Subnet.
main Boolean
If true, the route table is the main one.
requestId String
id string
The provider-assigned unique ID for this managed resource.
linkRouteTableId string
The ID of the association between the route table and the Subnet.
main boolean
If true, the route table is the main one.
requestId string
id str
The provider-assigned unique ID for this managed resource.
link_route_table_id str
The ID of the association between the route table and the Subnet.
main bool
If true, the route table is the main one.
request_id str
id String
The provider-assigned unique ID for this managed resource.
linkRouteTableId String
The ID of the association between the route table and the Subnet.
main Boolean
If true, the route table is the main one.
requestId String

Look up Existing RouteTableLink Resource

Get an existing RouteTableLink 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?: RouteTableLinkState, opts?: CustomResourceOptions): RouteTableLink
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        link_route_table_id: Optional[str] = None,
        main: Optional[bool] = None,
        request_id: Optional[str] = None,
        route_table_id: Optional[str] = None,
        route_table_link_id: Optional[str] = None,
        subnet_id: Optional[str] = None) -> RouteTableLink
func GetRouteTableLink(ctx *Context, name string, id IDInput, state *RouteTableLinkState, opts ...ResourceOption) (*RouteTableLink, error)
public static RouteTableLink Get(string name, Input<string> id, RouteTableLinkState? state, CustomResourceOptions? opts = null)
public static RouteTableLink get(String name, Output<String> id, RouteTableLinkState state, CustomResourceOptions options)
resources:  _:    type: outscale:RouteTableLink    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:
LinkRouteTableId string
The ID of the association between the route table and the Subnet.
Main bool
If true, the route table is the main one.
RequestId string
RouteTableId string
The ID of the route table.
RouteTableLinkId string
SubnetId string
The ID of the Net.
LinkRouteTableId string
The ID of the association between the route table and the Subnet.
Main bool
If true, the route table is the main one.
RequestId string
RouteTableId string
The ID of the route table.
RouteTableLinkId string
SubnetId string
The ID of the Net.
linkRouteTableId String
The ID of the association between the route table and the Subnet.
main Boolean
If true, the route table is the main one.
requestId String
routeTableId String
The ID of the route table.
routeTableLinkId String
subnetId String
The ID of the Net.
linkRouteTableId string
The ID of the association between the route table and the Subnet.
main boolean
If true, the route table is the main one.
requestId string
routeTableId string
The ID of the route table.
routeTableLinkId string
subnetId string
The ID of the Net.
link_route_table_id str
The ID of the association between the route table and the Subnet.
main bool
If true, the route table is the main one.
request_id str
route_table_id str
The ID of the route table.
route_table_link_id str
subnet_id str
The ID of the Net.
linkRouteTableId String
The ID of the association between the route table and the Subnet.
main Boolean
If true, the route table is the main one.
requestId String
routeTableId String
The ID of the route table.
routeTableLinkId String
subnetId String
The ID of the Net.

Import

A route table link can be imported using the route table ID and the route table link ID. For example:

console

$ pulumi import outscale:index/routeTableLink:RouteTableLink ImportedRouteTableLink rtb-12345678_rtbassoc-87654321
Copy

To learn more about importing existing cloud resources, see Importing resources.

Package Details

Repository
outscale outscale/terraform-provider-outscale
License
Notes
This Pulumi package is based on the outscale Terraform Provider.