1. Packages
  2. Alibaba Cloud Provider
  3. API Docs
  4. alb
  5. ListenerAclAttachment
Alibaba Cloud v3.76.0 published on Tuesday, Apr 8, 2025 by Pulumi

alicloud.alb.ListenerAclAttachment

Explore with Pulumi AI

Provides a ALB Listener Acl Attachment resource. Associating ACL to listening.

For information about ALB Listener Acl Attachment and how to use it, see What is Listener Acl Attachment.

NOTE: Available since v1.163.0.

NOTE: You can associate at most three ACLs with a listener.

NOTE: You can only configure either a whitelist or a blacklist for listener, not at the same time.

Create ListenerAclAttachment Resource

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

Constructor syntax

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

@overload
def ListenerAclAttachment(resource_name: str,
                          opts: Optional[ResourceOptions] = None,
                          acl_id: Optional[str] = None,
                          acl_type: Optional[str] = None,
                          listener_id: Optional[str] = None)
func NewListenerAclAttachment(ctx *Context, name string, args ListenerAclAttachmentArgs, opts ...ResourceOption) (*ListenerAclAttachment, error)
public ListenerAclAttachment(string name, ListenerAclAttachmentArgs args, CustomResourceOptions? opts = null)
public ListenerAclAttachment(String name, ListenerAclAttachmentArgs args)
public ListenerAclAttachment(String name, ListenerAclAttachmentArgs args, CustomResourceOptions options)
type: alicloud:alb:ListenerAclAttachment
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. ListenerAclAttachmentArgs
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. ListenerAclAttachmentArgs
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. ListenerAclAttachmentArgs
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. ListenerAclAttachmentArgs
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. ListenerAclAttachmentArgs
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 listenerAclAttachmentResource = new AliCloud.Alb.ListenerAclAttachment("listenerAclAttachmentResource", new()
{
    AclId = "string",
    AclType = "string",
    ListenerId = "string",
});
Copy
example, err := alb.NewListenerAclAttachment(ctx, "listenerAclAttachmentResource", &alb.ListenerAclAttachmentArgs{
	AclId:      pulumi.String("string"),
	AclType:    pulumi.String("string"),
	ListenerId: pulumi.String("string"),
})
Copy
var listenerAclAttachmentResource = new ListenerAclAttachment("listenerAclAttachmentResource", ListenerAclAttachmentArgs.builder()
    .aclId("string")
    .aclType("string")
    .listenerId("string")
    .build());
Copy
listener_acl_attachment_resource = alicloud.alb.ListenerAclAttachment("listenerAclAttachmentResource",
    acl_id="string",
    acl_type="string",
    listener_id="string")
Copy
const listenerAclAttachmentResource = new alicloud.alb.ListenerAclAttachment("listenerAclAttachmentResource", {
    aclId: "string",
    aclType: "string",
    listenerId: "string",
});
Copy
type: alicloud:alb:ListenerAclAttachment
properties:
    aclId: string
    aclType: string
    listenerId: string
Copy

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

AclId
This property is required.
Changes to this property will trigger replacement.
string
The ID list of the access policy group bound by the listener.
AclType
This property is required.
Changes to this property will trigger replacement.
string
Access control type:

  • White: only requests from IP addresses or address segments in the selected access control list are forwarded. The whitelist applies to scenarios where only specific IP addresses are allowed to access. There are certain business risks in setting up a whitelist. Once the whitelist is set, only the IP addresses in the whitelist can access the load balancer listener. If whitelist access is enabled but no IP addresses are added to the access policy group, the server load balancer listener forwards all requests.
  • Black: All requests from IP addresses or address segments in the selected access control list are not forwarded. Blacklists are applicable to scenarios where only certain IP addresses are restricted. If blacklist access is enabled and no IP is added to the access policy group, the server load balancer listener forwards all requests.
ListenerId
This property is required.
Changes to this property will trigger replacement.
string
Listener instance ID.
AclId
This property is required.
Changes to this property will trigger replacement.
string
The ID list of the access policy group bound by the listener.
AclType
This property is required.
Changes to this property will trigger replacement.
string
Access control type:

  • White: only requests from IP addresses or address segments in the selected access control list are forwarded. The whitelist applies to scenarios where only specific IP addresses are allowed to access. There are certain business risks in setting up a whitelist. Once the whitelist is set, only the IP addresses in the whitelist can access the load balancer listener. If whitelist access is enabled but no IP addresses are added to the access policy group, the server load balancer listener forwards all requests.
  • Black: All requests from IP addresses or address segments in the selected access control list are not forwarded. Blacklists are applicable to scenarios where only certain IP addresses are restricted. If blacklist access is enabled and no IP is added to the access policy group, the server load balancer listener forwards all requests.
