AWS CloudFormation
User Guide (Version )

The AWS Documentation website is getting a new look!
Try it now and let us know what you think. Switch to the new look >>

You can return to the original look by selecting English in the language selector above.

AWS::CertificateManager::Certificate

The AWS::CertificateManager::Certificate resource requests an AWS Certificate Manager (ACM) certificate that you can use to enable secure connections. For example, you can deploy an ACM certificate to an Elastic Load Balancer to enable HTTPS support. For more information, see RequestCertificate in the AWS Certificate Manager API Reference.

Important

When you use the AWS::CertificateManager::Certificate resource in an AWS CloudFormation stack, the stack will remain in the CREATE_IN_PROGRESS state. Further stack operations will be delayed until you validate the certificate request, either by acting upon the instructions in the validation email, or by adding a CNAME record to your DNS configuration. For more information, see Use Email to Validate Domain Ownership and Use DNS to Validate Domain Ownership.

Syntax

To declare this entity in your AWS CloudFormation template, use the following syntax:

JSON

{ "Type" : "AWS::CertificateManager::Certificate", "Properties" : { "DomainName" : String, "DomainValidationOptions" : [ DomainValidationOption, ... ], "SubjectAlternativeNames" : [ String, ... ], "Tags" : [ Tag, ... ], "ValidationMethod" : String } }

YAML

Type: AWS::CertificateManager::Certificate Properties: DomainName: String DomainValidationOptions: - DomainValidationOption SubjectAlternativeNames: - String Tags: - Tag ValidationMethod: String

Properties

DomainName

The fully qualified domain name (FQDN), such as www.example.com, with which you want to secure an ACM certificate. Use an asterisk (*) to create a wildcard certificate that protects several sites in the same domain. For example, *.example.com protects www.example.com, site.example.com, and images.example.com.

Required: Yes

Type: String

Minimum: 1

Maximum: 253

Pattern: ^(\*\.)?(((?!-)[A-Za-z0-9-]{0,62}[A-Za-z0-9])\.)+((?!-)[A-Za-z0-9-]{1,62}[A-Za-z0-9])$

Update requires: Replacement

DomainValidationOptions

Domain information that domain name registrars use to verify your identity.

Required: No

Type: List of DomainValidationOption

Maximum: 100

Update requires: Replacement

SubjectAlternativeNames

Additional FQDNs to be included in the Subject Alternative Name extension of the ACM certificate. For example, you can add www.example.net to a certificate for which the DomainName field is www.example.com if users can reach your site by using either name.

Required: No

Type: List of String

Maximum: 100

Update requires: Replacement

Tags

Key-value pairs that can identity the certificate.

Required: No

Type: List of Tag

Maximum: 50

Update requires: No interruption

ValidationMethod

The method you want to use to validate that you own or control the domain associated with a public certificate. You can validate with DNS or validate with email. We recommend that you use DNS validation.

Required: No

Type: String

Allowed Values: DNS | EMAIL

Update requires: Replacement

Return Values

Ref

When you pass the logical ID of this resource to the intrinsic Ref function, Ref returns the certificate's Amazon Resource Name (ARN).

For more information about using the Ref function, see Ref.

Examples

Declaring an Amazon Certificate Manager Certificate Resource

The following example shows how to declare an AWS::CertificateManager::Certificate resource to create an ACM certificate.

JSON

"mycert" : { "Type" : "AWS::CertificateManager::Certificate", "Properties" : { "DomainName" : "example.com", "DomainValidationOptions" : [{ "DomainName" : "example.com", "ValidationDomain" : "example.com" }] } }

YAML

mycert: Type: AWS::CertificateManager::Certificate Properties: DomainName: example.com DomainValidationOptions: - DomainName: example.com ValidationDomain: example.com ```