1. Packages
  2. Alibaba Cloud Provider
  3. API Docs
  4. eflo
  5. Vpd
Alibaba Cloud v3.90.0 published on Tuesday, Dec 2, 2025 by Pulumi
alicloud logo
Alibaba Cloud v3.90.0 published on Tuesday, Dec 2, 2025 by Pulumi

    Provides a Eflo Vpd resource.

    Lingjun Network Segment.

    For information about Eflo Vpd and how to use it, see What is Vpd.

    NOTE: Available since v1.201.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") || "terraform-example";
    const _default = alicloud.resourcemanager.getResourceGroups({});
    const defaultVpd = new alicloud.eflo.Vpd("default", {
        cidr: "10.0.0.0/8",
        vpdName: name,
        resourceGroupId: _default.then(_default => _default.groups?.[0]?.id),
    });
    
    import pulumi
    import pulumi_alicloud as alicloud
    
    config = pulumi.Config()
    name = config.get("name")
    if name is None:
        name = "terraform-example"
    default = alicloud.resourcemanager.get_resource_groups()
    default_vpd = alicloud.eflo.Vpd("default",
        cidr="10.0.0.0/8",
        vpd_name=name,
        resource_group_id=default.groups[0].id)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/eflo"
    	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/resourcemanager"
    	"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 := "terraform-example"
    		if param := cfg.Get("name"); param != "" {
    			name = param
    		}
    		_default, err := resourcemanager.GetResourceGroups(ctx, &resourcemanager.GetResourceGroupsArgs{}, nil)
    		if err != nil {
    			return err
    		}
    		_, err = eflo.NewVpd(ctx, "default", &eflo.VpdArgs{
    			Cidr:            pulumi.String("10.0.0.0/8"),
    			VpdName:         pulumi.String(name),
    			ResourceGroupId: pulumi.String(_default.Groups[0].Id),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    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") ?? "terraform-example";
        var @default = AliCloud.ResourceManager.GetResourceGroups.Invoke();
    
        var defaultVpd = new AliCloud.Eflo.Vpd("default", new()
        {
            Cidr = "10.0.0.0/8",
            VpdName = name,
            ResourceGroupId = @default.Apply(@default => @default.Apply(getResourceGroupsResult => getResourceGroupsResult.Groups[0]?.Id)),
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.alicloud.resourcemanager.ResourcemanagerFunctions;
    import com.pulumi.alicloud.resourcemanager.inputs.GetResourceGroupsArgs;
    import com.pulumi.alicloud.eflo.Vpd;
    import com.pulumi.alicloud.eflo.VpdArgs;
    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("terraform-example");
            final var default = ResourcemanagerFunctions.getResourceGroups(GetResourceGroupsArgs.builder()
                .build());
    
            var defaultVpd = new Vpd("defaultVpd", VpdArgs.builder()
                .cidr("10.0.0.0/8")
                .vpdName(name)
                .resourceGroupId(default_.groups()[0].id())
                .build());
    
        }
    }
    
    configuration:
      name:
        type: string
        default: terraform-example
    resources:
      defaultVpd:
        type: alicloud:eflo:Vpd
        name: default
        properties:
          cidr: 10.0.0.0/8
          vpdName: ${name}
          resourceGroupId: ${default.groups[0].id}
    variables:
      default:
        fn::invoke:
          function: alicloud:resourcemanager:getResourceGroups
          arguments: {}
    

    Create Vpd Resource

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

    Constructor syntax

    new Vpd(name: string, args: VpdArgs, opts?: CustomResourceOptions);
    @overload
    def Vpd(resource_name: str,
            args: VpdArgs,
            opts: Optional[ResourceOptions] = None)
    
    @overload
    def Vpd(resource_name: str,
            opts: Optional[ResourceOptions] = None,
            cidr: Optional[str] = None,
            vpd_name: Optional[str] = None,
            resource_group_id: Optional[str] = None,
            secondary_cidr_blocks: Optional[Sequence[str]] = None,
            tags: Optional[Mapping[str, str]] = None)
    func NewVpd(ctx *Context, name string, args VpdArgs, opts ...ResourceOption) (*Vpd, error)
    public Vpd(string name, VpdArgs args, CustomResourceOptions? opts = null)
    public Vpd(String name, VpdArgs args)
    public Vpd(String name, VpdArgs args, CustomResourceOptions options)
    
    type: alicloud:eflo:Vpd
    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 VpdArgs
    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 VpdArgs
    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 VpdArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args VpdArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args VpdArgs
    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 vpdResource = new AliCloud.Eflo.Vpd("vpdResource", new()
    {
        Cidr = "string",
        VpdName = "string",
        ResourceGroupId = "string",
        SecondaryCidrBlocks = new[]
        {
            "string",
        },
        Tags = 
        {
            { "string", "string" },
        },
    });
    
    example, err := eflo.NewVpd(ctx, "vpdResource", &eflo.VpdArgs{
    	Cidr:            pulumi.String("string"),
    	VpdName:         pulumi.String("string"),
    	ResourceGroupId: pulumi.String("string"),
    	SecondaryCidrBlocks: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	Tags: pulumi.StringMap{
    		"string": pulumi.String("string"),
    	},
    })
    
    var vpdResource = new Vpd("vpdResource", VpdArgs.builder()
        .cidr("string")
        .vpdName("string")
        .resourceGroupId("string")
        .secondaryCidrBlocks("string")
        .tags(Map.of("string", "string"))
        .build());
    
    vpd_resource = alicloud.eflo.Vpd("vpdResource",
        cidr="string",
        vpd_name="string",
        resource_group_id="string",
        secondary_cidr_blocks=["string"],
        tags={
            "string": "string",
        })
    
    const vpdResource = new alicloud.eflo.Vpd("vpdResource", {
        cidr: "string",
        vpdName: "string",
        resourceGroupId: "string",
        secondaryCidrBlocks: ["string"],
        tags: {
            string: "string",
        },
    });
    
    type: alicloud:eflo:Vpd
    properties:
        cidr: string
        resourceGroupId: string
        secondaryCidrBlocks:
            - string
        tags:
            string: string
        vpdName: string
    

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

    Cidr string
    The CIDR block of the VPD.
    VpdName string
    The name of the VPD instance.
    ResourceGroupId string
    The Resource group ID. NOTE: From version 1.263.0, resource_group_id can be modified.
    SecondaryCidrBlocks List<string>
    The additional CIDR block.
    Tags Dictionary<string, string>
    The tag of the resource.
    Cidr string
    The CIDR block of the VPD.
    VpdName string
    The name of the VPD instance.
    ResourceGroupId string
    The Resource group ID. NOTE: From version 1.263.0, resource_group_id can be modified.
    SecondaryCidrBlocks []string
    The additional CIDR block.
    Tags map[string]string
    The tag of the resource.
    cidr String
    The CIDR block of the VPD.
    vpdName String
    The name of the VPD instance.
    resourceGroupId String
    The Resource group ID. NOTE: From version 1.263.0, resource_group_id can be modified.
    secondaryCidrBlocks List<String>
    The additional CIDR block.
    tags Map<String,String>
    The tag of the resource.
    cidr string
    The CIDR block of the VPD.
    vpdName string
    The name of the VPD instance.
    resourceGroupId string
    The Resource group ID. NOTE: From version 1.263.0, resource_group_id can be modified.
    secondaryCidrBlocks string[]
    The additional CIDR block.
    tags {[key: string]: string}
    The tag of the resource.
    cidr str
    The CIDR block of the VPD.
    vpd_name str
    The name of the VPD instance.
    resource_group_id str
    The Resource group ID. NOTE: From version 1.263.0, resource_group_id can be modified.
    secondary_cidr_blocks Sequence[str]
    The additional CIDR block.
    tags Mapping[str, str]
    The tag of the resource.
    cidr String
    The CIDR block of the VPD.
    vpdName String
    The name of the VPD instance.
    resourceGroupId String
    The Resource group ID. NOTE: From version 1.263.0, resource_group_id can be modified.
    secondaryCidrBlocks List<String>
    The additional CIDR block.
    tags Map<String>
    The tag of the resource.

    Outputs

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

    CreateTime string
    The time when the activation code was created.
    GmtModified string
    The time when the O&M task was modified.
    Id string
    The provider-assigned unique ID for this managed resource.
    RegionId string
    (Available since v1.263.0) The region ID.
    Status string
    The current state of the instance.
    CreateTime string
    The time when the activation code was created.
    GmtModified string
    The time when the O&M task was modified.
    Id string
    The provider-assigned unique ID for this managed resource.
    RegionId string
    (Available since v1.263.0) The region ID.
    Status string
    The current state of the instance.
    createTime String
    The time when the activation code was created.
    gmtModified String
    The time when the O&M task was modified.
    id String
    The provider-assigned unique ID for this managed resource.
    regionId String
    (Available since v1.263.0) The region ID.
    status String
    The current state of the instance.
    createTime string
    The time when the activation code was created.
    gmtModified string
    The time when the O&M task was modified.
    id string
    The provider-assigned unique ID for this managed resource.
    regionId string
    (Available since v1.263.0) The region ID.
    status string
    The current state of the instance.
    create_time str
    The time when the activation code was created.
    gmt_modified str
    The time when the O&M task was modified.
    id str
    The provider-assigned unique ID for this managed resource.
    region_id str
    (Available since v1.263.0) The region ID.
    status str
    The current state of the instance.
    createTime String
    The time when the activation code was created.
    gmtModified String
    The time when the O&M task was modified.
    id String
    The provider-assigned unique ID for this managed resource.
    regionId String
    (Available since v1.263.0) The region ID.
    status String
    The current state of the instance.

    Look up Existing Vpd Resource

    Get an existing Vpd 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?: VpdState, opts?: CustomResourceOptions): Vpd
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            cidr: Optional[str] = None,
            create_time: Optional[str] = None,
            gmt_modified: Optional[str] = None,
            region_id: Optional[str] = None,
            resource_group_id: Optional[str] = None,
            secondary_cidr_blocks: Optional[Sequence[str]] = None,
            status: Optional[str] = None,
            tags: Optional[Mapping[str, str]] = None,
            vpd_name: Optional[str] = None) -> Vpd
    func GetVpd(ctx *Context, name string, id IDInput, state *VpdState, opts ...ResourceOption) (*Vpd, error)
    public static Vpd Get(string name, Input<string> id, VpdState? state, CustomResourceOptions? opts = null)
    public static Vpd get(String name, Output<String> id, VpdState state, CustomResourceOptions options)
    resources:  _:    type: alicloud:eflo:Vpd    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.
    The following state arguments are supported:
    Cidr string
    The CIDR block of the VPD.
    CreateTime string
    The time when the activation code was created.
    GmtModified string
    The time when the O&M task was modified.
    RegionId string
    (Available since v1.263.0) The region ID.
    ResourceGroupId string
    The Resource group ID. NOTE: From version 1.263.0, resource_group_id can be modified.
    SecondaryCidrBlocks List<string>
    The additional CIDR block.
    Status string
    The current state of the instance.
    Tags Dictionary<string, string>
    The tag of the resource.
    VpdName string
    The name of the VPD instance.
    Cidr string
    The CIDR block of the VPD.
    CreateTime string
    The time when the activation code was created.
    GmtModified string
    The time when the O&M task was modified.
    RegionId string
    (Available since v1.263.0) The region ID.
    ResourceGroupId string
    The Resource group ID. NOTE: From version 1.263.0, resource_group_id can be modified.
    SecondaryCidrBlocks []string
    The additional CIDR block.
    Status string
    The current state of the instance.
    Tags map[string]string
    The tag of the resource.
    VpdName string
    The name of the VPD instance.
    cidr String
    The CIDR block of the VPD.
    createTime String
    The time when the activation code was created.
    gmtModified String
    The time when the O&M task was modified.
    regionId String
    (Available since v1.263.0) The region ID.
    resourceGroupId String
    The Resource group ID. NOTE: From version 1.263.0, resource_group_id can be modified.
    secondaryCidrBlocks List<String>
    The additional CIDR block.
    status String
    The current state of the instance.
    tags Map<String,String>
    The tag of the resource.
    vpdName String
    The name of the VPD instance.
    cidr string
    The CIDR block of the VPD.
    createTime string
    The time when the activation code was created.
    gmtModified string
    The time when the O&M task was modified.
    regionId string
    (Available since v1.263.0) The region ID.
    resourceGroupId string
    The Resource group ID. NOTE: From version 1.263.0, resource_group_id can be modified.
    secondaryCidrBlocks string[]
    The additional CIDR block.
    status string
    The current state of the instance.
    tags {[key: string]: string}
    The tag of the resource.
    vpdName string
    The name of the VPD instance.
    cidr str
    The CIDR block of the VPD.
    create_time str
    The time when the activation code was created.
    gmt_modified str
    The time when the O&M task was modified.
    region_id str
    (Available since v1.263.0) The region ID.
    resource_group_id str
    The Resource group ID. NOTE: From version 1.263.0, resource_group_id can be modified.
    secondary_cidr_blocks Sequence[str]
    The additional CIDR block.
    status str
    The current state of the instance.
    tags Mapping[str, str]
    The tag of the resource.
    vpd_name str
    The name of the VPD instance.
    cidr String
    The CIDR block of the VPD.
    createTime String
    The time when the activation code was created.
    gmtModified String
    The time when the O&M task was modified.
    regionId String
    (Available since v1.263.0) The region ID.
    resourceGroupId String
    The Resource group ID. NOTE: From version 1.263.0, resource_group_id can be modified.
    secondaryCidrBlocks List<String>
    The additional CIDR block.
    status String
    The current state of the instance.
    tags Map<String>
    The tag of the resource.
    vpdName String
    The name of the VPD instance.

    Import

    Eflo Vpd can be imported using the id, e.g.

    $ pulumi import alicloud:eflo/vpd:Vpd example <id>
    

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

    Package Details

    Repository
    Alibaba Cloud pulumi/pulumi-alicloud
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the alicloud Terraform Provider.
    alicloud logo
    Alibaba Cloud v3.90.0 published on Tuesday, Dec 2, 2025 by Pulumi
      Meet Neo: Your AI Platform Teammate