Request a Let's Encrypt certificate
Request a Let's Encrypt certificate for the hostnames of a domain, prepare the challenge records, and check the issuance status.
You can request a Let’s Encrypt™ certificate for the hostnames of a domain from Azion Console or the Azion CLI. To use a certificate you obtained from another certificate authority instead, refer to Upload a digital certificate.
HTTPS on your own hostname needs a server certificate that covers it. With a Let’s Encrypt certificate, Certificate Manager does the certificate work for you. Azion requests the certificate from Let’s Encrypt, completes the challenge that proves you control each hostname, and renews the certificate before it expires. Some older clients cannot validate the chain of a Let’s Encrypt certificate. For which clients, refer to Certificate chain.
Prerequisites
Console
- An application for the domain to serve.
- A domain your account has permission to use, registered in the Domain Name System (DNS).
- Access to the DNS records of the domain, at your DNS provider or in Edge DNS.
- Access to Azion Console. For more information, refer to How to access Azion Console.
Prepare the DNS records for the challenge
Let’s Encrypt issues the certificate only after it validates every hostname on the request. A certificate requested from a domain is issued through the DNS-01 challenge, and the provider that holds the zone decides which DNS record must exist before you send the request:
| With the zone in Edge DNS | With the zone at another provider |
|---|---|
No record. Azion writes the _acme-challenge record into the zone |
One _acme-challenge CNAME record per hostname |
With a zone at another DNS provider, create the _acme-challenge record of each hostname at that provider before you send the request:
| Name | Type | Value |
|---|---|---|
_acme-challenge.<your-domain>, such as _acme-challenge.www.example.com |
CNAME |
<your-domain>.letsencrypt.azion.com, such as www.example.com.letsencrypt.azion.com |
With the zone in Edge DNS, Azion writes the record into the zone and the challenge completes with no action from you. For how the challenge validates a hostname, refer to Domain validation. For records and zones in Edge DNS, refer to Edge DNS guides and tutorials.
Keep the _acme-challenge record for as long as a domain uses the certificate. Azion renews the certificate 30 days before it expires by running the challenge again, and a deleted record makes the renewal fail.
Request the certificate
A Let’s Encrypt request names the main hostname as the common name and, optionally, other hostnames as alternative names. Every name must belong to a domain your account has permission to use.
Console
In Azion Console, you request the certificate from the domain, which takes the hostnames from its CNAME. To request the certificate from a domain in Azion Console:
Access Azion Console > Domains.
Select + Domain, or select an existing domain to edit it.
Enter a name. The name identifies the entry on the account and is not a hostname.
In Applications, select the application the domain serves.
In CNAME, add the fully qualified hostnames the certificate covers. For example: www.example.org.
In Digital Certificate, select the Let’s Encrypt option.
Select Save.
The certificate is issued through the DNS-01 challenge. A hostname whose zone is in Edge DNS is validated without further work. For a zone at another provider, create the _acme-challenge CNAME record the challenge needs. The section Prepare the DNS records for the challenge describes that record.
Bind the certificate to the domain
A certificate you requested with the Azion CLI protects HTTPS traffic only once a domain names it. You select the certificate on each domain. Make sure the certificate covers the hostnames that the domain lists in CNAME, or in cnames in the API.
Console
To bind the certificate to a domain in Azion Console:
Access Azion Console > Domains.
Select the domain. Its edit form opens.
In Digital Certificate, select your certificate.
Select Save.
Azion Console shows “Your domain has been edited”.
The change takes several minutes to reach all of Azion’s distributed infrastructure.
Check the issuance status
Azion makes the first attempt to issue the certificate up to 5 minutes after the request. The status field of the certificate shows where the issuance stands.
Console
To check the status in Azion Console:
Access Azion Console > Certificate Manager.
Find the certificate in the list, with the type TLS Certificate.
A pending certificate shows a warning icon, and a failed one shows an error icon, with the reason as its explanation. A certificate whose validity date has passed carries the tag Expired.
The certificate moves from pending to challenge_verification while the challenge awaits validation, and leaves challenge_verification once Let’s Encrypt issues it. When validation fails, it reads failed, and status_detail names the hostname to check, such as An error has occurred while issuing the requested certificate. Please verify the following domains CNAME: www.example.com.
A failed attempt is retried on a schedule, so a record you correct later can still end in an automatic issuance. For the retry schedule, refer to Issuance time and retries. For a certificate that stays pending or turns failed, refer to Troubleshoot Certificate Manager.