Hello, I found a issue with the docs for for this ...
# general
b
Hello, I found a issue with the docs for for this resource. https://www.pulumi.com/registry/packages/azure-native/api-docs/cdn/secret/#customercertificateparameters
Copy code
az afd secret list --profile-name $PROFILE_NAME --resource-group $RESOURCE_GROUP_NAME
[
  {
    "deploymentStatus": "NotStarted",
    "id": "/subscriptions/{{subscriptionId}}/resourcegroups/{{resourceGroupName}}/providers/Microsoft.Cdn/profiles/{{profileName}}/secrets/{{secretName}}",
    "name": "name",
    "parameters": {
      "certificateAuthority": "CN=DigiCert TLS RSA SHA256 2020 CA1, O=DigiCert Inc, C=US",
      "expirationDate": "2022-05-10T23:59:59+00:00",
      "secretSource": {
        "id": "/subscriptions/{{subscriptionId}}/resourcegroups/{{resourceGroupName}}/providers/Microsoft.KeyVault/vaults/{{keyVaultName}}certificates/{{certificateName}}",
        "resourceGroup": "{{resourceGroupName}}"
      },
      "secretVersion": null,
      "subject": "*.<http://example.com|example.com>",
      "subjectAlternativeNames": [
        "*.<http://example.com|example.com>",
        "<http://example.com|example.com>"
      ],
      "thumbprint": "***",
      "type": "CustomerCertificate",
      "useLatestVersion": true
    },
    "provisioningState": "Succeeded",
    "resourceGroup": "{{resourceGrupName}}",
    "systemData": null,
    "type": "Microsoft.Cdn/profiles/secrets"
  }
]
If you look at
secretSource: { id: string }
when getting the output from the CLI on the secret, you can see it outputs it as
certificates
when comparing against the docs it has
certificate
in the id string for secret source. I am happy to contribute an update, but I am unsure where this needs to be updated at.
g
Are you looking at the example, or are you looking somewhere else on that page? I ask because that part matters to where I point you to 🙂 If you'd rather just open an issue and have us take care of it, there's a link to the left on the docs page called "Request a Change." That takes you to a repo to make the issue so we can take it from there. For this specific API doc, I'm pretty sure it's all generated from the schema itself. There's a couple things that are hand-built, but not many.
b
I am looking at the example provided there in the pulumi docs
Copy code
...
                SecretSource = new AzureNative.Cdn.Inputs.ResourceReferenceArgs
                {
                    Id = "/subscriptions/subid/resourcegroups/RG/providers/Microsoft.KeyVault/vault/kvName/certificate/certName",
                },
...
This section specifically. I found this by pulling the resource from the
az cli
but I have not found its reference in the Microsoft documentation specifically.
g
Gotcha. So that's auto-generated from Microsoft's schema directly: https://github.com/Azure/azure-rest-api-specs/blob/main/specification/cdn/resource[…]er/Microsoft.Cdn/stable/2020-09-01/examples/Secrets_Create.json (it shows up in our repo in this autogenerated file). If you want to open an issue with us, you're welcome to, but you could also open a PR to address it directly on the Azure side, and we'll pull in the change automatically once it merges 🙂
b
TY I will work on submitting this directly to Azure.
👍 1