ListenerId
This property is required.
Changes to this property will trigger replacement.
string
Listener instance ID.
aclId
This property is required.
Changes to this property will trigger replacement.
String
The ID list of the access policy group bound by the listener.
aclType
This property is required.
Changes to this property will trigger replacement.
String
Access control type:

  • White: only requests from IP addresses or address segments in the selected access control list are forwarded. The whitelist applies to scenarios where only specific IP addresses are allowed to access. There are certain business risks in setting up a whitelist. Once the whitelist is set, only the IP addresses in the whitelist can access the load balancer listener. If whitelist access is enabled but no IP addresses are added to the access policy group, the server load balancer listener forwards all requests.
  • Black: All requests from IP addresses or address segments in the selected access control list are not forwarded. Blacklists are applicable to scenarios where only certain IP addresses are restricted. If blacklist access is enabled and no IP is added to the access policy group, the server load balancer listener forwards all requests.
listenerId
This property is required.
Changes to this property will trigger replacement.
String
Listener instance ID.
aclId
This property is required.
Changes to this property will trigger replacement.
string
The ID list of the access policy group bound by the listener.
aclType
This property is required.
Changes to this property will trigger replacement.
string
Access control type:

  • White: only requests from IP addresses or address segments in the selected access control list are forwarded. The whitelist applies to scenarios where only specific IP addresses are allowed to access. There are certain business risks in setting up a whitelist. Once the whitelist is set, only the IP addresses in the whitelist can access the load balancer listener. If whitelist access is enabled but no IP addresses are added to the access policy group, the server load balancer listener forwards all requests.
  • Black: All requests from IP addresses or address segments in the selected access control list are not forwarded. Blacklists are applicable to scenarios where only certain IP addresses are restricted. If blacklist access is enabled and no IP is added to the access policy group, the server load balancer listener forwards all requests.
listenerId
This property is required.
Changes to this property will trigger replacement.
string
Listener instance ID.
acl_id
This property is required.
Changes to this property will trigger replacement.
str
The ID list of the access policy group bound by the listener.
acl_type
This property is required.
Changes to this property will trigger replacement.
str
Access control type:

  • White: only requests from IP addresses or address segments in the selected access control list are forwarded. The whitelist applies to scenarios where only specific IP addresses are allowed to access. There are certain business risks in setting up a whitelist. Once the whitelist is set, only the IP addresses in the whitelist can access the load balancer listener. If whitelist access is enabled but no IP addresses are added to the access policy group, the server load balancer listener forwards all requests.
  • Black: All requests from IP addresses or address segments in the selected access control list are not forwarded. Blacklists are applicable to scenarios where only certain IP addresses are restricted. If blacklist access is enabled and no IP is added to the access policy group, the server load balancer listener forwards all requests.
listener_id
This property is required.
Changes to this property will trigger replacement.
str
Listener instance ID.
aclId
This property is required.
Changes to this property will trigger replacement.
String
The ID list of the access policy group bound by the listener.
aclType
This property is required.
Changes to this property will trigger replacement.
String
Access control type:

  • White: only requests from IP addresses or address segments in the selected access control list are forwarded. The whitelist applies to scenarios where only specific IP addresses are allowed to access. There are certain business risks in setting up a whitelist. Once the whitelist is set, only the IP addresses in the whitelist can access the load balancer listener. If whitelist access is enabled but no IP addresses are added to the access policy group, the server load balancer listener forwards all requests.
  • Black: All requests from IP addresses or address segments in the selected access control list are not forwarded. Blacklists are applicable to scenarios where only certain IP addresses are restricted. If blacklist access is enabled and no IP is added to the access policy group, the server load balancer listener forwards all requests.
listenerId
This property is required.
Changes to this property will trigger replacement.
String
Listener instance ID.

Outputs

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

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

Look up Existing ListenerAclAttachment Resource

Get an existing ListenerAclAttachment 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?: ListenerAclAttachmentState, opts?: CustomResourceOptions): ListenerAclAttachment
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        acl_id: Optional[str] = None,
        acl_type: Optional[str] = None,
        listener_id: Optional[str] = None,
        status: Optional[str] = None) -> ListenerAclAttachment
func GetListenerAclAttachment(ctx *Context, name string, id IDInput, state *ListenerAclAttachmentState, opts ...ResourceOption) (*ListenerAclAttachment, error)
public static ListenerAclAttachment Get(string name, Input<string> id, ListenerAclAttachmentState? state, CustomResourceOptions? opts = null)
public static ListenerAclAttachment get(String name, Output<String> id, ListenerAclAttachmentState state, CustomResourceOptions options)
resources:  _:    type: alicloud:alb:ListenerAclAttachment    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:
AclId Changes to this property will trigger replacement. string
The ID list of the access policy group bound by the listener.
AclType Changes to this property will trigger replacement. string
Access control type:

  • White: only requests from IP addresses or address segments in the selected access control list are forwarded. The whitelist applies to scenarios where only specific IP addresses are allowed to access. There are certain business risks in setting up a whitelist. Once the whitelist is set, only the IP addresses in the whitelist can access the load balancer listener. If whitelist access is enabled but no IP addresses are added to the access policy group, the server load balancer listener forwards all requests.
  • Black: All requests from IP addresses or address segments in the selected access control list are not forwarded. Blacklists are applicable to scenarios where only certain IP addresses are restricted. If blacklist access is enabled and no IP is added to the access policy group, the server load balancer listener forwards all requests.
