Alibaba Cloud v3.66.0 published on Friday, Nov 15, 2024 by Pulumi
alicloud.dcdn.getWafDomains
Explore with Pulumi AI
This data source provides the Dcdn Waf Domains of the current Alibaba Cloud user.
NOTE: Available in v1.185.0+.
Example Usage
Basic Usage
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";
const ids = alicloud.dcdn.getWafDomains({});
export const dcdnWafDomainId1 = ids.then(ids => ids.domains?.[0]?.id);
import pulumi
import pulumi_alicloud as alicloud
ids = alicloud.dcdn.get_waf_domains()
pulumi.export("dcdnWafDomainId1", ids.domains[0].id)
package main
import (
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/dcdn"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
ids, err := dcdn.GetWafDomains(ctx, &dcdn.GetWafDomainsArgs{}, nil)
if err != nil {
return err
}
ctx.Export("dcdnWafDomainId1", ids.Domains[0].Id)
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;
return await Deployment.RunAsync(() =>
{
var ids = AliCloud.Dcdn.GetWafDomains.Invoke();
return new Dictionary<string, object?>
{
["dcdnWafDomainId1"] = ids.Apply(getWafDomainsResult => getWafDomainsResult.Domains[0]?.Id),
};
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.dcdn.DcdnFunctions;
import com.pulumi.alicloud.dcdn.inputs.GetWafDomainsArgs;
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 ids = DcdnFunctions.getWafDomains();
ctx.export("dcdnWafDomainId1", ids.applyValue(getWafDomainsResult -> getWafDomainsResult.domains()[0].id()));
}
}
variables:
ids:
fn::invoke:
Function: alicloud:dcdn:getWafDomains
Arguments: {}
outputs:
dcdnWafDomainId1: ${ids.domains[0].id}
Using getWafDomains
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 getWafDomains(args: GetWafDomainsArgs, opts?: InvokeOptions): Promise<GetWafDomainsResult>
function getWafDomainsOutput(args: GetWafDomainsOutputArgs, opts?: InvokeOptions): Output<GetWafDomainsResult>
def get_waf_domains(enable_details: Optional[bool] = None,
ids: Optional[Sequence[str]] = None,
output_file: Optional[str] = None,
query_args: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetWafDomainsResult
def get_waf_domains_output(enable_details: Optional[pulumi.Input[bool]] = None,
ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
output_file: Optional[pulumi.Input[str]] = None,
query_args: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetWafDomainsResult]
func GetWafDomains(ctx *Context, args *GetWafDomainsArgs, opts ...InvokeOption) (*GetWafDomainsResult, error)
func GetWafDomainsOutput(ctx *Context, args *GetWafDomainsOutputArgs, opts ...InvokeOption) GetWafDomainsResultOutput
> Note: This function is named GetWafDomains
in the Go SDK.
public static class GetWafDomains
{
public static Task<GetWafDomainsResult> InvokeAsync(GetWafDomainsArgs args, InvokeOptions? opts = null)
public static Output<GetWafDomainsResult> Invoke(GetWafDomainsInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetWafDomainsResult> getWafDomains(GetWafDomainsArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: alicloud:dcdn/getWafDomains:getWafDomains
arguments:
# arguments dictionary
The following arguments are supported:
- Enable
Details bool - Default to
false
. Set it totrue
can output more details about resource attributes. - Ids List<string>
- A list of Waf Domain IDs.
- Output
File string - File name where to save data source results (after running
pulumi preview
). - Query
Args string - The query conditions. You can filter domain names by name. Fuzzy match is supported
QueryArgs={"DomainName":"Accelerated domain name"}
.
- Enable
Details bool - Default to
false
. Set it totrue
can output more details about resource attributes. - Ids []string
- A list of Waf Domain IDs.
- Output
File string - File name where to save data source results (after running
pulumi preview
). - Query
Args string - The query conditions. You can filter domain names by name. Fuzzy match is supported
QueryArgs={"DomainName":"Accelerated domain name"}
.
- enable
Details Boolean - Default to
false
. Set it totrue
can output more details about resource attributes. - ids List<String>
- A list of Waf Domain IDs.
- output
File String - File name where to save data source results (after running
pulumi preview
). - query
Args String - The query conditions. You can filter domain names by name. Fuzzy match is supported
QueryArgs={"DomainName":"Accelerated domain name"}
.
- enable
Details boolean - Default to
false
. Set it totrue
can output more details about resource attributes. - ids string[]
- A list of Waf Domain IDs.
- output
File string - File name where to save data source results (after running
pulumi preview
). - query
Args string - The query conditions. You can filter domain names by name. Fuzzy match is supported
QueryArgs={"DomainName":"Accelerated domain name"}
.
- enable_
details bool - Default to
false
. Set it totrue
can output more details about resource attributes. - ids Sequence[str]
- A list of Waf Domain IDs.
- output_
file str - File name where to save data source results (after running
pulumi preview
). - query_
args str - The query conditions. You can filter domain names by name. Fuzzy match is supported
QueryArgs={"DomainName":"Accelerated domain name"}
.
- enable
Details Boolean - Default to
false
. Set it totrue
can output more details about resource attributes. - ids List<String>
- A list of Waf Domain IDs.
- output
File String - File name where to save data source results (after running
pulumi preview
). - query
Args String - The query conditions. You can filter domain names by name. Fuzzy match is supported
QueryArgs={"DomainName":"Accelerated domain name"}
.
getWafDomains Result
The following output properties are available:
- Domains
List<Pulumi.
Ali Cloud. Dcdn. Outputs. Get Waf Domains Domain> - Id string
- The provider-assigned unique ID for this managed resource.
- Ids List<string>
- Enable
Details bool - Output
File string - Query
Args string
- Domains
[]Get
Waf Domains Domain - Id string
- The provider-assigned unique ID for this managed resource.
- Ids []string
- Enable
Details bool - Output
File string - Query
Args string
- domains
List<Get
Waf Domains Domain> - id String
- The provider-assigned unique ID for this managed resource.
- ids List<String>
- enable
Details Boolean - output
File String - query
Args String
- domains
Get
Waf Domains Domain[] - id string
- The provider-assigned unique ID for this managed resource.
- ids string[]
- enable
Details boolean - output
File string - query
Args string
- domains
Sequence[Get
Waf Domains Domain] - id str
- The provider-assigned unique ID for this managed resource.
- ids Sequence[str]
- enable_
details bool - output_
file str - query_
args str
- domains List<Property Map>
- id String
- The provider-assigned unique ID for this managed resource.
- ids List<String>
- enable
Details Boolean - output
File String - query
Args String
Supporting Types
GetWafDomainsDomain
- Client
Ip stringTag - The client ip tag.
- Defense
Scenes List<Pulumi.Ali Cloud. Dcdn. Inputs. Get Waf Domains Domain Defense Scene> - Protection policy type.
- Domain
Name string - The accelerated domain name.
- Id string
- The ID of the Waf Domain.
- Client
Ip stringTag - The client ip tag.
- Defense
Scenes []GetWaf Domains Domain Defense Scene - Protection policy type.
- Domain
Name string - The accelerated domain name.
- Id string
- The ID of the Waf Domain.
- client
Ip StringTag - The client ip tag.
- defense
Scenes List<GetWaf Domains Domain Defense Scene> - Protection policy type.
- domain
Name String - The accelerated domain name.
- id String
- The ID of the Waf Domain.
- client
Ip stringTag - The client ip tag.
- defense
Scenes GetWaf Domains Domain Defense Scene[] - Protection policy type.
- domain
Name string - The accelerated domain name.
- id string
- The ID of the Waf Domain.
- client_
ip_ strtag - The client ip tag.
- defense_
scenes Sequence[GetWaf Domains Domain Defense Scene] - Protection policy type.
- domain_
name str - The accelerated domain name.
- id str
- The ID of the Waf Domain.
- client
Ip StringTag - The client ip tag.
- defense
Scenes List<Property Map> - Protection policy type.
- domain
Name String - The accelerated domain name.
- id String
- The ID of the Waf Domain.
GetWafDomainsDomainDefenseScene
- Defense
Scene string - The type of protection policy.
- Policy
Id string - The protection policy ID.
- Defense
Scene string - The type of protection policy.
- Policy
Id string - The protection policy ID.
- defense
Scene String - The type of protection policy.
- policy
Id String - The protection policy ID.
- defense
Scene string - The type of protection policy.
- policy
Id string - The protection policy ID.
- defense_
scene str - The type of protection policy.
- policy_
id str - The protection policy ID.
- defense
Scene String - The type of protection policy.
- policy
Id String - The protection policy ID.
Package Details
- Repository
- Alibaba Cloud pulumi/pulumi-alicloud
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
alicloud
Terraform Provider.