Azure App Service (Web Apps) Certificate Order
This page shows how to write Terraform and Azure Resource Manager for App Service (Web Apps) Certificate Order and write them securely.
azurerm_app_service_certificate_order (Terraform)
The Certificate Order in App Service (Web Apps) can be configured in Terraform with the resource name azurerm_app_service_certificate_order
. The following sections describe 4 examples of how to use the resource and its parameters.
Example Usage from GitHub
resource "azurerm_app_service_certificate_order" "standard_cert" {
name = "example-cert-order"
resource_group_name = "fake"
location = "global"
distinguished_name = "CN=example.com"
}
resource "azurerm_app_service_certificate_order" "standard_cert" {
name = "example-cert-order"
resource_group_name = "fake"
location = "global"
distinguished_name = "CN=example.com"
}
resource "azurerm_app_service_certificate_order" "example3" {
name = "example-cert-order"
resource_group_name = azurerm_resource_group.example.name
location = "global"
distinguished_name = "CN=example.com"
product_type = "Standard"
resource "azurerm_app_service_certificate_order" "this" {
auto_renew = var.auto_renew
csr = var.csr
distinguished_name = var.distinguished_name
key_size = var.key_size
location = var.location
Parameters
-
app_service_certificate_not_renewable_reasons
optional computed - list of string -
auto_renew
optional - bool -
certificates
optional computed - list of object-
certificate_name
- string -
key_vault_id
- string -
key_vault_secret_name
- string -
provisioning_state
- string
-
-
csr
optional computed - string -
distinguished_name
optional computed - string -
domain_verification_token
optional computed - string -
expiration_time
optional computed - string -
id
optional computed - string -
intermediate_thumbprint
optional computed - string -
is_private_key_external
optional computed - bool -
key_size
optional - number -
location
required - string -
name
required - string -
product_type
optional - string -
resource_group_name
required - string -
root_thumbprint
optional computed - string -
signed_certificate_thumbprint
optional computed - string -
status
optional computed - string -
tags
optional - map from string to string -
validity_in_years
optional - number -
timeouts
single block
Explanation in Terraform Registry
Manages an App Service Certificate Order.
Tips: Best Practices for The Other Azure App Service (Web Apps) Resources
In addition to the azurerm_app_service, Azure App Service (Web Apps) has the other resources that should be configured for security reasons. Please check some examples of those resources and precautions.
azurerm_app_service
Ensure your App Service is accessible via HTTPS only
It is better to configure the App Service to be accessible via HTTPS only. By default, both HTTP and HTTPS are available.
azurerm_function_app
Ensure to enable authentication to prevent anonymous request being accepted
It is better to enable authentication to prevent anonymous requests and ensure all communications in the application are authenticated.
Microsoft.CertificateRegistration/certificateOrders (Azure Resource Manager)
The certificateOrders in Microsoft.CertificateRegistration can be configured in Azure Resource Manager with the resource name Microsoft.CertificateRegistration/certificateOrders
. The following sections describe how to use the resource and its parameters.
Example Usage from GitHub
An example could not be found in GitHub.
Parameters
apiVersion
required - stringkind
optional - stringKind of resource.
location
required - stringResource Location.
name
required - stringName of the certificate order.
properties
requiredautoRenew
optional - boolean<code>true</code> if the certificate should be automatically renewed when it expires; otherwise, <code>false</code>.
certificates
optional - undefinedState of the Key Vault secret.
csr
optional - stringLast CSR that was created for this order.
distinguishedName
optional - stringCertificate distinguished name.
keySize
optional - integerCertificate key size.
productType
required - stringCertificate product type.
validityInYears
optional - integerDuration in years (must be 1).
tags
optional - stringResource tags.
type
required - string
Frequently asked questions
What is Azure App Service (Web Apps) Certificate Order?
Azure App Service (Web Apps) Certificate Order is a resource for App Service (Web Apps) of Microsoft Azure. Settings can be wrote in Terraform.
Where can I find the example code for the Azure App Service (Web Apps) Certificate Order?
For Terraform, the gilyas/infracost, infracost/infracost and tommiefaj/Terraform-12-Project source code examples are useful. See the Terraform Example section for further details.