AclArgs

data class AclArgs(val aclEntries: Output<List<AclAclEntryArgs>>? = null, val aclName: Output<String>? = null, val dryRun: Output<Boolean>? = null, val resourceGroupId: Output<String>? = null, val tags: Output<Map<String, String>>? = null) : ConvertibleToJava<AclArgs>

Provides a Application Load Balancer (ALB) Acl resource. For information about ALB Acl and how to use it, see What is Acl.

NOTE: Available since v1.133.0.

Example Usage

Basic Usage

import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";
const _default = alicloud.resourcemanager.getResourceGroups({});
const defaultAcl = new alicloud.alb.Acl("default", {
aclName: "tf_example",
resourceGroupId: _default.then(_default => _default.groups?.[0]?.id),
});
import pulumi
import pulumi_alicloud as alicloud
default = alicloud.resourcemanager.get_resource_groups()
default_acl = alicloud.alb.Acl("default",
acl_name="tf_example",
resource_group_id=default.groups[0].id)
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;
return await Deployment.RunAsync(() =>
{
var @default = AliCloud.ResourceManager.GetResourceGroups.Invoke();
var defaultAcl = new AliCloud.Alb.Acl("default", new()
{
AclName = "tf_example",
ResourceGroupId = @default.Apply(@default => @default.Apply(getResourceGroupsResult => getResourceGroupsResult.Groups[0]?.Id)),
});
});
package main
import (
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/alb"
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/resourcemanager"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_default, err := resourcemanager.GetResourceGroups(ctx, &resourcemanager.GetResourceGroupsArgs{}, nil)
if err != nil {
return err
}
_, err = alb.NewAcl(ctx, "default", &alb.AclArgs{
AclName: pulumi.String("tf_example"),
ResourceGroupId: pulumi.String(_default.Groups[0].Id),
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.resourcemanager.ResourcemanagerFunctions;
import com.pulumi.alicloud.resourcemanager.inputs.GetResourceGroupsArgs;
import com.pulumi.alicloud.alb.Acl;
import com.pulumi.alicloud.alb.AclArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
final var default = ResourcemanagerFunctions.getResourceGroups(GetResourceGroupsArgs.builder()
.build());
var defaultAcl = new Acl("defaultAcl", AclArgs.builder()
.aclName("tf_example")
.resourceGroupId(default_.groups()[0].id())
.build());
}
}
resources:
defaultAcl:
type: alicloud:alb:Acl
name: default
properties:
aclName: tf_example
resourceGroupId: ${default.groups[0].id}
variables:
default:
fn::invoke:
function: alicloud:resourcemanager:getResourceGroups
arguments: {}

Import

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

$ pulumi import alicloud:alb/acl:Acl example <id>

Constructors

Link copied to clipboard
constructor(aclEntries: Output<List<AclAclEntryArgs>>? = null, aclName: Output<String>? = null, dryRun: Output<Boolean>? = null, resourceGroupId: Output<String>? = null, tags: Output<Map<String, String>>? = null)

Properties

Link copied to clipboard
val aclEntries: Output<List<AclAclEntryArgs>>? = null

The list of the ACL entries. You can add up to 20 entries in each call. See acl_entries below for details. NOTE: "Field 'acl_entries' has been deprecated from provider version 1.166.0 and it will be removed in the future version. Please use the new resource 'alicloud_alb_acl_entry_attachment'.",

Link copied to clipboard
val aclName: Output<String>? = null

The name of the ACL. The name must be 2 to 128 characters in length, and can contain letters, digits, hyphens (-) and underscores (_). It must start with a letter.

Link copied to clipboard
val dryRun: Output<Boolean>? = null

Specifies whether to precheck the API request.

Link copied to clipboard
val resourceGroupId: Output<String>? = null

The ID of the resource group.

Link copied to clipboard
val tags: Output<Map<String, String>>? = null

A mapping of tags to assign to the resource.

Functions

Link copied to clipboard
open override fun toJava(): AclArgs