ListenerId Changes to this property will trigger replacement. string
Listener instance ID.
Status string
Listener Status.
AclId Changes to this property will trigger replacement. string
The ID list of the access policy group bound by the listener.
AclType Changes to this property will trigger replacement. string
Access control type:

  • White: only requests from IP addresses or address segments in the selected access control list are forwarded. The whitelist applies to scenarios where only specific IP addresses are allowed to access. There are certain business risks in setting up a whitelist. Once the whitelist is set, only the IP addresses in the whitelist can access the load balancer listener. If whitelist access is enabled but no IP addresses are added to the access policy group, the server load balancer listener forwards all requests.
  • Black: All requests from IP addresses or address segments in the selected access control list are not forwarded. Blacklists are applicable to scenarios where only certain IP addresses are restricted. If blacklist access is enabled and no IP is added to the access policy group, the server load balancer listener forwards all requests.
ListenerId Changes to this property will trigger replacement. string
Listener instance ID.
Status string
Listener Status.
aclId Changes to this property will trigger replacement. String
The ID list of the access policy group bound by the listener.
aclType Changes to this property will trigger replacement. String
Access control type:

  • White: only requests from IP addresses or address segments in the selected access control list are forwarded. The whitelist applies to scenarios where only specific IP addresses are allowed to access. There are certain business risks in setting up a whitelist. Once the whitelist is set, only the IP addresses in the whitelist can access the load balancer listener. If whitelist access is enabled but no IP addresses are added to the access policy group, the server load balancer listener forwards all requests.
  • Black: All requests from IP addresses or address segments in the selected access control list are not forwarded. Blacklists are applicable to scenarios where only certain IP addresses are restricted. If blacklist access is enabled and no IP is added to the access policy group, the server load balancer listener forwards all requests.
listenerId Changes to this property will trigger replacement. String
Listener instance ID.
status String
Listener Status.
aclId Changes to this property will trigger replacement. string
The ID list of the access policy group bound by the listener.
aclType Changes to this property will trigger replacement. string
Access control type:

  • White: only requests from IP addresses or address segments in the selected access control list are forwarded. The whitelist applies to scenarios where only specific IP addresses are allowed to access. There are certain business risks in setting up a whitelist. Once the whitelist is set, only the IP addresses in the whitelist can access the load balancer listener. If whitelist access is enabled but no IP addresses are added to the access policy group, the server load balancer listener forwards all requests.
  • Black: All requests from IP addresses or address segments in the selected access control list are not forwarded. Blacklists are applicable to scenarios where only certain IP addresses are restricted. If blacklist access is enabled and no IP is added to the access policy group, the server load balancer listener forwards all requests.
listenerId Changes to this property will trigger replacement. string
Listener instance ID.
status string
Listener Status.
acl_id Changes to this property will trigger replacement. str
The ID list of the access policy group bound by the listener.
acl_type Changes to this property will trigger replacement. str
Access control type:

  • White: only requests from IP addresses or address segments in the selected access control list are forwarded. The whitelist applies to scenarios where only specific IP addresses are allowed to access. There are certain business risks in setting up a whitelist. Once the whitelist is set, only the IP addresses in the whitelist can access the load balancer listener. If whitelist access is enabled but no IP addresses are added to the access policy group, the server load balancer listener forwards all requests.
  • Black: All requests from IP addresses or address segments in the selected access control list are not forwarded. Blacklists are applicable to scenarios where only certain IP addresses are restricted. If blacklist access is enabled and no IP is added to the access policy group, the server load balancer listener forwards all requests.
listener_id Changes to this property will trigger replacement. str
Listener instance ID.
status str
Listener Status.
aclId Changes to this property will trigger replacement. String
The ID list of the access policy group bound by the listener.
aclType Changes to this property will trigger replacement. String
Access control type:

  • White: only requests from IP addresses or address segments in the selected access control list are forwarded. The whitelist applies to scenarios where only specific IP addresses are allowed to access. There are certain business risks in setting up a whitelist. Once the whitelist is set, only the IP addresses in the whitelist can access the load balancer listener. If whitelist access is enabled but no IP addresses are added to the access policy group, the server load balancer listener forwards all requests.
  • Black: All requests from IP addresses or address segments in the selected access control list are not forwarded. Blacklists are applicable to scenarios where only certain IP addresses are restricted. If blacklist access is enabled and no IP is added to the access policy group, the server load balancer listener forwards all requests.
listenerId Changes to this property will trigger replacement. String
Listener instance ID.
status String
Listener Status.

Import

ALB Listener Acl Attachment can be imported using the id, e.g.

$ pulumi import alicloud:alb/listenerAclAttachment:ListenerAclAttachment example <listener_id>:<acl_id>
Copy

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.