Router Interface
Provides a Express Connect Router Interface resource. For information about Express Connect Router Interface and how to use it, see What is Router Interface.
NOTE: Available since v1.199.0.
Example Usage
Basic Usage
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";
const config = new pulumi.Config();
const name = config.get("name") || "tf_example";
const _default = alicloud.vpc.getNetworks({
nameRegex: "default-NODELETING",
});
const defaultGetRegions = alicloud.getRegions({
current: true,
});
const defaultRouterInterface = new alicloud.expressconnect.RouterInterface("default", {
description: name,
oppositeRegionId: defaultGetRegions.then(defaultGetRegions => defaultGetRegions.regions?.[0]?.id),
routerId: _default.then(_default => _default.vpcs?.[0]?.routerId),
role: "InitiatingSide",
routerType: "VRouter",
paymentType: "PayAsYouGo",
routerInterfaceName: name,
spec: "Mini.2",
});
import pulumi
import pulumi_alicloud as alicloud
config = pulumi.Config()
name = config.get("name")
if name is None:
name = "tf_example"
default = alicloud.vpc.get_networks(name_regex="default-NODELETING")
default_get_regions = alicloud.get_regions(current=True)
default_router_interface = alicloud.expressconnect.RouterInterface("default",
description=name,
opposite_region_id=default_get_regions.regions[0].id,
router_id=default.vpcs[0].router_id,
role="InitiatingSide",
router_type="VRouter",
payment_type="PayAsYouGo",
router_interface_name=name,
spec="Mini.2")
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;
return await Deployment.RunAsync(() =>
{
var config = new Config();
var name = config.Get("name") ?? "tf_example";
var @default = AliCloud.Vpc.GetNetworks.Invoke(new()
{
NameRegex = "default-NODELETING",
});
var defaultGetRegions = AliCloud.GetRegions.Invoke(new()
{
Current = true,
});
var defaultRouterInterface = new AliCloud.ExpressConnect.RouterInterface("default", new()
{
Description = name,
OppositeRegionId = defaultGetRegions.Apply(getRegionsResult => getRegionsResult.Regions[0]?.Id),
RouterId = @default.Apply(@default => @default.Apply(getNetworksResult => getNetworksResult.Vpcs[0]?.RouterId)),
Role = "InitiatingSide",
RouterType = "VRouter",
PaymentType = "PayAsYouGo",
RouterInterfaceName = name,
Spec = "Mini.2",
});
});
package main
import (
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud"
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/expressconnect"
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/vpc"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi/config"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
cfg := config.New(ctx, "")
name := "tf_example"
if param := cfg.Get("name"); param != "" {
name = param
}
_default, err := vpc.GetNetworks(ctx, &vpc.GetNetworksArgs{
NameRegex: pulumi.StringRef("default-NODELETING"),
}, nil)
if err != nil {
return err
}
defaultGetRegions, err := alicloud.GetRegions(ctx, &alicloud.GetRegionsArgs{
Current: pulumi.BoolRef(true),
}, nil)
if err != nil {
return err
}
_, err = expressconnect.NewRouterInterface(ctx, "default", &expressconnect.RouterInterfaceArgs{
Description: pulumi.String(name),
OppositeRegionId: pulumi.String(defaultGetRegions.Regions[0].Id),
RouterId: pulumi.String(_default.Vpcs[0].RouterId),
Role: pulumi.String("InitiatingSide"),
RouterType: pulumi.String("VRouter"),
PaymentType: pulumi.String("PayAsYouGo"),
RouterInterfaceName: pulumi.String(name),
Spec: pulumi.String("Mini.2"),
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.vpc.VpcFunctions;
import com.pulumi.alicloud.vpc.inputs.GetNetworksArgs;
import com.pulumi.alicloud.AlicloudFunctions;
import com.pulumi.alicloud.inputs.GetRegionsArgs;
import com.pulumi.alicloud.expressconnect.RouterInterface;
import com.pulumi.alicloud.expressconnect.RouterInterfaceArgs;
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) {
final var config = ctx.config();
final var name = config.get("name").orElse("tf_example");
final var default = VpcFunctions.getNetworks(GetNetworksArgs.builder()
.nameRegex("default-NODELETING")
.build());
final var defaultGetRegions = AlicloudFunctions.getRegions(GetRegionsArgs.builder()
.current(true)
.build());
var defaultRouterInterface = new RouterInterface("defaultRouterInterface", RouterInterfaceArgs.builder()
.description(name)
.oppositeRegionId(defaultGetRegions.regions()[0].id())
.routerId(default_.vpcs()[0].routerId())
.role("InitiatingSide")
.routerType("VRouter")
.paymentType("PayAsYouGo")
.routerInterfaceName(name)
.spec("Mini.2")
.build());
}
}
configuration:
name:
type: string
default: tf_example
resources:
defaultRouterInterface:
type: alicloud:expressconnect:RouterInterface
name: default
properties:
description: ${name}
oppositeRegionId: ${defaultGetRegions.regions[0].id}
routerId: ${default.vpcs[0].routerId}
role: InitiatingSide
routerType: VRouter
paymentType: PayAsYouGo
routerInterfaceName: ${name}
spec: Mini.2
variables:
default:
fn::invoke:
function: alicloud:vpc:getNetworks
arguments:
nameRegex: default-NODELETING
defaultGetRegions:
fn::invoke:
function: alicloud:getRegions
arguments:
current: true
Import
Express Connect Router Interface can be imported using the id, e.g.
$ pulumi import alicloud:expressconnect/routerInterface:RouterInterface example <id>
Properties
The access point ID to which the VBR belongs.
Whether to pay automatically, value:-false (default): automatic payment is not enabled. After generating an order, you need to complete the payment at the order center.-true: Enable automatic payment to automatically pay for orders.>InstanceChargeType is required when the value of the parameter is **PrePaid.
The businessStatus of the resource. Valid Values: Normal
, FinancialLocked
, SecurityLocked
.
The connected time of the resource.
The creation time of the resource.
The cross border of the resource.
Whether to delete the health check IP address configured on the router interface. Value:-true: deletes the health check IP address.-false (default): does not delete the health check IP address.
The description of the router interface. The description must be 2 to 256 characters in length and cannot start with http:// or https://.
The has reservation data of the resource.
The health check thresholds. Unit: pcs. The recommended value is 8. This indicates the number of probe messages to be sent during the specified health check.
The health check source IP address, must be an unused IP within the local VPC.
The IP address for health screening purposes.
The Access point ID to which the other end belongs.
The opposite bandwidth of the router on the other side.
The opposite interface business status of the router on the other side. Valid Values: Normal
, FinancialLocked
, SecurityLocked
.
The Interface ID of the router at the other end.
The AliCloud account ID of the owner of the router interface on the other end.
The opposite interface spec of the router on the other side. Valid Values: Mini.2
, Mini.5
, Mini.5
, Small.2
, Small.5
, Middle.1
, Middle.2
, Middle.5
, Large.1
, Large.2
, Large.5
, XLarge.1
, Negative
.
The opposite interface status of the router on the other side. Valid Values: Idle
, AcceptingConnecting
, Connecting
, Activating
, Active
, Modifying
, Deactivating
, Inactive
, Deleting
.
The geographical ID of the location of the receiving end of the connection.
The id of the router at the other end.
The opposite router type of the router on the other side. Valid Values: VRouter
, VBR
.
The opposite vpc instance id of the router on the other side.
The payment methods for router interfaces. Valid Values: PayAsYouGo
, Subscription
.
The billing cycle of the prepaid fee. Valid values:-Month (default): monthly payment.-Year: Pay per Year.>InstanceChargeType is required when the value of the parameter is **PrePaid.
The reservation active time of the resource.
The reservation bandwidth of the resource.
The reservation internet charge type of the resource.
The reservation order type of the resource.
The first ID of the resource.
The name of the resource.
The type of router associated with the router interface. Valid Values: VRouter
, VBR
.
The vpc instance id of the resource.