Viewing docs for flexibleengine 1.46.0
published on Monday, Apr 14, 2025 by flexibleenginecloud
published on Monday, Apr 14, 2025 by flexibleenginecloud
Viewing docs for flexibleengine 1.46.0
published on Monday, Apr 14, 2025 by flexibleenginecloud
published on Monday, Apr 14, 2025 by flexibleenginecloud
!> WARNING: It has been deprecated, use flexibleengine.VpcRouteTable to get the route details.
flexibleengine.VpcRouteV2 provides details about a specific VPC route.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as flexibleengine from "@pulumi/flexibleengine";
const config = new pulumi.Config();
const routeId = config.requireObject("routeId");
const vpcRoute = flexibleengine.getVpcRouteV2({
id: routeId,
});
const subnetV1 = new flexibleengine.VpcSubnetV1("subnetV1", {
cidr: "192.168.0.0/24",
gatewayIp: "192.168.0.1",
vpcId: vpcRoute.then(vpcRoute => vpcRoute.vpcId),
});
import pulumi
import pulumi_flexibleengine as flexibleengine
config = pulumi.Config()
route_id = config.require_object("routeId")
vpc_route = flexibleengine.get_vpc_route_v2(id=route_id)
subnet_v1 = flexibleengine.VpcSubnetV1("subnetV1",
cidr="192.168.0.0/24",
gateway_ip="192.168.0.1",
vpc_id=vpc_route.vpc_id)
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/flexibleengine/flexibleengine"
"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, "")
routeId := cfg.RequireObject("routeId")
vpcRoute, err := flexibleengine.LookupVpcRouteV2(ctx, &flexibleengine.LookupVpcRouteV2Args{
Id: pulumi.StringRef(routeId),
}, nil)
if err != nil {
return err
}
_, err = flexibleengine.NewVpcSubnetV1(ctx, "subnetV1", &flexibleengine.VpcSubnetV1Args{
Cidr: pulumi.String("192.168.0.0/24"),
GatewayIp: pulumi.String("192.168.0.1"),
VpcId: pulumi.String(vpcRoute.VpcId),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Flexibleengine = Pulumi.Flexibleengine;
return await Deployment.RunAsync(() =>
{
var config = new Config();
var routeId = config.RequireObject<dynamic>("routeId");
var vpcRoute = Flexibleengine.GetVpcRouteV2.Invoke(new()
{
Id = routeId,
});
var subnetV1 = new Flexibleengine.VpcSubnetV1("subnetV1", new()
{
Cidr = "192.168.0.0/24",
GatewayIp = "192.168.0.1",
VpcId = vpcRoute.Apply(getVpcRouteV2Result => getVpcRouteV2Result.VpcId),
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.flexibleengine.FlexibleengineFunctions;
import com.pulumi.flexibleengine.inputs.GetVpcRouteV2Args;
import com.pulumi.flexibleengine.VpcSubnetV1;
import com.pulumi.flexibleengine.VpcSubnetV1Args;
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 routeId = config.get("routeId");
final var vpcRoute = FlexibleengineFunctions.getVpcRouteV2(GetVpcRouteV2Args.builder()
.id(routeId)
.build());
var subnetV1 = new VpcSubnetV1("subnetV1", VpcSubnetV1Args.builder()
.cidr("192.168.0.0/24")
.gatewayIp("192.168.0.1")
.vpcId(vpcRoute.applyValue(getVpcRouteV2Result -> getVpcRouteV2Result.vpcId()))
.build());
}
}
configuration:
routeId:
type: dynamic
resources:
subnetV1:
type: flexibleengine:VpcSubnetV1
properties:
cidr: 192.168.0.0/24
gatewayIp: 192.168.0.1
vpcId: ${vpcRoute.vpcId}
variables:
vpcRoute:
fn::invoke:
function: flexibleengine:getVpcRouteV2
arguments:
id: ${routeId}
Using getVpcRouteV2
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getVpcRouteV2(args: GetVpcRouteV2Args, opts?: InvokeOptions): Promise<GetVpcRouteV2Result>
function getVpcRouteV2Output(args: GetVpcRouteV2OutputArgs, opts?: InvokeOptions): Output<GetVpcRouteV2Result>def get_vpc_route_v2(destination: Optional[str] = None,
id: Optional[str] = None,
nexthop: Optional[str] = None,
region: Optional[str] = None,
tenant_id: Optional[str] = None,
type: Optional[str] = None,
vpc_id: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetVpcRouteV2Result
def get_vpc_route_v2_output(destination: Optional[pulumi.Input[str]] = None,
id: Optional[pulumi.Input[str]] = None,
nexthop: Optional[pulumi.Input[str]] = None,
region: Optional[pulumi.Input[str]] = None,
tenant_id: Optional[pulumi.Input[str]] = None,
type: Optional[pulumi.Input[str]] = None,
vpc_id: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetVpcRouteV2Result]func LookupVpcRouteV2(ctx *Context, args *LookupVpcRouteV2Args, opts ...InvokeOption) (*LookupVpcRouteV2Result, error)
func LookupVpcRouteV2Output(ctx *Context, args *LookupVpcRouteV2OutputArgs, opts ...InvokeOption) LookupVpcRouteV2ResultOutput> Note: This function is named LookupVpcRouteV2 in the Go SDK.
public static class GetVpcRouteV2
{
public static Task<GetVpcRouteV2Result> InvokeAsync(GetVpcRouteV2Args args, InvokeOptions? opts = null)
public static Output<GetVpcRouteV2Result> Invoke(GetVpcRouteV2InvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetVpcRouteV2Result> getVpcRouteV2(GetVpcRouteV2Args args, InvokeOptions options)
public static Output<GetVpcRouteV2Result> getVpcRouteV2(GetVpcRouteV2Args args, InvokeOptions options)
fn::invoke:
function: flexibleengine:index/getVpcRouteV2:getVpcRouteV2
arguments:
# arguments dictionaryThe following arguments are supported:
- Destination string
- The route destination address (CIDR).
- Id string
- The id of the specific route to retrieve.
- Nexthop string
- The next hop of the route. If the route type is peering, it will provide VPC peering connection ID.
- Region string
- The region in which to obtain the V1 VPC client. A VPC client is needed to retrieve VPCs. If omitted, the region argument of the provider is used.
- Tenant
Id string - Only the administrator can specify the tenant ID of other tenants.
- Type string
- Route type for filtering.
- Vpc
Id string - The id of the VPC that the desired route belongs to.
- Destination string
- The route destination address (CIDR).
- Id string
- The id of the specific route to retrieve.
- Nexthop string
- The next hop of the route. If the route type is peering, it will provide VPC peering connection ID.
- Region string
- The region in which to obtain the V1 VPC client. A VPC client is needed to retrieve VPCs. If omitted, the region argument of the provider is used.
- Tenant
Id string - Only the administrator can specify the tenant ID of other tenants.
- Type string
- Route type for filtering.
- Vpc
Id string - The id of the VPC that the desired route belongs to.
- destination String
- The route destination address (CIDR).
- id String
- The id of the specific route to retrieve.
- nexthop String
- The next hop of the route. If the route type is peering, it will provide VPC peering connection ID.
- region String
- The region in which to obtain the V1 VPC client. A VPC client is needed to retrieve VPCs. If omitted, the region argument of the provider is used.
- tenant
Id String - Only the administrator can specify the tenant ID of other tenants.
- type String
- Route type for filtering.
- vpc
Id String - The id of the VPC that the desired route belongs to.
- destination string
- The route destination address (CIDR).
- id string
- The id of the specific route to retrieve.
- nexthop string
- The next hop of the route. If the route type is peering, it will provide VPC peering connection ID.
- region string
- The region in which to obtain the V1 VPC client. A VPC client is needed to retrieve VPCs. If omitted, the region argument of the provider is used.
- tenant
Id string - Only the administrator can specify the tenant ID of other tenants.
- type string
- Route type for filtering.
- vpc
Id string - The id of the VPC that the desired route belongs to.
- destination str
- The route destination address (CIDR).
- id str
- The id of the specific route to retrieve.
- nexthop str
- The next hop of the route. If the route type is peering, it will provide VPC peering connection ID.
- region str
- The region in which to obtain the V1 VPC client. A VPC client is needed to retrieve VPCs. If omitted, the region argument of the provider is used.
- tenant_
id str - Only the administrator can specify the tenant ID of other tenants.
- type str
- Route type for filtering.
- vpc_
id str - The id of the VPC that the desired route belongs to.
- destination String
- The route destination address (CIDR).
- id String
- The id of the specific route to retrieve.
- nexthop String
- The next hop of the route. If the route type is peering, it will provide VPC peering connection ID.
- region String
- The region in which to obtain the V1 VPC client. A VPC client is needed to retrieve VPCs. If omitted, the region argument of the provider is used.
- tenant
Id String - Only the administrator can specify the tenant ID of other tenants.
- type String
- Route type for filtering.
- vpc
Id String - The id of the VPC that the desired route belongs to.
getVpcRouteV2 Result
The following output properties are available:
Package Details
- Repository
- flexibleengine flexibleenginecloud/terraform-provider-flexibleengine
- License
- Notes
- This Pulumi package is based on the
flexibleengineTerraform Provider.
Viewing docs for flexibleengine 1.46.0
published on Monday, Apr 14, 2025 by flexibleenginecloud
published on Monday, Apr 14, 2025 by flexibleenginecloud
