In a CI script to build desktop app running on windows, we have an avaloniaUI app packaged by a .wapproj project, we can build it fine locally using a self-signed certificate, but the USB key containing the EV certificate is located on a remote physical server.
In the CI script, I build/package it like so:
msbuild -t:restore
msbuild /p:Configuration=Release /p:RuntimeIdentifier=win-x64 /p:AppxBundle=Always /p:AppxBundlePlatforms="x64" /p:Platform=x64 /p:UapAppxPackageBuildMode=SideloadOnly
Now, I want to specify a signing certificate via the CLI command OR prompt me to select one from windows GUI, and I want it to prompt me for security PIN in order to sign the app. (As said above, the key is connected via USB).
Right now I get this error:
C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VisualStudio\v17.0\AppxPackage\Microsoft.AppXPackage.Targets(4790,5): error APPX0101: A signing key is required in order to package this project. Please specify a PackageCertificateKeyFile or PackageCertificateThumbprint value in the project file.