Alibaba Cloud

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

getCertificates

This data source provides the Waf Certificates of the current Alibaba Cloud user.

NOTE: Available in v1.135.0+.

Example Usage

using Pulumi;
using AliCloud = Pulumi.AliCloud;

class MyStack : Stack
{
    public MyStack()
    {
        var @default = Output.Create(AliCloud.Waf.GetCertificates.InvokeAsync(new AliCloud.Waf.GetCertificatesArgs
        {
            Ids = 
            {
                "your_certificate_id",
            },
            InstanceId = "your_instance_id",
            Domain = "your_domain_name",
        }));
        this.WafCertificate = @default.Apply(@default => @default.Certificates?[0]);
    }

    [Output("wafCertificate")]
    public Output<string> WafCertificate { get; set; }
}
package main

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

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_default, err := waf.GetCertificates(ctx, &waf.GetCertificatesArgs{
			Ids: []string{
				"your_certificate_id",
			},
			InstanceId: "your_instance_id",
			Domain:     pulumi.StringRef("your_domain_name"),
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("wafCertificate", _default.Certificates[0])
		return nil
	})
}

Coming soon!

import pulumi
import pulumi_alicloud as alicloud

default = alicloud.waf.get_certificates(ids=["your_certificate_id"],
    instance_id="your_instance_id",
    domain="your_domain_name")
pulumi.export("wafCertificate", default.certificates[0])
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";

const default = alicloud.waf.getCertificates({
    ids: ["your_certificate_id"],
    instanceId: "your_instance_id",
    domain: "your_domain_name",
});
export const wafCertificate = _default.then(_default => _default.certificates?[0]);

Coming soon!

Using getCertificates

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 getCertificates(args: GetCertificatesArgs, opts?: InvokeOptions): Promise<GetCertificatesResult>
function getCertificatesOutput(args: GetCertificatesOutputArgs, opts?: InvokeOptions): Output<GetCertificatesResult>
def get_certificates(domain: Optional[str] = None,
                     ids: Optional[Sequence[str]] = None,
                     instance_id: Optional[str] = None,
                     name_regex: Optional[str] = None,
                     output_file: Optional[str] = None,
                     opts: Optional[InvokeOptions] = None) -> GetCertificatesResult
def get_certificates_output(domain: Optional[pulumi.Input[str]] = None,
                     ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
                     instance_id: Optional[pulumi.Input[str]] = None,
                     name_regex: Optional[pulumi.Input[str]] = None,
                     output_file: Optional[pulumi.Input[str]] = None,
                     opts: Optional[InvokeOptions] = None) -> Output[GetCertificatesResult]
func GetCertificates(ctx *Context, args *GetCertificatesArgs, opts ...InvokeOption) (*GetCertificatesResult, error)
func GetCertificatesOutput(ctx *Context, args *GetCertificatesOutputArgs, opts ...InvokeOption) GetCertificatesResultOutput

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

public static class GetCertificates 
{
    public static Task<GetCertificatesResult> InvokeAsync(GetCertificatesArgs args, InvokeOptions? opts = null)
    public static Output<GetCertificatesResult> Invoke(GetCertificatesInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetCertificatesResult> getCertificates(GetCertificatesArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
Fn::Invoke:
  Function: alicloud:waf/getCertificates:getCertificates
  Arguments:
    # Arguments dictionary

The following arguments are supported:

InstanceId string

WAF instance ID.

Domain string

The domain that you want to add to WAF.

Ids List<string>

A list of Certificate IDs.

NameRegex string

A regex string to filter results by Certificate name.

OutputFile string
InstanceId string

WAF instance ID.

Domain string

The domain that you want to add to WAF.

Ids []string

A list of Certificate IDs.

NameRegex string

A regex string to filter results by Certificate name.

OutputFile string
instanceId String

WAF instance ID.

domain String

The domain that you want to add to WAF.

ids List

A list of Certificate IDs.

nameRegex String

A regex string to filter results by Certificate name.

outputFile String
instanceId string

WAF instance ID.

domain string

The domain that you want to add to WAF.

ids string[]

A list of Certificate IDs.

nameRegex string

A regex string to filter results by Certificate name.

outputFile string
instance_id str

WAF instance ID.

domain str

The domain that you want to add to WAF.

ids Sequence[str]

A list of Certificate IDs.

name_regex str

A regex string to filter results by Certificate name.

output_file str
instanceId String

WAF instance ID.

domain String

The domain that you want to add to WAF.

ids List

A list of Certificate IDs.

nameRegex String

A regex string to filter results by Certificate name.

outputFile String

getCertificates Result

The following output properties are available:

Certificates List<Pulumi.AliCloud.Waf.Outputs.GetCertificatesCertificate>
Id string

The provider-assigned unique ID for this managed resource.

Ids List<string>
InstanceId string
Names List<string>
Domain string
NameRegex string
OutputFile string
Certificates []GetCertificatesCertificate
Id string

The provider-assigned unique ID for this managed resource.

Ids []string
InstanceId string
Names []string
Domain string
NameRegex string
OutputFile string
certificates ListCertificatesCertificate>
id String

The provider-assigned unique ID for this managed resource.

ids List
instanceId String
names List
domain String
nameRegex String
outputFile String
certificates GetCertificatesCertificate[]
id string

The provider-assigned unique ID for this managed resource.

ids string[]
instanceId string
names string[]
domain string
nameRegex string
outputFile string
certificates Sequence[GetCertificatesCertificate]
id str

The provider-assigned unique ID for this managed resource.

ids Sequence[str]
instance_id str
names Sequence[str]
domain str
name_regex str
output_file str
certificates List
id String

The provider-assigned unique ID for this managed resource.

ids List
instanceId String
names List
domain String
nameRegex String
outputFile String

Supporting Types

GetCertificatesCertificate

CertificateId string

Certificate recording ID.

CertificateName string

Your certificate name.

CommonName string

Certificate bound to the domain name.

Domain string

The domain that you want to add to WAF.

Id string

The ID of the Certificate.

InstanceId string

WAF instance ID.

IsUsing bool
Sans List<string>
CertificateId string

Certificate recording ID.

CertificateName string

Your certificate name.

CommonName string

Certificate bound to the domain name.

Domain string

The domain that you want to add to WAF.

Id string

The ID of the Certificate.

InstanceId string

WAF instance ID.

IsUsing bool
Sans []string
certificateId String

Certificate recording ID.

certificateName String

Your certificate name.

commonName String

Certificate bound to the domain name.

domain String

The domain that you want to add to WAF.

id String

The ID of the Certificate.

instanceId String

WAF instance ID.

isUsing Boolean
sans List
certificateId string

Certificate recording ID.

certificateName string

Your certificate name.

commonName string

Certificate bound to the domain name.

domain string

The domain that you want to add to WAF.

id string

The ID of the Certificate.

instanceId string

WAF instance ID.

isUsing boolean
sans string[]
certificate_id str

Certificate recording ID.

certificate_name str

Your certificate name.

common_name str

Certificate bound to the domain name.

domain str

The domain that you want to add to WAF.

id str

The ID of the Certificate.

instance_id str

WAF instance ID.

is_using bool
sans Sequence[str]
certificateId String

Certificate recording ID.

certificateName String

Your certificate name.

commonName String

Certificate bound to the domain name.

domain String

The domain that you want to add to WAF.

id String

The ID of the Certificate.

instanceId String

WAF instance ID.

isUsing Boolean
sans List

Package Details

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

This Pulumi package is based on the alicloud Terraform Provider.