1. Packages
  2. Tencentcloud Provider
  3. API Docs
  4. CkafkaAcl
tencentcloud 1.81.183 published on Wednesday, Apr 16, 2025 by tencentcloudstack

tencentcloud.CkafkaAcl

Explore with Pulumi AI

Provides a resource to create a Ckafka Acl.

Example Usage

Ckafka Acl

import * as pulumi from "@pulumi/pulumi";
import * as tencentcloud from "@pulumi/tencentcloud";

const foo = new tencentcloud.CkafkaAcl("foo", {
    instanceId: "ckafka-f9ife4zz",
    resourceType: "TOPIC",
    resourceName: "topic-tf-test",
    operationType: "WRITE",
    permissionType: "ALLOW",
    host: "*",
    principal: tencentcloud_ckafka_user.foo.account_name,
});
Copy
import pulumi
import pulumi_tencentcloud as tencentcloud

foo = tencentcloud.CkafkaAcl("foo",
    instance_id="ckafka-f9ife4zz",
    resource_type="TOPIC",
    resource_name_="topic-tf-test",
    operation_type="WRITE",
    permission_type="ALLOW",
    host="*",
    principal=tencentcloud_ckafka_user["foo"]["account_name"])
Copy
package main

import (
	"github.com/pulumi/pulumi-terraform-provider/sdks/go/tencentcloud/tencentcloud"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := tencentcloud.NewCkafkaAcl(ctx, "foo", &tencentcloud.CkafkaAclArgs{
			InstanceId:     pulumi.String("ckafka-f9ife4zz"),
			ResourceType:   pulumi.String("TOPIC"),
			ResourceName:   pulumi.String("topic-tf-test"),
			OperationType:  pulumi.String("WRITE"),
			PermissionType: pulumi.String("ALLOW"),
			Host:           pulumi.String("*"),
			Principal:      pulumi.Any(tencentcloud_ckafka_user.Foo.Account_name),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Tencentcloud = Pulumi.Tencentcloud;

return await Deployment.RunAsync(() => 
{
    var foo = new Tencentcloud.CkafkaAcl("foo", new()
    {
        InstanceId = "ckafka-f9ife4zz",
        ResourceType = "TOPIC",
        ResourceName = "topic-tf-test",
        OperationType = "WRITE",
        PermissionType = "ALLOW",
        Host = "*",
        Principal = tencentcloud_ckafka_user.Foo.Account_name,
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.tencentcloud.CkafkaAcl;
import com.pulumi.tencentcloud.CkafkaAclArgs;
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 foo = new CkafkaAcl("foo", CkafkaAclArgs.builder()
            .instanceId("ckafka-f9ife4zz")
            .resourceType("TOPIC")
            .resourceName("topic-tf-test")
            .operationType("WRITE")
            .permissionType("ALLOW")
            .host("*")
            .principal(tencentcloud_ckafka_user.foo().account_name())
            .build());

    }
}
Copy
resources:
  foo:
    type: tencentcloud:CkafkaAcl
    properties:
      instanceId: ckafka-f9ife4zz
      resourceType: TOPIC
      resourceName: topic-tf-test
      operationType: WRITE
      permissionType: ALLOW
      host: '*'
      principal: ${tencentcloud_ckafka_user.foo.account_name}
Copy

Create CkafkaAcl Resource

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

Constructor syntax

new CkafkaAcl(name: string, args: CkafkaAclArgs, opts?: CustomResourceOptions);
@overload
def CkafkaAcl(resource_name: str,
              args: CkafkaAclArgs,
              opts: Optional[ResourceOptions] = None)

@overload
def CkafkaAcl(resource_name: str,
              opts: Optional[ResourceOptions] = None,
              instance_id: Optional[str] = None,
              operation_type: Optional[str] = None,
              resource_name_: Optional[str] = None,
              ckafka_acl_id: Optional[str] = None,
              host: Optional[str] = None,
              permission_type: Optional[str] = None,
              principal: Optional[str] = None,
              resource_type: Optional[str] = None)
func NewCkafkaAcl(ctx *Context, name string, args CkafkaAclArgs, opts ...ResourceOption) (*CkafkaAcl, error)
public CkafkaAcl(string name, CkafkaAclArgs args, CustomResourceOptions? opts = null)
public CkafkaAcl(String name, CkafkaAclArgs args)
public CkafkaAcl(String name, CkafkaAclArgs args, CustomResourceOptions options)
type: tencentcloud:CkafkaAcl
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. string
The unique name of the resource.
args This property is required. CkafkaAclArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args This property is required. CkafkaAclArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name This property is required. string
The unique name of the resource.
args This property is required. CkafkaAclArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args This property is required. CkafkaAclArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. CkafkaAclArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

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

InstanceId This property is required. string
ID of the ckafka instance.
OperationType This property is required. string
ACL operation mode. Valid values: UNKNOWN, ANY, ALL, READ, WRITE, CREATE, DELETE, ALTER, DESCRIBE, CLUSTER_ACTION, DESCRIBE_CONFIGS and ALTER_CONFIGS.
ResourceName This property is required. string
ACL resource name, which is related to resource_type. For example, if resource_type is TOPIC, this field indicates the topic name; if resource_type is GROUP, this field indicates the group name.
CkafkaAclId string
ID of the resource.
Host string
The default is *, which means that any host can access it. Support filling in IP or network segment, and support ;separation.
PermissionType string
ACL permission type. Valid values: UNKNOWN, ANY, DENY, ALLOW. and ALLOW by default. Currently, CKafka supports ALLOW (equivalent to allow list), and other fields will be used for future ACLs compatible with open-source Kafka.
Principal string
User list. The default value is *, which means that any user can access. The current user can only be one included in the user list. For example: root meaning user root can access.
ResourceType string
ACL resource type. Valid values are UNKNOWN, ANY, TOPIC, GROUP, CLUSTER, TRANSACTIONAL_ID. and TOPIC by default. Currently, only TOPIC is available, and other fields will be used for future ACLs compatible with open-source Kafka.
InstanceId This property is required. string
ID of the ckafka instance.
OperationType This property is required. string
ACL operation mode. Valid values: UNKNOWN, ANY, ALL, READ, WRITE, CREATE, DELETE, ALTER, DESCRIBE, CLUSTER_ACTION, DESCRIBE_CONFIGS and ALTER_CONFIGS.
ResourceName This property is required. string
ACL resource name, which is related to resource_type. For example, if resource_type is TOPIC, this field indicates the topic name; if resource_type is GROUP, this field indicates the group name.
CkafkaAclId string
ID of the resource.
Host string
The default is *, which means that any host can access it. Support filling in IP or network segment, and support ;separation.
PermissionType string
ACL permission type. Valid values: UNKNOWN, ANY, DENY, ALLOW. and ALLOW by default. Currently, CKafka supports ALLOW (equivalent to allow list), and other fields will be used for future ACLs compatible with open-source Kafka.
Principal string
User list. The default value is *, which means that any user can access. The current user can only be one included in the user list. For example: root meaning user root can access.
ResourceType string
ACL resource type. Valid values are UNKNOWN, ANY, TOPIC, GROUP, CLUSTER, TRANSACTIONAL_ID. and TOPIC by default. Currently, only TOPIC is available, and other fields will be used for future ACLs compatible with open-source Kafka.
instanceId This property is required. String
ID of the ckafka instance.
operationType This property is required. String
ACL operation mode. Valid values: UNKNOWN, ANY, ALL, READ, WRITE, CREATE, DELETE, ALTER, DESCRIBE, CLUSTER_ACTION, DESCRIBE_CONFIGS and ALTER_CONFIGS.
resourceName This property is required. String
ACL resource name, which is related to resource_type. For example, if resource_type is TOPIC, this field indicates the topic name; if resource_type is GROUP, this field indicates the group name.
ckafkaAclId String
ID of the resource.
host String
The default is *, which means that any host can access it. Support filling in IP or network segment, and support ;separation.
permissionType String
ACL permission type. Valid values: UNKNOWN, ANY, DENY, ALLOW. and ALLOW by default. Currently, CKafka supports ALLOW (equivalent to allow list), and other fields will be used for future ACLs compatible with open-source Kafka.
principal String
User list. The default value is *, which means that any user can access. The current user can only be one included in the user list. For example: root meaning user root can access.
resourceType String
ACL resource type. Valid values are UNKNOWN, ANY, TOPIC, GROUP, CLUSTER, TRANSACTIONAL_ID. and TOPIC by default. Currently, only TOPIC is available, and other fields will be used for future ACLs compatible with open-source Kafka.
instanceId This property is required. string
ID of the ckafka instance.
operationType This property is required. string
ACL operation mode. Valid values: UNKNOWN, ANY, ALL, READ, WRITE, CREATE, DELETE, ALTER, DESCRIBE, CLUSTER_ACTION, DESCRIBE_CONFIGS and ALTER_CONFIGS.
resourceName This property is required. string
ACL resource name, which is related to resource_type. For example, if resource_type is TOPIC, this field indicates the topic name; if resource_type is GROUP, this field indicates the group name.
ckafkaAclId string
ID of the resource.
host string
The default is *, which means that any host can access it. Support filling in IP or network segment, and support ;separation.
permissionType string
ACL permission type. Valid values: UNKNOWN, ANY, DENY, ALLOW. and ALLOW by default. Currently, CKafka supports ALLOW (equivalent to allow list), and other fields will be used for future ACLs compatible with open-source Kafka.
principal string
User list. The default value is *, which means that any user can access. The current user can only be one included in the user list. For example: root meaning user root can access.
resourceType string
ACL resource type. Valid values are UNKNOWN, ANY, TOPIC, GROUP, CLUSTER, TRANSACTIONAL_ID. and TOPIC by default. Currently, only TOPIC is available, and other fields will be used for future ACLs compatible with open-source Kafka.
instance_id This property is required. str
ID of the ckafka instance.
operation_type This property is required. str
ACL operation mode. Valid values: UNKNOWN, ANY, ALL, READ, WRITE, CREATE, DELETE, ALTER, DESCRIBE, CLUSTER_ACTION, DESCRIBE_CONFIGS and ALTER_CONFIGS.
resource_name This property is required. str
ACL resource name, which is related to resource_type. For example, if resource_type is TOPIC, this field indicates the topic name; if resource_type is GROUP, this field indicates the group name.
ckafka_acl_id str
ID of the resource.
host str
The default is *, which means that any host can access it. Support filling in IP or network segment, and support ;separation.
permission_type str
ACL permission type. Valid values: UNKNOWN, ANY, DENY, ALLOW. and ALLOW by default. Currently, CKafka supports ALLOW (equivalent to allow list), and other fields will be used for future ACLs compatible with open-source Kafka.
principal str
User list. The default value is *, which means that any user can access. The current user can only be one included in the user list. For example: root meaning user root can access.
resource_type str
ACL resource type. Valid values are UNKNOWN, ANY, TOPIC, GROUP, CLUSTER, TRANSACTIONAL_ID. and TOPIC by default. Currently, only TOPIC is available, and other fields will be used for future ACLs compatible with open-source Kafka.
instanceId This property is required. String
ID of the ckafka instance.
operationType This property is required. String
ACL operation mode. Valid values: UNKNOWN, ANY, ALL, READ, WRITE, CREATE, DELETE, ALTER, DESCRIBE, CLUSTER_ACTION, DESCRIBE_CONFIGS and ALTER_CONFIGS.
resourceName This property is required. String
ACL resource name, which is related to resource_type. For example, if resource_type is TOPIC, this field indicates the topic name; if resource_type is GROUP, this field indicates the group name.
ckafkaAclId String
ID of the resource.
host String
The default is *, which means that any host can access it. Support filling in IP or network segment, and support ;separation.
permissionType String
ACL permission type. Valid values: UNKNOWN, ANY, DENY, ALLOW. and ALLOW by default. Currently, CKafka supports ALLOW (equivalent to allow list), and other fields will be used for future ACLs compatible with open-source Kafka.
principal String
User list. The default value is *, which means that any user can access. The current user can only be one included in the user list. For example: root meaning user root can access.
resourceType String
ACL resource type. Valid values are UNKNOWN, ANY, TOPIC, GROUP, CLUSTER, TRANSACTIONAL_ID. and TOPIC by default. Currently, only TOPIC is available, and other fields will be used for future ACLs compatible with open-source Kafka.

Outputs

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

Id string
The provider-assigned unique ID for this managed resource.
Id string
The provider-assigned unique ID for this managed resource.
id String
The provider-assigned unique ID for this managed resource.
id string
The provider-assigned unique ID for this managed resource.
id str
The provider-assigned unique ID for this managed resource.
id String
The provider-assigned unique ID for this managed resource.

Look up Existing CkafkaAcl Resource

Get an existing CkafkaAcl 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?: CkafkaAclState, opts?: CustomResourceOptions): CkafkaAcl
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        ckafka_acl_id: Optional[str] = None,
        host: Optional[str] = None,
        instance_id: Optional[str] = None,
        operation_type: Optional[str] = None,
        permission_type: Optional[str] = None,
        principal: Optional[str] = None,
        resource_name: Optional[str] = None,
        resource_type: Optional[str] = None) -> CkafkaAcl
func GetCkafkaAcl(ctx *Context, name string, id IDInput, state *CkafkaAclState, opts ...ResourceOption) (*CkafkaAcl, error)
public static CkafkaAcl Get(string name, Input<string> id, CkafkaAclState? state, CustomResourceOptions? opts = null)
public static CkafkaAcl get(String name, Output<String> id, CkafkaAclState state, CustomResourceOptions options)
resources:  _:    type: tencentcloud:CkafkaAcl    get:      id: ${id}
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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:
CkafkaAclId string
ID of the resource.
Host string
The default is *, which means that any host can access it. Support filling in IP or network segment, and support ;separation.
InstanceId string
ID of the ckafka instance.
OperationType string
ACL operation mode. Valid values: UNKNOWN, ANY, ALL, READ, WRITE, CREATE, DELETE, ALTER, DESCRIBE, CLUSTER_ACTION, DESCRIBE_CONFIGS and ALTER_CONFIGS.
PermissionType string
ACL permission type. Valid values: UNKNOWN, ANY, DENY, ALLOW. and ALLOW by default. Currently, CKafka supports ALLOW (equivalent to allow list), and other fields will be used for future ACLs compatible with open-source Kafka.
Principal string
User list. The default value is *, which means that any user can access. The current user can only be one included in the user list. For example: root meaning user root can access.
ResourceName string
ACL resource name, which is related to resource_type. For example, if resource_type is TOPIC, this field indicates the topic name; if resource_type is GROUP, this field indicates the group name.
ResourceType string
ACL resource type. Valid values are UNKNOWN, ANY, TOPIC, GROUP, CLUSTER, TRANSACTIONAL_ID. and TOPIC by default. Currently, only TOPIC is available, and other fields will be used for future ACLs compatible with open-source Kafka.
CkafkaAclId string
ID of the resource.
Host string
The default is *, which means that any host can access it. Support filling in IP or network segment, and support ;separation.
InstanceId string
ID of the ckafka instance.
OperationType string
ACL operation mode. Valid values: UNKNOWN, ANY, ALL, READ, WRITE, CREATE, DELETE, ALTER, DESCRIBE, CLUSTER_ACTION, DESCRIBE_CONFIGS and ALTER_CONFIGS.
PermissionType string
ACL permission type. Valid values: UNKNOWN, ANY, DENY, ALLOW. and ALLOW by default. Currently, CKafka supports ALLOW (equivalent to allow list), and other fields will be used for future ACLs compatible with open-source Kafka.
Principal string
User list. The default value is *, which means that any user can access. The current user can only be one included in the user list. For example: root meaning user root can access.
ResourceName string
ACL resource name, which is related to resource_type. For example, if resource_type is TOPIC, this field indicates the topic name; if resource_type is GROUP, this field indicates the group name.
ResourceType string
ACL resource type. Valid values are UNKNOWN, ANY, TOPIC, GROUP, CLUSTER, TRANSACTIONAL_ID. and TOPIC by default. Currently, only TOPIC is available, and other fields will be used for future ACLs compatible with open-source Kafka.
ckafkaAclId String
ID of the resource.
host String
The default is *, which means that any host can access it. Support filling in IP or network segment, and support ;separation.
instanceId String
ID of the ckafka instance.
operationType String
ACL operation mode. Valid values: UNKNOWN, ANY, ALL, READ, WRITE, CREATE, DELETE, ALTER, DESCRIBE, CLUSTER_ACTION, DESCRIBE_CONFIGS and ALTER_CONFIGS.
permissionType String
ACL permission type. Valid values: UNKNOWN, ANY, DENY, ALLOW. and ALLOW by default. Currently, CKafka supports ALLOW (equivalent to allow list), and other fields will be used for future ACLs compatible with open-source Kafka.
principal String
User list. The default value is *, which means that any user can access. The current user can only be one included in the user list. For example: root meaning user root can access.
resourceName String
ACL resource name, which is related to resource_type. For example, if resource_type is TOPIC, this field indicates the topic name; if resource_type is GROUP, this field indicates the group name.
resourceType String
ACL resource type. Valid values are UNKNOWN, ANY, TOPIC, GROUP, CLUSTER, TRANSACTIONAL_ID. and TOPIC by default. Currently, only TOPIC is available, and other fields will be used for future ACLs compatible with open-source Kafka.
ckafkaAclId string
ID of the resource.
host string
The default is *, which means that any host can access it. Support filling in IP or network segment, and support ;separation.
instanceId string
ID of the ckafka instance.
operationType string
ACL operation mode. Valid values: UNKNOWN, ANY, ALL, READ, WRITE, CREATE, DELETE, ALTER, DESCRIBE, CLUSTER_ACTION, DESCRIBE_CONFIGS and ALTER_CONFIGS.
permissionType string
ACL permission type. Valid values: UNKNOWN, ANY, DENY, ALLOW. and ALLOW by default. Currently, CKafka supports ALLOW (equivalent to allow list), and other fields will be used for future ACLs compatible with open-source Kafka.
principal string
User list. The default value is *, which means that any user can access. The current user can only be one included in the user list. For example: root meaning user root can access.
resourceName string
ACL resource name, which is related to resource_type. For example, if resource_type is TOPIC, this field indicates the topic name; if resource_type is GROUP, this field indicates the group name.
resourceType string
ACL resource type. Valid values are UNKNOWN, ANY, TOPIC, GROUP, CLUSTER, TRANSACTIONAL_ID. and TOPIC by default. Currently, only TOPIC is available, and other fields will be used for future ACLs compatible with open-source Kafka.
ckafka_acl_id str
ID of the resource.
host str
The default is *, which means that any host can access it. Support filling in IP or network segment, and support ;separation.
instance_id str
ID of the ckafka instance.
operation_type str
ACL operation mode. Valid values: UNKNOWN, ANY, ALL, READ, WRITE, CREATE, DELETE, ALTER, DESCRIBE, CLUSTER_ACTION, DESCRIBE_CONFIGS and ALTER_CONFIGS.
permission_type str
ACL permission type. Valid values: UNKNOWN, ANY, DENY, ALLOW. and ALLOW by default. Currently, CKafka supports ALLOW (equivalent to allow list), and other fields will be used for future ACLs compatible with open-source Kafka.
principal str
User list. The default value is *, which means that any user can access. The current user can only be one included in the user list. For example: root meaning user root can access.
resource_name str
ACL resource name, which is related to resource_type. For example, if resource_type is TOPIC, this field indicates the topic name; if resource_type is GROUP, this field indicates the group name.
resource_type str
ACL resource type. Valid values are UNKNOWN, ANY, TOPIC, GROUP, CLUSTER, TRANSACTIONAL_ID. and TOPIC by default. Currently, only TOPIC is available, and other fields will be used for future ACLs compatible with open-source Kafka.
ckafkaAclId String
ID of the resource.
host String
The default is *, which means that any host can access it. Support filling in IP or network segment, and support ;separation.
instanceId String
ID of the ckafka instance.
operationType String
ACL operation mode. Valid values: UNKNOWN, ANY, ALL, READ, WRITE, CREATE, DELETE, ALTER, DESCRIBE, CLUSTER_ACTION, DESCRIBE_CONFIGS and ALTER_CONFIGS.
permissionType String
ACL permission type. Valid values: UNKNOWN, ANY, DENY, ALLOW. and ALLOW by default. Currently, CKafka supports ALLOW (equivalent to allow list), and other fields will be used for future ACLs compatible with open-source Kafka.
principal String
User list. The default value is *, which means that any user can access. The current user can only be one included in the user list. For example: root meaning user root can access.
resourceName String
ACL resource name, which is related to resource_type. For example, if resource_type is TOPIC, this field indicates the topic name; if resource_type is GROUP, this field indicates the group name.
resourceType String
ACL resource type. Valid values are UNKNOWN, ANY, TOPIC, GROUP, CLUSTER, TRANSACTIONAL_ID. and TOPIC by default. Currently, only TOPIC is available, and other fields will be used for future ACLs compatible with open-source Kafka.

Import

Ckafka acl can be imported using the instance_id#permission_type#principal#host#operation_type#resource_type#resource_name, e.g.

$ pulumi import tencentcloud:index/ckafkaAcl:CkafkaAcl foo ckafka-f9ife4zz#ALLOW#test#*#WRITE#TOPIC#topic-tf-test
Copy

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

Package Details

Repository
tencentcloud tencentcloudstack/terraform-provider-tencentcloud
License
Notes
This Pulumi package is based on the tencentcloud Terraform Provider.