Reputation: 13
My environment is:
OSX 10.11 El Capitan
Unity3D 5.3.4f1
Xcode 7.3
Jenkins 1.642.4
The Xcode
project file generated by Unity3D
build process.
I import Developer & Team certificate to jenkins user's login.keychain
/Users/Share/Jenkins/Library/Keychains/login.keychain
Also copy all Provisioning Profiles to
/Users/Share/Jenkins/Library/MobileDevice/Provisioning Profiles
Build is running fine. And then run
/usr/bin/codesign return exit code 1
I tried many way to fix this.
But is not work yet.
I logged in as jenkins user.
And try to build xcode project
The codesign is build success.
I have no idea to figure out this problem.
Could anyone help me to solve this?
Thanks
sudo su - jenkins
xcodebuild
is also failed on codesign
.
Screenshot
Build as sudo su - jenkins
Change user to jenkins to build
Jenkins web console output
Only 2 links allow, so here is the address https://i.sstatic.net/dYFOW.png
Maybe the codesign issue could like execute codesign via ssh remote build.
Does any idea to solve this?
I tried ssh.
after security unlock keychain.
It's passed.
Directly run /usr/bin/codesign --force --sign ...
pass
But execute xcodebuild
still failed on codesign...
security set-keychain-settings -t 3600 -l ~/Library/Keychains/login.keychain
I added this to build step. It was passed built on jenkins.
So the problem maybe is TIMEOUT
God... It's stuck me TWO DAYS...
Thanks everyone.
Have good day
Upvotes: 1
Views: 2698
Reputation: 125245
1. Got to Xcode -> Preferences -> Accounts -> Choose your account, and then View Details -> refresh the Provisioning Profile. If the refresh button is missing then click on Download All button then restart XCode.
EDIT:
After looking at the picture you posted, I noticed an error before the error you posted. It says "“User interaction is not allowed". So try the following below.
2. KeyChain may be locked: Keychain Access -> Keychain First Aid -> Repair
OR do it by code: https://stackoverflow.com/a/21327591/3785314
3. It could be a timeout issue when building. Try
security set-keychain-settings -t 3600 -l ~/Library/Keychains/login.keychain
4. Login your build user via the GUI and open Keychain Access. Select your signing private key, right-click, choose Get Info, change to the Access Control tab and select the "Allow all applications to access this item".
"User interaction is not allowed" trying to sign an OSX app using codesign
Upvotes: 1