I have been working on this for days. I have a project in DevOps that I am trying to build. Part of my the build process tries to install the SSL certificate (DigiCert.pfx). This worked fine with the old certificate but we recently updated it and now it doesnt work. So I know the process is correct. Something else must be wrong.
The script being used is
$password = ConvertTo-SecureString "$(CertificatePassword)" -asplaintext -force
Import-PfxCertificate -FilePath $(CertificateFilename) -CertStoreLocation cert:\CurrentUser\My -Password $password
When executed I get
I have updated the project file in Visual Studio with the new SSL certificate and pushed the project file and the new DigiCert.pfx file up to DevOps. I have read a bunch of articles but none that really help. Any help would be appreciated.