1. Packages
  2. Volcengine
  3. API Docs
  4. redis
  5. AllowList
Volcengine v0.0.24 published on Tuesday, Jun 25, 2024 by Volcengine

volcengine.redis.AllowList

Explore with Pulumi AI

volcengine logo
Volcengine v0.0.24 published on Tuesday, Jun 25, 2024 by Volcengine

    Provides a resource to manage redis allow list

    Example Usage

    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Volcengine = Pulumi.Volcengine;
    
    return await Deployment.RunAsync(() => 
    {
        var foo = new Volcengine.Redis.AllowList("foo", new()
        {
            AllowLists = new[]
            {
                "0.0.0.0/0",
                "192.168.0.0/24",
                "192.168.1.1",
                "192.168.2.22",
            },
            AllowListDesc = "acctftestallowlist",
            AllowListName = "acc_test_tf_allowlist_create",
        });
    
    });
    
    package main
    
    import (
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    	"github.com/volcengine/pulumi-volcengine/sdk/go/volcengine/redis"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := redis.NewAllowList(ctx, "foo", &redis.AllowListArgs{
    			AllowLists: pulumi.StringArray{
    				pulumi.String("0.0.0.0/0"),
    				pulumi.String("192.168.0.0/24"),
    				pulumi.String("192.168.1.1"),
    				pulumi.String("192.168.2.22"),
    			},
    			AllowListDesc: pulumi.String("acctftestallowlist"),
    			AllowListName: pulumi.String("acc_test_tf_allowlist_create"),
    		})
    		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.volcengine.redis.AllowList;
    import com.pulumi.volcengine.redis.AllowListArgs;
    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 AllowList("foo", AllowListArgs.builder()        
                .allowLists(            
                    "0.0.0.0/0",
                    "192.168.0.0/24",
                    "192.168.1.1",
                    "192.168.2.22")
                .allowListDesc("acctftestallowlist")
                .allowListName("acc_test_tf_allowlist_create")
                .build());
    
        }
    }
    
    import pulumi
    import pulumi_volcengine as volcengine
    
    foo = volcengine.redis.AllowList("foo",
        allow_lists=[
            "0.0.0.0/0",
            "192.168.0.0/24",
            "192.168.1.1",
            "192.168.2.22",
        ],
        allow_list_desc="acctftestallowlist",
        allow_list_name="acc_test_tf_allowlist_create")
    
    import * as pulumi from "@pulumi/pulumi";
    import * as volcengine from "@volcengine/pulumi";
    
    const foo = new volcengine.redis.AllowList("foo", {
        allowLists: [
            "0.0.0.0/0",
            "192.168.0.0/24",
            "192.168.1.1",
            "192.168.2.22",
        ],
        allowListDesc: "acctftestallowlist",
        allowListName: "acc_test_tf_allowlist_create",
    });
    
    resources:
      foo:
        type: volcengine:redis:AllowList
        properties:
          allowLists:
            - 0.0.0.0/0
            - 192.168.0.0/24
            - 192.168.1.1
            - 192.168.2.22
          allowListDesc: acctftestallowlist
          allowListName: acc_test_tf_allowlist_create
    

    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_name: Optional[str] = None,
                  allow_lists: Optional[Sequence[str]] = None,
                  allow_list_desc: Optional[str] = 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: volcengine:redis: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.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var allowListResource = new Volcengine.Redis.AllowList("allowListResource", new()
    {
        AllowListName = "string",
        AllowLists = new[]
        {
            "string",
        },
        AllowListDesc = "string",
    });
    
    example, err := redis.NewAllowList(ctx, "allowListResource", &redis.AllowListArgs{
    	AllowListName: pulumi.String("string"),
    	AllowLists: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	AllowListDesc: pulumi.String("string"),
    })
    
    var allowListResource = new AllowList("allowListResource", AllowListArgs.builder()
        .allowListName("string")
        .allowLists("string")
        .allowListDesc("string")
        .build());
    
    allow_list_resource = volcengine.redis.AllowList("allowListResource",
        allow_list_name="string",
        allow_lists=["string"],
        allow_list_desc="string")
    
    const allowListResource = new volcengine.redis.AllowList("allowListResource", {
        allowListName: "string",
        allowLists: ["string"],
        allowListDesc: "string",
    });
    
    type: volcengine:redis:AllowList
    properties:
        allowListDesc: string
        allowListName: string
        allowLists:
            - string
    

    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

    The AllowList resource accepts the following input properties:

    AllowListName string
    Name of allow list.
    AllowLists List<string>
    Ip list of allow list.
    AllowListDesc string
    Description of allow list.
    AllowListName string
    Name of allow list.
    AllowLists []string
    Ip list of allow list.
    AllowListDesc string
    Description of allow list.
    allowListName String
    Name of allow list.
    allowLists List<String>
    Ip list of allow list.
    allowListDesc String
    Description of allow list.
    allowListName string
    Name of allow list.
    allowLists string[]
    Ip list of allow list.
    allowListDesc string
    Description of allow list.
    allow_list_name str
    Name of allow list.
    allow_lists Sequence[str]
    Ip list of allow list.
    allow_list_desc str
    Description of allow list.
    allowListName String
    Name of allow list.
    allowLists List<String>
    Ip list of allow list.
    allowListDesc String
    Description of allow list.

    Outputs

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

    AllowListId string
    Id of allow list.
    AllowListIpNum int
    The IP number of allow list.
    AllowListType string
    Type of allow list.
    AssociatedInstanceNum int
    The number of instance that associated to allow list.
    AssociatedInstances List<AllowListAssociatedInstance>
    Instances associated by this allow list.
    Id string
    The provider-assigned unique ID for this managed resource.
    AllowListId string
    Id of allow list.
    AllowListIpNum int
    The IP number of allow list.
    AllowListType string
    Type of allow list.
    AssociatedInstanceNum int
    The number of instance that associated to allow list.
    AssociatedInstances []AllowListAssociatedInstance
    Instances associated by this allow list.
    Id string
    The provider-assigned unique ID for this managed resource.
    allowListId String
    Id of allow list.
    allowListIpNum Integer
    The IP number of allow list.
    allowListType String
    Type of allow list.
    associatedInstanceNum Integer
    The number of instance that associated to allow list.
    associatedInstances List<AllowListAssociatedInstance>
    Instances associated by this allow list.
    id String
    The provider-assigned unique ID for this managed resource.
    allowListId string
    Id of allow list.
    allowListIpNum number
    The IP number of allow list.
    allowListType string
    Type of allow list.
    associatedInstanceNum number
    The number of instance that associated to allow list.
    associatedInstances AllowListAssociatedInstance[]
    Instances associated by this allow list.
    id string
    The provider-assigned unique ID for this managed resource.
    allow_list_id str
    Id of allow list.
    allow_list_ip_num int
    The IP number of allow list.
    allow_list_type str
    Type of allow list.
    associated_instance_num int
    The number of instance that associated to allow list.
    associated_instances Sequence[AllowListAssociatedInstance]
    Instances associated by this allow list.
    id str
    The provider-assigned unique ID for this managed resource.
    allowListId String
    Id of allow list.
    allowListIpNum Number
    The IP number of allow list.
    allowListType String
    Type of allow list.
    associatedInstanceNum Number
    The number of instance that associated to allow list.
    associatedInstances List<Property Map>
    Instances associated by this allow list.
    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_desc: Optional[str] = None,
            allow_list_id: Optional[str] = None,
            allow_list_ip_num: Optional[int] = None,
            allow_list_name: Optional[str] = None,
            allow_list_type: Optional[str] = None,
            allow_lists: Optional[Sequence[str]] = None,
            associated_instance_num: Optional[int] = None,
            associated_instances: Optional[Sequence[AllowListAssociatedInstanceArgs]] = None) -> AllowList
    func 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)
    Resource lookup is not supported in YAML
    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.
    The following state arguments are supported:
    AllowListDesc string
    Description of allow list.
    AllowListId string
    Id of allow list.
    AllowListIpNum int
    The IP number of allow list.
    AllowListName string
    Name of allow list.
    AllowListType string
    Type of allow list.
    AllowLists List<string>
    Ip list of allow list.
    AssociatedInstanceNum int
    The number of instance that associated to allow list.
    AssociatedInstances List<AllowListAssociatedInstance>
    Instances associated by this allow list.
    AllowListDesc string
    Description of allow list.
    AllowListId string
    Id of allow list.
    AllowListIpNum int
    The IP number of allow list.
    AllowListName string
    Name of allow list.
    AllowListType string
    Type of allow list.
    AllowLists []string
    Ip list of allow list.
    AssociatedInstanceNum int
    The number of instance that associated to allow list.
    AssociatedInstances []AllowListAssociatedInstanceArgs
    Instances associated by this allow list.
    allowListDesc String
    Description of allow list.
    allowListId String
    Id of allow list.
    allowListIpNum Integer
    The IP number of allow list.
    allowListName String
    Name of allow list.
    allowListType String
    Type of allow list.
    allowLists List<String>
    Ip list of allow list.
    associatedInstanceNum Integer
    The number of instance that associated to allow list.
    associatedInstances List<AllowListAssociatedInstance>
    Instances associated by this allow list.
    allowListDesc string
    Description of allow list.
    allowListId string
    Id of allow list.
    allowListIpNum number
    The IP number of allow list.
    allowListName string
    Name of allow list.
    allowListType string
    Type of allow list.
    allowLists string[]
    Ip list of allow list.
    associatedInstanceNum number
    The number of instance that associated to allow list.
    associatedInstances AllowListAssociatedInstance[]
    Instances associated by this allow list.
    allow_list_desc str
    Description of allow list.
    allow_list_id str
    Id of allow list.
    allow_list_ip_num int
    The IP number of allow list.
    allow_list_name str
    Name of allow list.
    allow_list_type str
    Type of allow list.
    allow_lists Sequence[str]
    Ip list of allow list.
    associated_instance_num int
    The number of instance that associated to allow list.
    associated_instances Sequence[AllowListAssociatedInstanceArgs]
    Instances associated by this allow list.
    allowListDesc String
    Description of allow list.
    allowListId String
    Id of allow list.
    allowListIpNum Number
    The IP number of allow list.
    allowListName String
    Name of allow list.
    allowListType String
    Type of allow list.
    allowLists List<String>
    Ip list of allow list.
    associatedInstanceNum Number
    The number of instance that associated to allow list.
    associatedInstances List<Property Map>
    Instances associated by this allow list.

    Supporting Types

    AllowListAssociatedInstance, AllowListAssociatedInstanceArgs

    InstanceId string
    Id of instance.
    InstanceName string
    Name of instance.
    Vpc string
    Id of virtual private cloud.
    InstanceId string
    Id of instance.
    InstanceName string
    Name of instance.
    Vpc string
    Id of virtual private cloud.
    instanceId String
    Id of instance.
    instanceName String
    Name of instance.
    vpc String
    Id of virtual private cloud.
    instanceId string
    Id of instance.
    instanceName string
    Name of instance.
    vpc string
    Id of virtual private cloud.
    instance_id str
    Id of instance.
    instance_name str
    Name of instance.
    vpc str
    Id of virtual private cloud.
    instanceId String
    Id of instance.
    instanceName String
    Name of instance.
    vpc String
    Id of virtual private cloud.

    Import

    Redis AllowList can be imported using the id, e.g.

     $ pulumi import volcengine:redis/allowList:AllowList default acl-cn03wk541s55c376xxxx
    

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

    Package Details

    Repository
    volcengine volcengine/pulumi-volcengine
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the volcengine Terraform Provider.
    volcengine logo
    Volcengine v0.0.24 published on Tuesday, Jun 25, 2024 by Volcengine