Volcengine v0.0.38 published on Friday, Oct 31, 2025 by Volcengine
Volcengine v0.0.38 published on Friday, Oct 31, 2025 by Volcengine
Use this data source to query detailed information of vedb mysql allowlists
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as volcengine from "@pulumi/volcengine";
import * as volcengine from "@volcengine/pulumi";
const fooAllowlist = new volcengine.vedb_mysql.Allowlist("fooAllowlist", {
allowListName: "acc-test-allowlist",
allowListDesc: "acc-test",
allowListType: "IPv4",
allowLists: [
"192.168.0.0/24",
"192.168.1.0/24",
"192.168.2.0/24",
],
});
const fooZones = volcengine.ecs.getZones({});
const fooVpc = new volcengine.vpc.Vpc("fooVpc", {
vpcName: "acc-test-vpc",
cidrBlock: "172.16.0.0/16",
});
const fooSubnet = new volcengine.vpc.Subnet("fooSubnet", {
subnetName: "acc-test-subnet",
cidrBlock: "172.16.0.0/24",
zoneId: fooZones.then(fooZones => fooZones.zones?.[2]?.id),
vpcId: fooVpc.id,
});
const fooInstance = new volcengine.vedb_mysql.Instance("fooInstance", {
chargeType: "PostPaid",
storageChargeType: "PostPaid",
dbEngineVersion: "MySQL_8_0",
dbMinorVersion: "3.0",
nodeNumber: 2,
nodeSpec: "vedb.mysql.x4.large",
subnetId: fooSubnet.id,
instanceName: "tf-test",
projectName: "testA",
tags: [
{
key: "tftest",
value: "tftest",
},
{
key: "tftest2",
value: "tftest2",
},
],
});
const fooAllowlistAssociate = new volcengine.vedb_mysql.AllowlistAssociate("fooAllowlistAssociate", {
allowListId: fooAllowlist.id,
instanceId: fooInstance.id,
});
const fooAllowlists = volcengine.vedb_mysql.getAllowlistsOutput({
instanceId: fooInstance.id,
});
import pulumi
import pulumi_volcengine as volcengine
foo_allowlist = volcengine.vedb_mysql.Allowlist("fooAllowlist",
allow_list_name="acc-test-allowlist",
allow_list_desc="acc-test",
allow_list_type="IPv4",
allow_lists=[
"192.168.0.0/24",
"192.168.1.0/24",
"192.168.2.0/24",
])
foo_zones = volcengine.ecs.get_zones()
foo_vpc = volcengine.vpc.Vpc("fooVpc",
vpc_name="acc-test-vpc",
cidr_block="172.16.0.0/16")
foo_subnet = volcengine.vpc.Subnet("fooSubnet",
subnet_name="acc-test-subnet",
cidr_block="172.16.0.0/24",
zone_id=foo_zones.zones[2].id,
vpc_id=foo_vpc.id)
foo_instance = volcengine.vedb_mysql.Instance("fooInstance",
charge_type="PostPaid",
storage_charge_type="PostPaid",
db_engine_version="MySQL_8_0",
db_minor_version="3.0",
node_number=2,
node_spec="vedb.mysql.x4.large",
subnet_id=foo_subnet.id,
instance_name="tf-test",
project_name="testA",
tags=[
volcengine.vedb_mysql.InstanceTagArgs(
key="tftest",
value="tftest",
),
volcengine.vedb_mysql.InstanceTagArgs(
key="tftest2",
value="tftest2",
),
])
foo_allowlist_associate = volcengine.vedb_mysql.AllowlistAssociate("fooAllowlistAssociate",
allow_list_id=foo_allowlist.id,
instance_id=foo_instance.id)
foo_allowlists = volcengine.vedb_mysql.get_allowlists_output(instance_id=foo_instance.id)
package main
import (
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/volcengine/pulumi-volcengine/sdk/go/volcengine/ecs"
"github.com/volcengine/pulumi-volcengine/sdk/go/volcengine/vedb_mysql"
"github.com/volcengine/pulumi-volcengine/sdk/go/volcengine/vpc"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
fooAllowlist, err := vedb_mysql.NewAllowlist(ctx, "fooAllowlist", &vedb_mysql.AllowlistArgs{
AllowListName: pulumi.String("acc-test-allowlist"),
AllowListDesc: pulumi.String("acc-test"),
AllowListType: pulumi.String("IPv4"),
AllowLists: pulumi.StringArray{
pulumi.String("192.168.0.0/24"),
pulumi.String("192.168.1.0/24"),
pulumi.String("192.168.2.0/24"),
},
})
if err != nil {
return err
}
fooZones, err := ecs.GetZones(ctx, nil, nil)
if err != nil {
return err
}
fooVpc, err := vpc.NewVpc(ctx, "fooVpc", &vpc.VpcArgs{
VpcName: pulumi.String("acc-test-vpc"),
CidrBlock: pulumi.String("172.16.0.0/16"),
})
if err != nil {
return err
}
fooSubnet, err := vpc.NewSubnet(ctx, "fooSubnet", &vpc.SubnetArgs{
SubnetName: pulumi.String("acc-test-subnet"),
CidrBlock: pulumi.String("172.16.0.0/24"),
ZoneId: pulumi.String(fooZones.Zones[2].Id),
VpcId: fooVpc.ID(),
})
if err != nil {
return err
}
fooInstance, err := vedb_mysql.NewInstance(ctx, "fooInstance", &vedb_mysql.InstanceArgs{
ChargeType: pulumi.String("PostPaid"),
StorageChargeType: pulumi.String("PostPaid"),
DbEngineVersion: pulumi.String("MySQL_8_0"),
DbMinorVersion: pulumi.String("3.0"),
NodeNumber: pulumi.Int(2),
NodeSpec: pulumi.String("vedb.mysql.x4.large"),
SubnetId: fooSubnet.ID(),
InstanceName: pulumi.String("tf-test"),
ProjectName: pulumi.String("testA"),
Tags: vedb_mysql.InstanceTagArray{
&vedb_mysql.InstanceTagArgs{
Key: pulumi.String("tftest"),
Value: pulumi.String("tftest"),
},
&vedb_mysql.InstanceTagArgs{
Key: pulumi.String("tftest2"),
Value: pulumi.String("tftest2"),
},
},
})
if err != nil {
return err
}
_, err = vedb_mysql.NewAllowlistAssociate(ctx, "fooAllowlistAssociate", &vedb_mysql.AllowlistAssociateArgs{
AllowListId: fooAllowlist.ID(),
InstanceId: fooInstance.ID(),
})
if err != nil {
return err
}
_ = vedb_mysql.GetAllowlistsOutput(ctx, vedb_mysql.GetAllowlistsOutputArgs{
InstanceId: fooInstance.ID(),
}, nil)
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Volcengine = Pulumi.Volcengine;
return await Deployment.RunAsync(() =>
{
var fooAllowlist = new Volcengine.Vedb_mysql.Allowlist("fooAllowlist", new()
{
AllowListName = "acc-test-allowlist",
AllowListDesc = "acc-test",
AllowListType = "IPv4",
AllowLists = new[]
{
"192.168.0.0/24",
"192.168.1.0/24",
"192.168.2.0/24",
},
});
var fooZones = Volcengine.Ecs.GetZones.Invoke();
var fooVpc = new Volcengine.Vpc.Vpc("fooVpc", new()
{
VpcName = "acc-test-vpc",
CidrBlock = "172.16.0.0/16",
});
var fooSubnet = new Volcengine.Vpc.Subnet("fooSubnet", new()
{
SubnetName = "acc-test-subnet",
CidrBlock = "172.16.0.0/24",
ZoneId = fooZones.Apply(getZonesResult => getZonesResult.Zones[2]?.Id),
VpcId = fooVpc.Id,
});
var fooInstance = new Volcengine.Vedb_mysql.Instance("fooInstance", new()
{
ChargeType = "PostPaid",
StorageChargeType = "PostPaid",
DbEngineVersion = "MySQL_8_0",
DbMinorVersion = "3.0",
NodeNumber = 2,
NodeSpec = "vedb.mysql.x4.large",
SubnetId = fooSubnet.Id,
InstanceName = "tf-test",
ProjectName = "testA",
Tags = new[]
{
new Volcengine.Vedb_mysql.Inputs.InstanceTagArgs
{
Key = "tftest",
Value = "tftest",
},
new Volcengine.Vedb_mysql.Inputs.InstanceTagArgs
{
Key = "tftest2",
Value = "tftest2",
},
},
});
var fooAllowlistAssociate = new Volcengine.Vedb_mysql.AllowlistAssociate("fooAllowlistAssociate", new()
{
AllowListId = fooAllowlist.Id,
InstanceId = fooInstance.Id,
});
var fooAllowlists = Volcengine.Vedb_mysql.GetAllowlists.Invoke(new()
{
InstanceId = fooInstance.Id,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.volcengine.vedb_mysql.Allowlist;
import com.pulumi.volcengine.vedb_mysql.AllowlistArgs;
import com.pulumi.volcengine.ecs.EcsFunctions;
import com.pulumi.volcengine.ecs.inputs.GetZonesArgs;
import com.pulumi.volcengine.vpc.Vpc;
import com.pulumi.volcengine.vpc.VpcArgs;
import com.pulumi.volcengine.vpc.Subnet;
import com.pulumi.volcengine.vpc.SubnetArgs;
import com.pulumi.volcengine.vedb_mysql.Instance;
import com.pulumi.volcengine.vedb_mysql.InstanceArgs;
import com.pulumi.volcengine.vedb_mysql.inputs.InstanceTagArgs;
import com.pulumi.volcengine.vedb_mysql.AllowlistAssociate;
import com.pulumi.volcengine.vedb_mysql.AllowlistAssociateArgs;
import com.pulumi.volcengine.vedb_mysql.Vedb_mysqlFunctions;
import com.pulumi.volcengine.vedb_mysql.inputs.GetAllowlistsArgs;
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 fooAllowlist = new Allowlist("fooAllowlist", AllowlistArgs.builder()
.allowListName("acc-test-allowlist")
.allowListDesc("acc-test")
.allowListType("IPv4")
.allowLists(
"192.168.0.0/24",
"192.168.1.0/24",
"192.168.2.0/24")
.build());
final var fooZones = EcsFunctions.getZones();
var fooVpc = new Vpc("fooVpc", VpcArgs.builder()
.vpcName("acc-test-vpc")
.cidrBlock("172.16.0.0/16")
.build());
var fooSubnet = new Subnet("fooSubnet", SubnetArgs.builder()
.subnetName("acc-test-subnet")
.cidrBlock("172.16.0.0/24")
.zoneId(fooZones.applyValue(getZonesResult -> getZonesResult.zones()[2].id()))
.vpcId(fooVpc.id())
.build());
var fooInstance = new Instance("fooInstance", InstanceArgs.builder()
.chargeType("PostPaid")
.storageChargeType("PostPaid")
.dbEngineVersion("MySQL_8_0")
.dbMinorVersion("3.0")
.nodeNumber(2)
.nodeSpec("vedb.mysql.x4.large")
.subnetId(fooSubnet.id())
.instanceName("tf-test")
.projectName("testA")
.tags(
InstanceTagArgs.builder()
.key("tftest")
.value("tftest")
.build(),
InstanceTagArgs.builder()
.key("tftest2")
.value("tftest2")
.build())
.build());
var fooAllowlistAssociate = new AllowlistAssociate("fooAllowlistAssociate", AllowlistAssociateArgs.builder()
.allowListId(fooAllowlist.id())
.instanceId(fooInstance.id())
.build());
final var fooAllowlists = Vedb_mysqlFunctions.getAllowlists(GetAllowlistsArgs.builder()
.instanceId(fooInstance.id())
.build());
}
}
resources:
fooAllowlist:
type: volcengine:vedb_mysql:Allowlist
properties:
allowListName: acc-test-allowlist
allowListDesc: acc-test
allowListType: IPv4
allowLists:
- 192.168.0.0/24
- 192.168.1.0/24
- 192.168.2.0/24
fooVpc:
type: volcengine:vpc:Vpc
properties:
vpcName: acc-test-vpc
cidrBlock: 172.16.0.0/16
fooSubnet:
type: volcengine:vpc:Subnet
properties:
subnetName: acc-test-subnet
cidrBlock: 172.16.0.0/24
zoneId: ${fooZones.zones[2].id}
vpcId: ${fooVpc.id}
fooInstance:
type: volcengine:vedb_mysql:Instance
properties:
chargeType: PostPaid
storageChargeType: PostPaid
dbEngineVersion: MySQL_8_0
dbMinorVersion: '3.0'
nodeNumber: 2
nodeSpec: vedb.mysql.x4.large
subnetId: ${fooSubnet.id}
instanceName: tf-test
projectName: testA
tags:
- key: tftest
value: tftest
- key: tftest2
value: tftest2
fooAllowlistAssociate:
type: volcengine:vedb_mysql:AllowlistAssociate
properties:
allowListId: ${fooAllowlist.id}
instanceId: ${fooInstance.id}
variables:
fooZones:
fn::invoke:
Function: volcengine:ecs:getZones
Arguments: {}
fooAllowlists:
fn::invoke:
Function: volcengine:vedb_mysql:getAllowlists
Arguments:
instanceId: ${fooInstance.id}
Using getAllowlists
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 getAllowlists(args: GetAllowlistsArgs, opts?: InvokeOptions): Promise<GetAllowlistsResult>
function getAllowlistsOutput(args: GetAllowlistsOutputArgs, opts?: InvokeOptions): Output<GetAllowlistsResult>def get_allowlists(instance_id: Optional[str] = None,
name_regex: Optional[str] = None,
output_file: Optional[str] = None,
region_id: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetAllowlistsResult
def get_allowlists_output(instance_id: Optional[pulumi.Input[str]] = None,
name_regex: Optional[pulumi.Input[str]] = None,
output_file: Optional[pulumi.Input[str]] = None,
region_id: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetAllowlistsResult]func GetAllowlists(ctx *Context, args *GetAllowlistsArgs, opts ...InvokeOption) (*GetAllowlistsResult, error)
func GetAllowlistsOutput(ctx *Context, args *GetAllowlistsOutputArgs, opts ...InvokeOption) GetAllowlistsResultOutput> Note: This function is named GetAllowlists in the Go SDK.
public static class GetAllowlists
{
public static Task<GetAllowlistsResult> InvokeAsync(GetAllowlistsArgs args, InvokeOptions? opts = null)
public static Output<GetAllowlistsResult> Invoke(GetAllowlistsInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetAllowlistsResult> getAllowlists(GetAllowlistsArgs args, InvokeOptions options)
public static Output<GetAllowlistsResult> getAllowlists(GetAllowlistsArgs args, InvokeOptions options)
fn::invoke:
function: volcengine:vedb_mysql/getAllowlists:getAllowlists
arguments:
# arguments dictionaryThe following arguments are supported:
- Region
Id string - The region of the allow lists.
- Instance
Id string - Instance ID. When an InstanceId is specified, the DescribeAllowLists interface will return the whitelist bound to the specified instance.
- Name
Regex string - A Name Regex of Resource.
- Output
File string - File name where to save data source results.
- Region
Id string - The region of the allow lists.
- Instance
Id string - Instance ID. When an InstanceId is specified, the DescribeAllowLists interface will return the whitelist bound to the specified instance.
- Name
Regex string - A Name Regex of Resource.
- Output
File string - File name where to save data source results.
- region
Id String - The region of the allow lists.
- instance
Id String - Instance ID. When an InstanceId is specified, the DescribeAllowLists interface will return the whitelist bound to the specified instance.
- name
Regex String - A Name Regex of Resource.
- output
File String - File name where to save data source results.
- region
Id string - The region of the allow lists.
- instance
Id string - Instance ID. When an InstanceId is specified, the DescribeAllowLists interface will return the whitelist bound to the specified instance.
- name
Regex string - A Name Regex of Resource.
- output
File string - File name where to save data source results.
- region_
id str - The region of the allow lists.
- instance_
id str - Instance ID. When an InstanceId is specified, the DescribeAllowLists interface will return the whitelist bound to the specified instance.
- name_
regex str - A Name Regex of Resource.
- output_
file str - File name where to save data source results.
- region
Id String - The region of the allow lists.
- instance
Id String - Instance ID. When an InstanceId is specified, the DescribeAllowLists interface will return the whitelist bound to the specified instance.
- name
Regex String - A Name Regex of Resource.
- output
File String - File name where to save data source results.
getAllowlists Result
The following output properties are available:
- Allow
Lists List<GetAllowlists Allow List> - The collection of query.
- Id string
- The provider-assigned unique ID for this managed resource.
- Region
Id string - Total
Count int - The total count of query.
- Instance
Id string - The id of the instance.
- Name
Regex string - Output
File string
- Allow
Lists []GetAllowlists Allow List - The collection of query.
- Id string
- The provider-assigned unique ID for this managed resource.
- Region
Id string - Total
Count int - The total count of query.
- Instance
Id string - The id of the instance.
- Name
Regex string - Output
File string
- allow
Lists List<GetAllowlists Allow List> - The collection of query.
- id String
- The provider-assigned unique ID for this managed resource.
- region
Id String - total
Count Integer - The total count of query.
- instance
Id String - The id of the instance.
- name
Regex String - output
File String
- allow
Lists GetAllowlists Allow List[] - The collection of query.
- id string
- The provider-assigned unique ID for this managed resource.
- region
Id string - total
Count number - The total count of query.
- instance
Id string - The id of the instance.
- name
Regex string - output
File string
- allow_
lists Sequence[GetAllowlists Allow List] - The collection of query.
- id str
- The provider-assigned unique ID for this managed resource.
- region_
id str - total_
count int - The total count of query.
- instance_
id str - The id of the instance.
- name_
regex str - output_
file str
- allow
Lists List<Property Map> - The collection of query.
- id String
- The provider-assigned unique ID for this managed resource.
- region
Id String - total
Count Number - The total count of query.
- instance
Id String - The id of the instance.
- name
Regex String - output
File String
Supporting Types
GetAllowlistsAllowList
- Allow
List stringDesc - The description of the allow list.
- Allow
List stringId - The id of the allow list.
- Allow
List intIp Num - The total number of IP addresses (or address ranges) in the whitelist.
- Allow
List stringName - The name of the allow list.
- Allow
List stringType - The type of the allow list.
- Allow
Lists List<string> - The IP address or a range of IP addresses in CIDR format.
- Associated
Instance intNum - The total number of instances bound under the whitelist.
- Associated
Instances List<GetAllowlists Allow List Associated Instance> - The list of instances.
- Allow
List stringDesc - The description of the allow list.
- Allow
List stringId - The id of the allow list.
- Allow
List intIp Num - The total number of IP addresses (or address ranges) in the whitelist.
- Allow
List stringName - The name of the allow list.
- Allow
List stringType - The type of the allow list.
- Allow
Lists []string - The IP address or a range of IP addresses in CIDR format.
- Associated
Instance intNum - The total number of instances bound under the whitelist.
- Associated
Instances []GetAllowlists Allow List Associated Instance - The list of instances.
- allow
List StringDesc - The description of the allow list.
- allow
List StringId - The id of the allow list.
- allow
List IntegerIp Num - The total number of IP addresses (or address ranges) in the whitelist.
- allow
List StringName - The name of the allow list.
- allow
List StringType - The type of the allow list.
- allow
Lists List<String> - The IP address or a range of IP addresses in CIDR format.
- associated
Instance IntegerNum - The total number of instances bound under the whitelist.
- associated
Instances List<GetAllowlists Allow List Associated Instance> - The list of instances.
- allow
List stringDesc - The description of the allow list.
- allow
List stringId - The id of the allow list.
- allow
List numberIp Num - The total number of IP addresses (or address ranges) in the whitelist.
- allow
List stringName - The name of the allow list.
- allow
List stringType - The type of the allow list.
- allow
Lists string[] - The IP address or a range of IP addresses in CIDR format.
- associated
Instance numberNum - The total number of instances bound under the whitelist.
- associated
Instances GetAllowlists Allow List Associated Instance[] - The list of instances.
- allow_
list_ strdesc - The description of the allow list.
- allow_
list_ strid - The id of the allow list.
- allow_
list_ intip_ num - The total number of IP addresses (or address ranges) in the whitelist.
- allow_
list_ strname - The name of the allow list.
- allow_
list_ strtype - The type of the allow list.
- allow_
lists Sequence[str] - The IP address or a range of IP addresses in CIDR format.
- associated_
instance_ intnum - The total number of instances bound under the whitelist.
- associated_
instances Sequence[GetAllowlists Allow List Associated Instance] - The list of instances.
- allow
List StringDesc - The description of the allow list.
- allow
List StringId - The id of the allow list.
- allow
List NumberIp Num - The total number of IP addresses (or address ranges) in the whitelist.
- allow
List StringName - The name of the allow list.
- allow
List StringType - The type of the allow list.
- allow
Lists List<String> - The IP address or a range of IP addresses in CIDR format.
- associated
Instance NumberNum - The total number of instances bound under the whitelist.
- associated
Instances List<Property Map> - The list of instances.
GetAllowlistsAllowListAssociatedInstance
- Instance
Id string - Instance ID. When an InstanceId is specified, the DescribeAllowLists interface will return the whitelist bound to the specified instance.
- Instance
Name string - The name of the instance.
- Vpc string
- The id of the vpc.
- Instance
Id string - Instance ID. When an InstanceId is specified, the DescribeAllowLists interface will return the whitelist bound to the specified instance.
- Instance
Name string - The name of the instance.
- Vpc string
- The id of the vpc.
- instance
Id String - Instance ID. When an InstanceId is specified, the DescribeAllowLists interface will return the whitelist bound to the specified instance.
- instance
Name String - The name of the instance.
- vpc String
- The id of the vpc.
- instance
Id string - Instance ID. When an InstanceId is specified, the DescribeAllowLists interface will return the whitelist bound to the specified instance.
- instance
Name string - The name of the instance.
- vpc string
- The id of the vpc.
- instance_
id str - Instance ID. When an InstanceId is specified, the DescribeAllowLists interface will return the whitelist bound to the specified instance.
- instance_
name str - The name of the instance.
- vpc str
- The id of the vpc.
- instance
Id String - Instance ID. When an InstanceId is specified, the DescribeAllowLists interface will return the whitelist bound to the specified instance.
- instance
Name String - The name of the instance.
- vpc String
- The id of the vpc.
Package Details
- Repository
- volcengine volcengine/pulumi-volcengine
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
volcengineTerraform Provider.
Volcengine v0.0.38 published on Friday, Oct 31, 2025 by Volcengine
