The jenkins was started before the login of the user so the jenkins didn't have access to the user's keychain. The fix was to start the jenkins with the user login.
xcodebuild returning code sign error
-
30-06-2022 - |
Question
Check dependencies Code Sign error: The identity 'iPhone Distribution: XXX' doesn't match any valid, non-expired certificate/private key pair in your keychains
This is the constant message that I'm getting from the xcodebuild command. From Xcode, I have no trouble building the application with the same code sign and scheme.
I have tried:
- Fresh installing the command line tools
- Trying with fresh provisioning profile, certificate and key
- Locking, unlocking, setting timers, removing timers from the keychains
and many many more
The weird thing is that on another Mac with the same profile, certificate, key, command line tools, Xcode version, and keychain configuration, the xcodebuild command works as expected.
Solution
OTHER TIPS
Check out your provisioning profile *bundle id* is match with your app bundle identifier. two of them is always same. and then you need to set the code sign identity.
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow