We recommend using Azure Native.
Manages a Front Door (standard/premium) Secret.
Required Key Vault Permissions
!> Note: You must add an Access Policy to your azure.keyvault.KeyVault for the Microsoft.AzurefrontDoor-Cdn Enterprise Application Object ID.
This can be created by running Az Powershell command like this:
New-AzADServicePrincipal -ApplicationId "00000000-0000-0000-0000-000000000000"
| Object ID | Key Permissions | Secret Permissions | Certificate Permissions |
|---|---|---|---|
Microsoft.Azure.Cdn Object ID | - | Get | - |
| Your Personal AAD Object ID | - | Get and List | Get, List, Purge and Recover |
| Terraform Service Principal | - | Get | Get, Import, Delete and Purge |
-> Note: You only need to add the Access Policy for your personal AAD Object ID if you are planning to view the secrets via the Azure Portal.
Create FrontdoorSecret Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new FrontdoorSecret(name: string, args: FrontdoorSecretArgs, opts?: CustomResourceOptions);@overload
def FrontdoorSecret(resource_name: str,
args: FrontdoorSecretArgs,
opts: Optional[ResourceOptions] = None)
@overload
def FrontdoorSecret(resource_name: str,
opts: Optional[ResourceOptions] = None,
cdn_frontdoor_profile_id: Optional[str] = None,
secret: Optional[FrontdoorSecretSecretArgs] = None,
name: Optional[str] = None)func NewFrontdoorSecret(ctx *Context, name string, args FrontdoorSecretArgs, opts ...ResourceOption) (*FrontdoorSecret, error)public FrontdoorSecret(string name, FrontdoorSecretArgs args, CustomResourceOptions? opts = null)
public FrontdoorSecret(String name, FrontdoorSecretArgs args)
public FrontdoorSecret(String name, FrontdoorSecretArgs args, CustomResourceOptions options)
type: azure:cdn:FrontdoorSecret
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args FrontdoorSecretArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args FrontdoorSecretArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args FrontdoorSecretArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args FrontdoorSecretArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args FrontdoorSecretArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var frontdoorSecretResource = new Azure.Cdn.FrontdoorSecret("frontdoorSecretResource", new()
{
CdnFrontdoorProfileId = "string",
Secret = new Azure.Cdn.Inputs.FrontdoorSecretSecretArgs
{
CustomerCertificates = new[]
{
new Azure.Cdn.Inputs.FrontdoorSecretSecretCustomerCertificateArgs
{
KeyVaultCertificateId = "string",
SubjectAlternativeNames = new[]
{
"string",
},
},
},
},
Name = "string",
});
example, err := cdn.NewFrontdoorSecret(ctx, "frontdoorSecretResource", &cdn.FrontdoorSecretArgs{
CdnFrontdoorProfileId: pulumi.String("string"),
Secret: &cdn.FrontdoorSecretSecretArgs{
CustomerCertificates: cdn.FrontdoorSecretSecretCustomerCertificateArray{
&cdn.FrontdoorSecretSecretCustomerCertificateArgs{
KeyVaultCertificateId: pulumi.String("string"),
SubjectAlternativeNames: pulumi.StringArray{
pulumi.String("string"),
},
},
},
},
Name: pulumi.String("string"),
})
var frontdoorSecretResource = new FrontdoorSecret("frontdoorSecretResource", FrontdoorSecretArgs.builder()
.cdnFrontdoorProfileId("string")
.secret(FrontdoorSecretSecretArgs.builder()
.customerCertificates(FrontdoorSecretSecretCustomerCertificateArgs.builder()
.keyVaultCertificateId("string")
.subjectAlternativeNames("string")
.build())
.build())
.name("string")
.build());
frontdoor_secret_resource = azure.cdn.FrontdoorSecret("frontdoorSecretResource",
cdn_frontdoor_profile_id="string",
secret={
"customer_certificates": [{
"key_vault_certificate_id": "string",
"subject_alternative_names": ["string"],
}],
},
name="string")
const frontdoorSecretResource = new azure.cdn.FrontdoorSecret("frontdoorSecretResource", {
cdnFrontdoorProfileId: "string",
secret: {
customerCertificates: [{
keyVaultCertificateId: "string",
subjectAlternativeNames: ["string"],
}],
},
name: "string",
});
type: azure:cdn:FrontdoorSecret
properties:
cdnFrontdoorProfileId: string
name: string
secret:
customerCertificates:
- keyVaultCertificateId: string
subjectAlternativeNames:
- string
FrontdoorSecret Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The FrontdoorSecret resource accepts the following input properties:
- Cdn
Frontdoor stringProfile Id - The Resource ID of the Front Door Profile. Changing this forces a new Front Door Secret to be created.
- Secret
Frontdoor
Secret Secret - A
secretblock as defined below. Changing this forces a new Front Door Secret to be created. - Name string
- The name which should be used for this Front Door Secret. Possible values must start with a letter or a number, only contain letters, numbers and hyphens and have a length of between 2 and 260 characters. Changing this forces a new Front Door Secret to be created.
- Cdn
Frontdoor stringProfile Id - The Resource ID of the Front Door Profile. Changing this forces a new Front Door Secret to be created.
- Secret
Frontdoor
Secret Secret Args - A
secretblock as defined below. Changing this forces a new Front Door Secret to be created. - Name string
- The name which should be used for this Front Door Secret. Possible values must start with a letter or a number, only contain letters, numbers and hyphens and have a length of between 2 and 260 characters. Changing this forces a new Front Door Secret to be created.
- cdn
Frontdoor StringProfile Id - The Resource ID of the Front Door Profile. Changing this forces a new Front Door Secret to be created.
- secret
Frontdoor
Secret Secret - A
secretblock as defined below. Changing this forces a new Front Door Secret to be created. - name String
- The name which should be used for this Front Door Secret. Possible values must start with a letter or a number, only contain letters, numbers and hyphens and have a length of between 2 and 260 characters. Changing this forces a new Front Door Secret to be created.
- cdn
Frontdoor stringProfile Id - The Resource ID of the Front Door Profile. Changing this forces a new Front Door Secret to be created.
- secret
Frontdoor
Secret Secret - A
secretblock as defined below. Changing this forces a new Front Door Secret to be created. - name string
- The name which should be used for this Front Door Secret. Possible values must start with a letter or a number, only contain letters, numbers and hyphens and have a length of between 2 and 260 characters. Changing this forces a new Front Door Secret to be created.
- cdn_
frontdoor_ strprofile_ id - The Resource ID of the Front Door Profile. Changing this forces a new Front Door Secret to be created.
- secret
Frontdoor
Secret Secret Args - A
secretblock as defined below. Changing this forces a new Front Door Secret to be created. - name str
- The name which should be used for this Front Door Secret. Possible values must start with a letter or a number, only contain letters, numbers and hyphens and have a length of between 2 and 260 characters. Changing this forces a new Front Door Secret to be created.
- cdn
Frontdoor StringProfile Id - The Resource ID of the Front Door Profile. Changing this forces a new Front Door Secret to be created.
- secret Property Map
- A
secretblock as defined below. Changing this forces a new Front Door Secret to be created. - name String
- The name which should be used for this Front Door Secret. Possible values must start with a letter or a number, only contain letters, numbers and hyphens and have a length of between 2 and 260 characters. Changing this forces a new Front Door Secret to be created.
Outputs
All input properties are implicitly available as output properties. Additionally, the FrontdoorSecret resource produces the following output properties:
- Cdn
Frontdoor stringProfile Name - The name of the Front Door Profile containing this Front Door Secret.
- Id string
- The provider-assigned unique ID for this managed resource.
- Cdn
Frontdoor stringProfile Name - The name of the Front Door Profile containing this Front Door Secret.
- Id string
- The provider-assigned unique ID for this managed resource.
- cdn
Frontdoor StringProfile Name - The name of the Front Door Profile containing this Front Door Secret.
- id String
- The provider-assigned unique ID for this managed resource.
- cdn
Frontdoor stringProfile Name - The name of the Front Door Profile containing this Front Door Secret.
- id string
- The provider-assigned unique ID for this managed resource.
- cdn_
frontdoor_ strprofile_ name - The name of the Front Door Profile containing this Front Door Secret.
- id str
- The provider-assigned unique ID for this managed resource.
- cdn
Frontdoor StringProfile Name - The name of the Front Door Profile containing this Front Door Secret.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing FrontdoorSecret Resource
Get an existing FrontdoorSecret resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: FrontdoorSecretState, opts?: CustomResourceOptions): FrontdoorSecret@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
cdn_frontdoor_profile_id: Optional[str] = None,
cdn_frontdoor_profile_name: Optional[str] = None,
name: Optional[str] = None,
secret: Optional[FrontdoorSecretSecretArgs] = None) -> FrontdoorSecretfunc GetFrontdoorSecret(ctx *Context, name string, id IDInput, state *FrontdoorSecretState, opts ...ResourceOption) (*FrontdoorSecret, error)public static FrontdoorSecret Get(string name, Input<string> id, FrontdoorSecretState? state, CustomResourceOptions? opts = null)public static FrontdoorSecret get(String name, Output<String> id, FrontdoorSecretState state, CustomResourceOptions options)resources: _: type: azure:cdn:FrontdoorSecret get: id: ${id}- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Cdn
Frontdoor stringProfile Id - The Resource ID of the Front Door Profile. Changing this forces a new Front Door Secret to be created.
- Cdn
Frontdoor stringProfile Name - The name of the Front Door Profile containing this Front Door Secret.
- Name string
- The name which should be used for this Front Door Secret. Possible values must start with a letter or a number, only contain letters, numbers and hyphens and have a length of between 2 and 260 characters. Changing this forces a new Front Door Secret to be created.
- Secret
Frontdoor
Secret Secret - A
secretblock as defined below. Changing this forces a new Front Door Secret to be created.
- Cdn
Frontdoor stringProfile Id - The Resource ID of the Front Door Profile. Changing this forces a new Front Door Secret to be created.
- Cdn
Frontdoor stringProfile Name - The name of the Front Door Profile containing this Front Door Secret.
- Name string
- The name which should be used for this Front Door Secret. Possible values must start with a letter or a number, only contain letters, numbers and hyphens and have a length of between 2 and 260 characters. Changing this forces a new Front Door Secret to be created.
- Secret
Frontdoor
Secret Secret Args - A
secretblock as defined below. Changing this forces a new Front Door Secret to be created.
- cdn
Frontdoor StringProfile Id - The Resource ID of the Front Door Profile. Changing this forces a new Front Door Secret to be created.
- cdn
Frontdoor StringProfile Name - The name of the Front Door Profile containing this Front Door Secret.
- name String
- The name which should be used for this Front Door Secret. Possible values must start with a letter or a number, only contain letters, numbers and hyphens and have a length of between 2 and 260 characters. Changing this forces a new Front Door Secret to be created.
- secret
Frontdoor
Secret Secret - A
secretblock as defined below. Changing this forces a new Front Door Secret to be created.
- cdn
Frontdoor stringProfile Id - The Resource ID of the Front Door Profile. Changing this forces a new Front Door Secret to be created.
- cdn
Frontdoor stringProfile Name - The name of the Front Door Profile containing this Front Door Secret.
- name string
- The name which should be used for this Front Door Secret. Possible values must start with a letter or a number, only contain letters, numbers and hyphens and have a length of between 2 and 260 characters. Changing this forces a new Front Door Secret to be created.
- secret
Frontdoor
Secret Secret - A
secretblock as defined below. Changing this forces a new Front Door Secret to be created.
- cdn_
frontdoor_ strprofile_ id - The Resource ID of the Front Door Profile. Changing this forces a new Front Door Secret to be created.
- cdn_
frontdoor_ strprofile_ name - The name of the Front Door Profile containing this Front Door Secret.
- name str
- The name which should be used for this Front Door Secret. Possible values must start with a letter or a number, only contain letters, numbers and hyphens and have a length of between 2 and 260 characters. Changing this forces a new Front Door Secret to be created.
- secret
Frontdoor
Secret Secret Args - A
secretblock as defined below. Changing this forces a new Front Door Secret to be created.
- cdn
Frontdoor StringProfile Id - The Resource ID of the Front Door Profile. Changing this forces a new Front Door Secret to be created.
- cdn
Frontdoor StringProfile Name - The name of the Front Door Profile containing this Front Door Secret.
- name String
- The name which should be used for this Front Door Secret. Possible values must start with a letter or a number, only contain letters, numbers and hyphens and have a length of between 2 and 260 characters. Changing this forces a new Front Door Secret to be created.
- secret Property Map
- A
secretblock as defined below. Changing this forces a new Front Door Secret to be created.
Supporting Types
FrontdoorSecretSecret, FrontdoorSecretSecretArgs
- Customer
Certificates List<FrontdoorSecret Secret Customer Certificate> - A
customer_certificateblock as defined below. Changing this forces a new Front Door Secret to be created.
- Customer
Certificates []FrontdoorSecret Secret Customer Certificate - A
customer_certificateblock as defined below. Changing this forces a new Front Door Secret to be created.
- customer
Certificates List<FrontdoorSecret Secret Customer Certificate> - A
customer_certificateblock as defined below. Changing this forces a new Front Door Secret to be created.
- customer
Certificates FrontdoorSecret Secret Customer Certificate[] - A
customer_certificateblock as defined below. Changing this forces a new Front Door Secret to be created.
- customer_
certificates Sequence[FrontdoorSecret Secret Customer Certificate] - A
customer_certificateblock as defined below. Changing this forces a new Front Door Secret to be created.
- customer
Certificates List<Property Map> - A
customer_certificateblock as defined below. Changing this forces a new Front Door Secret to be created.
FrontdoorSecretSecretCustomerCertificate, FrontdoorSecretSecretCustomerCertificateArgs
- Key
Vault stringCertificate Id The ID of the Key Vault certificate resource to use. Changing this forces a new Front Door Secret to be created.
Note: If you would like to use the latest version of the Key Vault Certificate use the Key Vault Certificates
versionless_idattribute as thekey_vault_certificate_idfields value(e.g.key_vault_certificate_id </span>= azurerm_key_vault_certificate.example.versionless_id).- Subject
Alternative List<string>Names - One or more
subject alternative namescontained within the key vault certificate.
- Key
Vault stringCertificate Id The ID of the Key Vault certificate resource to use. Changing this forces a new Front Door Secret to be created.
Note: If you would like to use the latest version of the Key Vault Certificate use the Key Vault Certificates
versionless_idattribute as thekey_vault_certificate_idfields value(e.g.key_vault_certificate_id </span>= azurerm_key_vault_certificate.example.versionless_id).- Subject
Alternative []stringNames - One or more
subject alternative namescontained within the key vault certificate.
- key
Vault StringCertificate Id The ID of the Key Vault certificate resource to use. Changing this forces a new Front Door Secret to be created.
Note: If you would like to use the latest version of the Key Vault Certificate use the Key Vault Certificates
versionless_idattribute as thekey_vault_certificate_idfields value(e.g.key_vault_certificate_id </span>= azurerm_key_vault_certificate.example.versionless_id).- subject
Alternative List<String>Names - One or more
subject alternative namescontained within the key vault certificate.
- key
Vault stringCertificate Id The ID of the Key Vault certificate resource to use. Changing this forces a new Front Door Secret to be created.
Note: If you would like to use the latest version of the Key Vault Certificate use the Key Vault Certificates
versionless_idattribute as thekey_vault_certificate_idfields value(e.g.key_vault_certificate_id </span>= azurerm_key_vault_certificate.example.versionless_id).- subject
Alternative string[]Names - One or more
subject alternative namescontained within the key vault certificate.
- key_
vault_ strcertificate_ id The ID of the Key Vault certificate resource to use. Changing this forces a new Front Door Secret to be created.
Note: If you would like to use the latest version of the Key Vault Certificate use the Key Vault Certificates
versionless_idattribute as thekey_vault_certificate_idfields value(e.g.key_vault_certificate_id </span>= azurerm_key_vault_certificate.example.versionless_id).- subject_
alternative_ Sequence[str]names - One or more
subject alternative namescontained within the key vault certificate.
- key
Vault StringCertificate Id The ID of the Key Vault certificate resource to use. Changing this forces a new Front Door Secret to be created.
Note: If you would like to use the latest version of the Key Vault Certificate use the Key Vault Certificates
versionless_idattribute as thekey_vault_certificate_idfields value(e.g.key_vault_certificate_id </span>= azurerm_key_vault_certificate.example.versionless_id).- subject
Alternative List<String>Names - One or more
subject alternative namescontained within the key vault certificate.
Import
Front Door Secrets can be imported using the resource id, e.g.
$ pulumi import azure:cdn/frontdoorSecret:FrontdoorSecret example /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/resourceGroup1/providers/Microsoft.Cdn/profiles/profile1/secrets/secrets1
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- Azure Classic pulumi/pulumi-azure
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
azurermTerraform Provider.
