https://pulumi.com logo
#azure
Title
# azure
g

gray-baker-98982

03/08/2023, 11:55 AM
Trying to create a certificate using Azure Classic, but can't get my code to compile policy is an object created from CertificateCertificatePolicyArgs. Have also tried wrapping it in an Output.Create Cannot implicitly convert type 'Pulumi.Output<Pulumi.Azure.KeyVault.Inputs.CertificateCertificatePolicyArgs>' to 'Pulumi.Input<Pulumi.Azure.KeyVault.Inputs.CertifiateCertificatePolicyArgs>' I'm using the C# .NET SDK
Copy code
var certificate = new Certifiate($"cer-{platform}-sp-{stackName}", new CertifiateArgs
        {
            KeyVaultId = vault.Id,
            CertificatePolicy = policy
        });
e

echoing-dinner-19531

03/09/2023, 7:40 PM
There is an implicit conversion defined for that, so not sure why it's not being invoked but try adding an explicit cast
(Pulumi.Input<Pulumi.Azure.KeyVault.Inputs.CertifiateCertificatePolicyArgs>)policy
and see if that works?
6 Views