Alibaba Cloud

Pulumi Official
Package maintained by Pulumi
v3.19.0 published on Friday, Mar 18, 2022 by Pulumi

getAccessGroups

This data source provides the Apsara File Storage for HDFS Access Groups of the current Alibaba Cloud user.

NOTE: Available in v1.133.0+.

Example Usage

using Pulumi;
using AliCloud = Pulumi.AliCloud;

class MyStack : Stack
{
    public MyStack()
    {
        var ids = Output.Create(AliCloud.Dfs.GetAccessGroups.InvokeAsync(new AliCloud.Dfs.GetAccessGroupsArgs
        {
            Ids = 
            {
                "example_id",
            },
        }));
        this.DfsAccessGroupId1 = ids.Apply(ids => ids.Groups?[0]?.Id);
        var nameRegex = Output.Create(AliCloud.Dfs.GetAccessGroups.InvokeAsync(new AliCloud.Dfs.GetAccessGroupsArgs
        {
            NameRegex = "^my-AccessGroup",
        }));
        this.DfsAccessGroupId2 = nameRegex.Apply(nameRegex => nameRegex.Groups?[0]?.Id);
    }

    [Output("dfsAccessGroupId1")]
    public Output<string> DfsAccessGroupId1 { get; set; }
    [Output("dfsAccessGroupId2")]
    public Output<string> DfsAccessGroupId2 { get; set; }
}
package main

import (
	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/dfs"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		ids, err := dfs.GetAccessGroups(ctx, &dfs.GetAccessGroupsArgs{
			Ids: []string{
				"example_id",
			},
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("dfsAccessGroupId1", ids.Groups[0].Id)
		nameRegex, err := dfs.GetAccessGroups(ctx, &dfs.GetAccessGroupsArgs{
			NameRegex: pulumi.StringRef("^my-AccessGroup"),
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("dfsAccessGroupId2", nameRegex.Groups[0].Id)
		return nil
	})
}

Coming soon!

import pulumi
import pulumi_alicloud as alicloud

ids = alicloud.dfs.get_access_groups(ids=["example_id"])
pulumi.export("dfsAccessGroupId1", ids.groups[0].id)
name_regex = alicloud.dfs.get_access_groups(name_regex="^my-AccessGroup")
pulumi.export("dfsAccessGroupId2", name_regex.groups[0].id)
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";

const ids = alicloud.dfs.getAccessGroups({
    ids: ["example_id"],
});
export const dfsAccessGroupId1 = ids.then(ids => ids.groups?[0]?.id);
const nameRegex = alicloud.dfs.getAccessGroups({
    nameRegex: "^my-AccessGroup",
});
export const dfsAccessGroupId2 = nameRegex.then(nameRegex => nameRegex.groups?[0]?.id);

Coming soon!

Using getAccessGroups

Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

function getAccessGroups(args: GetAccessGroupsArgs, opts?: InvokeOptions): Promise<GetAccessGroupsResult>
function getAccessGroupsOutput(args: GetAccessGroupsOutputArgs, opts?: InvokeOptions): Output<GetAccessGroupsResult>
def get_access_groups(ids: Optional[Sequence[str]] = None,
                      limit: Optional[int] = None,
                      name_regex: Optional[str] = None,
                      order_by: Optional[str] = None,
                      order_type: Optional[str] = None,
                      output_file: Optional[str] = None,
                      start_offset: Optional[int] = None,
                      opts: Optional[InvokeOptions] = None) -> GetAccessGroupsResult
def get_access_groups_output(ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
                      limit: Optional[pulumi.Input[int]] = None,
                      name_regex: Optional[pulumi.Input[str]] = None,
                      order_by: Optional[pulumi.Input[str]] = None,
                      order_type: Optional[pulumi.Input[str]] = None,
                      output_file: Optional[pulumi.Input[str]] = None,
                      start_offset: Optional[pulumi.Input[int]] = None,
                      opts: Optional[InvokeOptions] = None) -> Output[GetAccessGroupsResult]
func GetAccessGroups(ctx *Context, args *GetAccessGroupsArgs, opts ...InvokeOption) (*GetAccessGroupsResult, error)
func GetAccessGroupsOutput(ctx *Context, args *GetAccessGroupsOutputArgs, opts ...InvokeOption) GetAccessGroupsResultOutput

> Note: This function is named GetAccessGroups in the Go SDK.

