published on Thursday, Apr 23, 2026 by Volcengine
published on Thursday, Apr 23, 2026 by Volcengine
When creating a Kafka instance, you can bind an allowlist as needed. After binding the allowlist to the Kafka instance, only IP addresses and address ranges specified in the allowlist can access the Kafka message queue instance. For security, we recommend creating an allowlist and adding the client IP address or IP address range to the Kafka instance’s allowlist. Regularly maintain and manage the allowlist to enhance the security of Kafka instance access
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as volcenginecc from "@pulumi/volcenginecc";
const kafkaAllowListDemo = new volcenginecc.index.KafkaAllowlist("KafkaAllowListDemo", {
allowList: "127.0.0.2",
allowListDesc: "test",
allowListName: "ccapi-text",
associatedInstances: [
{
instanceId: "kafka-cnng9x9s***",
},
{
instanceId: "kafka-cnnghf99**",
},
],
applyInstanceNum: 2,
});
import pulumi
import pulumi_volcenginecc as volcenginecc
kafka_allow_list_demo = volcenginecc.index.KafkaAllowlist("KafkaAllowListDemo",
allow_list=127.0.0.2,
allow_list_desc=test,
allow_list_name=ccapi-text,
associated_instances=[
{
instanceId: kafka-cnng9x9s***,
},
{
instanceId: kafka-cnnghf99**,
},
],
apply_instance_num=2)
package main
import (
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/volcengine/pulumi-volcenginecc/sdk/go/volcenginecc"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := volcenginecc.NewKafkaAllowlist(ctx, "KafkaAllowListDemo", &volcenginecc.KafkaAllowlistArgs{
AllowList: "127.0.0.2",
AllowListDesc: "test",
AllowListName: "ccapi-text",
AssociatedInstances: []map[string]interface{}{
map[string]interface{}{
"instanceId": "kafka-cnng9x9s***",
},
map[string]interface{}{
"instanceId": "kafka-cnnghf99**",
},
},
ApplyInstanceNum: 2,
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Volcenginecc = Pulumi.Volcenginecc;
return await Deployment.RunAsync(() =>
{
var kafkaAllowListDemo = new Volcenginecc.Index.KafkaAllowlist("KafkaAllowListDemo", new()
{
AllowList = "127.0.0.2",
AllowListDesc = "test",
AllowListName = "ccapi-text",
AssociatedInstances = new[]
{
{
{ "instanceId", "kafka-cnng9x9s***" },
},
{
{ "instanceId", "kafka-cnnghf99**" },
},
},
ApplyInstanceNum = 2,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.volcenginecc.kafkaAllowlist;
import com.pulumi.volcenginecc.kafkaAllowlistArgs;
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 kafkaAllowListDemo = new KafkaAllowlist("kafkaAllowListDemo", KafkaAllowlistArgs.builder()
.allowList("127.0.0.2")
.allowListDesc("test")
.allowListName("ccapi-text")
.associatedInstances(List.of(
Map.of("instanceId", "kafka-cnng9x9s***"),
Map.of("instanceId", "kafka-cnnghf99**")))
.applyInstanceNum(2)
.build());
}
}
resources:
kafkaAllowListDemo:
type: volcenginecc:kafkaAllowlist
name: KafkaAllowListDemo
properties:
allowList: 127.0.0.2
allowListDesc: test
allowListName: ccapi-text
associatedInstances:
- instanceId: kafka-cnng9x9s***
- instanceId: kafka-cnnghf99**
applyInstanceNum: 2
Create AllowList Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new AllowList(name: string, args: AllowListArgs, opts?: CustomResourceOptions);@overload
def AllowList(resource_name: str,
args: AllowListArgs,
opts: Optional[ResourceOptions] = None)
@overload
def AllowList(resource_name: str,
opts: Optional[ResourceOptions] = None,
allow_list: Optional[str] = None,
allow_list_name: Optional[str] = None,
allow_list_desc: Optional[str] = None,
apply_instance_num: Optional[int] = None,
associated_instances: Optional[Sequence[AllowListAssociatedInstanceArgs]] = None)func NewAllowList(ctx *Context, name string, args AllowListArgs, opts ...ResourceOption) (*AllowList, error)public AllowList(string name, AllowListArgs args, CustomResourceOptions? opts = null)
public AllowList(String name, AllowListArgs args)
public AllowList(String name, AllowListArgs args, CustomResourceOptions options)
type: volcenginecc:kafka:AllowList
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 AllowListArgs
- 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 AllowListArgs
- 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 AllowListArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args AllowListArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args AllowListArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
AllowList 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 AllowList resource accepts the following input properties:
- Allow
List stringName - Allowlist rule name. Length: 1–128 characters. Can only contain Chinese characters, letters, numbers, underscores, and hyphens (-). Cannot start with a number or hyphen (-). The allowlist name must be unique within the current region
- Allow
List stringValue - Allowlist rule list. Supports specifying IP addresses or IP ranges. Separate multiple IP addresses or ranges with commas (,). Each allowlist can contain up to 300 IP addresses or ranges
- Allow
List stringDesc - Allowlist description. Maximum length: 200 characters
- Apply
Instance intNum - Number of instances already bound to this allowlist. If the AllowList parameter is specified, this field is required to indicate the expected number of instances affected after rule modification. If the expected number does not match the actual number, the request fails
- Associated
Instances List<Volcengine.Allow List Associated Instance>
- Allow
List string - Allowlist rule list. Supports specifying IP addresses or IP ranges. Separate multiple IP addresses or ranges with commas (,). Each allowlist can contain up to 300 IP addresses or ranges
- Allow
List stringName - Allowlist rule name. Length: 1–128 characters. Can only contain Chinese characters, letters, numbers, underscores, and hyphens (-). Cannot start with a number or hyphen (-). The allowlist name must be unique within the current region
- Allow
List stringDesc - Allowlist description. Maximum length: 200 characters
- Apply
Instance intNum - Number of instances already bound to this allowlist. If the AllowList parameter is specified, this field is required to indicate the expected number of instances affected after rule modification. If the expected number does not match the actual number, the request fails
- Associated
Instances []AllowList Associated Instance Args
- allow
List String - Allowlist rule list. Supports specifying IP addresses or IP ranges. Separate multiple IP addresses or ranges with commas (,). Each allowlist can contain up to 300 IP addresses or ranges
- allow
List StringName - Allowlist rule name. Length: 1–128 characters. Can only contain Chinese characters, letters, numbers, underscores, and hyphens (-). Cannot start with a number or hyphen (-). The allowlist name must be unique within the current region
- allow
List StringDesc - Allowlist description. Maximum length: 200 characters
- apply
Instance IntegerNum - Number of instances already bound to this allowlist. If the AllowList parameter is specified, this field is required to indicate the expected number of instances affected after rule modification. If the expected number does not match the actual number, the request fails
- associated
Instances List<AllowList Associated Instance>
- allow
List string - Allowlist rule list. Supports specifying IP addresses or IP ranges. Separate multiple IP addresses or ranges with commas (,). Each allowlist can contain up to 300 IP addresses or ranges
- allow
List stringName - Allowlist rule name. Length: 1–128 characters. Can only contain Chinese characters, letters, numbers, underscores, and hyphens (-). Cannot start with a number or hyphen (-). The allowlist name must be unique within the current region
- allow
List stringDesc - Allowlist description. Maximum length: 200 characters
- apply
Instance numberNum - Number of instances already bound to this allowlist. If the AllowList parameter is specified, this field is required to indicate the expected number of instances affected after rule modification. If the expected number does not match the actual number, the request fails
- associated
Instances AllowList Associated Instance[]
- allow_
list str - Allowlist rule list. Supports specifying IP addresses or IP ranges. Separate multiple IP addresses or ranges with commas (,). Each allowlist can contain up to 300 IP addresses or ranges
- allow_
list_ strname - Allowlist rule name. Length: 1–128 characters. Can only contain Chinese characters, letters, numbers, underscores, and hyphens (-). Cannot start with a number or hyphen (-). The allowlist name must be unique within the current region
- allow_
list_ strdesc - Allowlist description. Maximum length: 200 characters
- apply_
instance_ intnum - Number of instances already bound to this allowlist. If the AllowList parameter is specified, this field is required to indicate the expected number of instances affected after rule modification. If the expected number does not match the actual number, the request fails
- associated_
instances Sequence[AllowList Associated Instance Args]
- allow
List String - Allowlist rule list. Supports specifying IP addresses or IP ranges. Separate multiple IP addresses or ranges with commas (,). Each allowlist can contain up to 300 IP addresses or ranges
- allow
List StringName - Allowlist rule name. Length: 1–128 characters. Can only contain Chinese characters, letters, numbers, underscores, and hyphens (-). Cannot start with a number or hyphen (-). The allowlist name must be unique within the current region
- allow
List StringDesc - Allowlist description. Maximum length: 200 characters
- apply
Instance NumberNum - Number of instances already bound to this allowlist. If the AllowList parameter is specified, this field is required to indicate the expected number of instances affected after rule modification. If the expected number does not match the actual number, the request fails
- associated
Instances List<Property Map>
Outputs
All input properties are implicitly available as output properties. Additionally, the AllowList resource produces the following output properties:
- Allow
List stringId - Allowlist ID
- Allow
List intIp Num - Number of rules specified in the allowlist
- Associated
Instance intNum - Number of instances bound to the allowlist
- Id string
- The provider-assigned unique ID for this managed resource.
- Allow
List stringId - Allowlist ID
- Allow
List intIp Num - Number of rules specified in the allowlist
- Associated
Instance intNum - Number of instances bound to the allowlist
- Id string
- The provider-assigned unique ID for this managed resource.
- allow
List StringId - Allowlist ID
- allow
List IntegerIp Num - Number of rules specified in the allowlist
- associated
Instance IntegerNum - Number of instances bound to the allowlist
- id String
- The provider-assigned unique ID for this managed resource.
- allow
List stringId - Allowlist ID
- allow
List numberIp Num - Number of rules specified in the allowlist
- associated
Instance numberNum - Number of instances bound to the allowlist
- id string
- The provider-assigned unique ID for this managed resource.
- allow_
list_ strid - Allowlist ID
- allow_
list_ intip_ num - Number of rules specified in the allowlist
- associated_
instance_ intnum - Number of instances bound to the allowlist
- id str
- The provider-assigned unique ID for this managed resource.
- allow
List StringId - Allowlist ID
- allow
List NumberIp Num - Number of rules specified in the allowlist
- associated
Instance NumberNum - Number of instances bound to the allowlist
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing AllowList Resource
Get an existing AllowList 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?: AllowListState, opts?: CustomResourceOptions): AllowList@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
allow_list: Optional[str] = None,
allow_list_desc: Optional[str] = None,
allow_list_id: Optional[str] = None,
allow_list_ip_num: Optional[int] = None,
allow_list_name: Optional[str] = None,
apply_instance_num: Optional[int] = None,
associated_instance_num: Optional[int] = None,
associated_instances: Optional[Sequence[AllowListAssociatedInstanceArgs]] = None) -> AllowListfunc GetAllowList(ctx *Context, name string, id IDInput, state *AllowListState, opts ...ResourceOption) (*AllowList, error)public static AllowList Get(string name, Input<string> id, AllowListState? state, CustomResourceOptions? opts = null)public static AllowList get(String name, Output<String> id, AllowListState state, CustomResourceOptions options)resources: _: type: volcenginecc:kafka:AllowList 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.
- Allow
List stringDesc - Allowlist description. Maximum length: 200 characters
- Allow
List stringId - Allowlist ID
- Allow
List intIp Num - Number of rules specified in the allowlist
- Allow
List stringName - Allowlist rule name. Length: 1–128 characters. Can only contain Chinese characters, letters, numbers, underscores, and hyphens (-). Cannot start with a number or hyphen (-). The allowlist name must be unique within the current region
- Allow
List stringValue - Allowlist rule list. Supports specifying IP addresses or IP ranges. Separate multiple IP addresses or ranges with commas (,). Each allowlist can contain up to 300 IP addresses or ranges
- Apply
Instance intNum - Number of instances already bound to this allowlist. If the AllowList parameter is specified, this field is required to indicate the expected number of instances affected after rule modification. If the expected number does not match the actual number, the request fails
- Associated
Instance intNum - Number of instances bound to the allowlist
- Associated
Instances List<Volcengine.Allow List Associated Instance>
- Allow
List string - Allowlist rule list. Supports specifying IP addresses or IP ranges. Separate multiple IP addresses or ranges with commas (,). Each allowlist can contain up to 300 IP addresses or ranges
- Allow
List stringDesc - Allowlist description. Maximum length: 200 characters
- Allow
List stringId - Allowlist ID
- Allow
List intIp Num - Number of rules specified in the allowlist
- Allow
List stringName - Allowlist rule name. Length: 1–128 characters. Can only contain Chinese characters, letters, numbers, underscores, and hyphens (-). Cannot start with a number or hyphen (-). The allowlist name must be unique within the current region
- Apply
Instance intNum - Number of instances already bound to this allowlist. If the AllowList parameter is specified, this field is required to indicate the expected number of instances affected after rule modification. If the expected number does not match the actual number, the request fails
- Associated
Instance intNum - Number of instances bound to the allowlist
- Associated
Instances []AllowList Associated Instance Args
- allow
List String - Allowlist rule list. Supports specifying IP addresses or IP ranges. Separate multiple IP addresses or ranges with commas (,). Each allowlist can contain up to 300 IP addresses or ranges
- allow
List StringDesc - Allowlist description. Maximum length: 200 characters
- allow
List StringId - Allowlist ID
- allow
List IntegerIp Num - Number of rules specified in the allowlist
- allow
List StringName - Allowlist rule name. Length: 1–128 characters. Can only contain Chinese characters, letters, numbers, underscores, and hyphens (-). Cannot start with a number or hyphen (-). The allowlist name must be unique within the current region
- apply
Instance IntegerNum - Number of instances already bound to this allowlist. If the AllowList parameter is specified, this field is required to indicate the expected number of instances affected after rule modification. If the expected number does not match the actual number, the request fails
- associated
Instance IntegerNum - Number of instances bound to the allowlist
- associated
Instances List<AllowList Associated Instance>
- allow
List string - Allowlist rule list. Supports specifying IP addresses or IP ranges. Separate multiple IP addresses or ranges with commas (,). Each allowlist can contain up to 300 IP addresses or ranges
- allow
List stringDesc - Allowlist description. Maximum length: 200 characters
- allow
List stringId - Allowlist ID
- allow
List numberIp Num - Number of rules specified in the allowlist
- allow
List stringName - Allowlist rule name. Length: 1–128 characters. Can only contain Chinese characters, letters, numbers, underscores, and hyphens (-). Cannot start with a number or hyphen (-). The allowlist name must be unique within the current region
- apply
Instance numberNum - Number of instances already bound to this allowlist. If the AllowList parameter is specified, this field is required to indicate the expected number of instances affected after rule modification. If the expected number does not match the actual number, the request fails
- associated
Instance numberNum - Number of instances bound to the allowlist
- associated
Instances AllowList Associated Instance[]
- allow_
list str - Allowlist rule list. Supports specifying IP addresses or IP ranges. Separate multiple IP addresses or ranges with commas (,). Each allowlist can contain up to 300 IP addresses or ranges
- allow_
list_ strdesc - Allowlist description. Maximum length: 200 characters
- allow_
list_ strid - Allowlist ID
- allow_
list_ intip_ num - Number of rules specified in the allowlist
- allow_
list_ strname - Allowlist rule name. Length: 1–128 characters. Can only contain Chinese characters, letters, numbers, underscores, and hyphens (-). Cannot start with a number or hyphen (-). The allowlist name must be unique within the current region
- apply_
instance_ intnum - Number of instances already bound to this allowlist. If the AllowList parameter is specified, this field is required to indicate the expected number of instances affected after rule modification. If the expected number does not match the actual number, the request fails
- associated_
instance_ intnum - Number of instances bound to the allowlist
- associated_
instances Sequence[AllowList Associated Instance Args]
- allow
List String - Allowlist rule list. Supports specifying IP addresses or IP ranges. Separate multiple IP addresses or ranges with commas (,). Each allowlist can contain up to 300 IP addresses or ranges
- allow
List StringDesc - Allowlist description. Maximum length: 200 characters
- allow
List StringId - Allowlist ID
- allow
List NumberIp Num - Number of rules specified in the allowlist
- allow
List StringName - Allowlist rule name. Length: 1–128 characters. Can only contain Chinese characters, letters, numbers, underscores, and hyphens (-). Cannot start with a number or hyphen (-). The allowlist name must be unique within the current region
- apply
Instance NumberNum - Number of instances already bound to this allowlist. If the AllowList parameter is specified, this field is required to indicate the expected number of instances affected after rule modification. If the expected number does not match the actual number, the request fails
- associated
Instance NumberNum - Number of instances bound to the allowlist
- associated
Instances List<Property Map>
Supporting Types
AllowListAssociatedInstance, AllowListAssociatedInstanceArgs
- Instance
Id string - ID of the instance bound to the allowlist
- Instance
Id string - ID of the instance bound to the allowlist
- instance
Id String - ID of the instance bound to the allowlist
- instance
Id string - ID of the instance bound to the allowlist
- instance_
id str - ID of the instance bound to the allowlist
- instance
Id String - ID of the instance bound to the allowlist
Import
$ pulumi import volcenginecc:kafka/allowList:AllowList example "allow_list_id"
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- volcenginecc volcengine/pulumi-volcenginecc
- License
- MPL-2.0
- Notes
- This Pulumi package is based on the
volcengineccTerraform Provider.
published on Thursday, Apr 23, 2026 by Volcengine
