Electron builder azure devops pipeline code signing certificate
Hello,
I have an issue when i run this command as an azure devops task : npm run build on my Electron JS desktop application, when i put my certificate in the Root store i get this error : SignTool Error: No certificates were found that met all the given criteria.
When i install the certificate in the MY store i get this error : Build failed: Error: Cannot find certificate CampanyName, all certs.
Electron builder generate this command :
C:\WINDOWS\ServiceProfiles\NetworkService\AppData\Local\electron-builder\Cache\winCodeSign\winCodeSign-2.6.0\windows-10\x64\signtool.exe sign /f yourcertificatefilename.pfx /p "PFXfilepassword” /tr [http://timestamp.sectigo.com] /td sha256 /fd sha256 "C:\path\to[FileToSign.exe"](http://filetosign.exe%22/)
When i try to run this command in the server it works, but in azure devops task it s not.
also the npm run build in my local works as well.
could anyone help me for this devops azure step ?
In my electron-builder config, i have this code :
win: {
icon: 'images/convert.ico', // Path to the ICO file for Windows
publisherName: 'Sectigo Public Code Signing CA R36',
certificateSubjectName: 'Campany name',
certificateFile: 'Security/certificate.pfx',
certificatePassword: p.certificatePassword,
certificateSha1: p.certificateSha1,
},