public static class GetAccessGroups 
{
    public static Task<GetAccessGroupsResult> InvokeAsync(GetAccessGroupsArgs args, InvokeOptions? opts = null)
    public static Output<GetAccessGroupsResult> Invoke(GetAccessGroupsInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetAccessGroupsResult> getAccessGroups(GetAccessGroupsArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
Fn::Invoke:
  Function: alicloud:dfs/getAccessGroups:getAccessGroups
  Arguments:
    # Arguments dictionary

The following arguments are supported:

Ids List<string>

A list of Access Group IDs.

Limit int
NameRegex string

A regex string to filter results by Access Group name.

OrderBy string
OrderType string
OutputFile string
StartOffset int
Ids []string

A list of Access Group IDs.

Limit int
NameRegex string

A regex string to filter results by Access Group name.

OrderBy string
OrderType string
OutputFile string
StartOffset int
ids List

A list of Access Group IDs.

limit Integer
nameRegex String

A regex string to filter results by Access Group name.

orderBy String
orderType String
outputFile String
startOffset Integer
ids string[]

A list of Access Group IDs.

limit number
nameRegex string

A regex string to filter results by Access Group name.

orderBy string
orderType string
outputFile string
startOffset number
ids Sequence[str]

A list of Access Group IDs.

limit int
name_regex str

A regex string to filter results by Access Group name.

order_by str
order_type str
output_file str
start_offset int
ids List

A list of Access Group IDs.

limit Number
nameRegex String

A regex string to filter results by Access Group name.

orderBy String
orderType String
outputFile String
startOffset Number

getAccessGroups Result

The following output properties are available:

Groups List<Pulumi.AliCloud.Dfs.Outputs.GetAccessGroupsGroup>
Id string

The provider-assigned unique ID for this managed resource.

Ids List<string>
Names List<string>
Limit int
NameRegex string
OrderBy string
OrderType string
OutputFile string
StartOffset int
Groups []GetAccessGroupsGroup
Id string

The provider-assigned unique ID for this managed resource.

Ids []string
Names []string
Limit int
NameRegex string
OrderBy string
OrderType string
OutputFile string
StartOffset int
groups ListAccessGroupsGroup>
id String

The provider-assigned unique ID for this managed resource.

ids List
names List
limit Integer
nameRegex String
orderBy String
orderType String
outputFile String
startOffset Integer
groups GetAccessGroupsGroup[]
id string

The provider-assigned unique ID for this managed resource.

ids string[]
names string[]
limit number
nameRegex string
orderBy string
orderType string
outputFile string
startOffset number
groups Sequence[GetAccessGroupsGroup]
id str

The provider-assigned unique ID for this managed resource.

ids Sequence[str]
names Sequence[str]
limit int
name_regex str
order_by str
order_type str
output_file str
start_offset int
groups List
id String

The provider-assigned unique ID for this managed resource.

ids List
names List
limit Number
nameRegex String
orderBy String
orderType String
outputFile String
startOffset Number

Supporting Types

GetAccessGroupsGroup

AccessGroupId string

The length of description does not exceed 100 bytes.

AccessGroupName string

The Name of Access Group. The length Of access_group_name does not exceed 100 bytes.

CreateTime string

The CreateTime of Access Group.

Description string

The Description of Access Group. The length Of description does not exceed 100 bytes.

Id string

The ID of the Access Group.

MountPointCount int

The Number of attached mountpoint.

NetworkType string

The NetworkType of Access Group. Valid values: VPC.

RuleCount int

The Number of access rule.

AccessGroupId string

The length of description does not exceed 100 bytes.

AccessGroupName string

The Name of Access Group. The length Of access_group_name does not exceed 100 bytes.

CreateTime string

The CreateTime of Access Group.

Description string

The Description of Access Group. The length Of description does not exceed 100 bytes.

Id string

The ID of the Access Group.

MountPointCount int

The Number of attached mountpoint.

NetworkType string

The NetworkType of Access Group. Valid values: VPC.

RuleCount int

The Number of access rule.

accessGroupId String

The length of description does not exceed 100 bytes.

accessGroupName String

The Name of Access Group. The length Of access_group_name does not exceed 100 bytes.

createTime String

The CreateTime of Access Group.

description String

The Description of Access Group. The length Of description does not exceed 100 bytes.

id String

The ID of the Access Group.

mountPointCount Integer

The Number of attached mountpoint.

networkType String

The NetworkType of Access Group. Valid values: VPC.

ruleCount Integer

The Number of access rule.

accessGroupId string

The length of description does not exceed 100 bytes.

accessGroupName string

The Name of Access Group. The length Of access_group_name does not exceed 100 bytes.

createTime string

The CreateTime of Access Group.

description string

The Description of Access Group. The length Of description does not exceed 100 bytes.

id string

The ID of the Access Group.

mountPointCount number

The Number of attached mountpoint.

networkType string

The NetworkType of Access Group. Valid values: VPC.

ruleCount number

The Number of access rule.

access_group_id str

The length of description does not exceed 100 bytes.

access_group_name str

The Name of Access Group. The length Of access_group_name does not exceed 100 bytes.

create_time str

The CreateTime of Access Group.

description str

The Description of Access Group. The length Of description does not exceed 100 bytes.

id str

The ID of the Access Group.

mount_point_count int

The Number of attached mountpoint.

network_type str

The NetworkType of Access Group. Valid values: VPC.

rule_count int

The Number of access rule.

accessGroupId String

The length of description does not exceed 100 bytes.

accessGroupName String

The Name of Access Group. The length Of access_group_name does not exceed 100 bytes.

createTime String

The CreateTime of Access Group.

description String

The Description of Access Group. The length Of description does not exceed 100 bytes.

id String

The ID of the Access Group.

mountPointCount Number

The Number of attached mountpoint.

networkType String

The NetworkType of Access Group. Valid values: VPC.

ruleCount Number

The Number of access rule.

Package Details

Repository
https://github.com/pulumi/pulumi-alicloud
License
Apache-2.0
Notes

This Pulumi package is based on the alicloud Terraform Provider.