Jenkins Build Failed : Xcode couldn't find a provisioning profile matching

冷暖自知 提交于 2020-01-03 03:57:24

问题


I have Jenkins Master running on Aws instance of Ubuntu and created mac laptop as slave , when I ran using Xcode in mac loptop build is successful but when I trigger it from Jenkins it's giving.

     error : 

        Check dependencies : No profiles for 'com.xyz.abc' were found: Xcode couldn't find a provisioning profile matching 'com.xyz.abc'. Code signing is required for product type 'Application' in SDK 'iOS 10.2' 

* ARCHIVE FAILED * The following build commands failed: Check dependencies (1 failure) Build step 'Xcode' marked build as failure.

Ps :

I have already tried to read previous post but most of them were having Jenkins running on MAC, also xcode is running on same server which is not my case.

As I am able to run my project in xcode I feel that my code signing & provisioning profile are correct. Furthermore now I am able to create IPA using Xcode option :

Product --> Archive in Xcode in Mac Laptop

Then why jenkins is not able to create ipa ?

I also have moved all keys in login.keychain to system.keychain

I have connected jenkins master(ubuntu) to slave(mac) using java slave-agent.jnlp

Jenkins Console Output :

=========================================================== == Available provisioning profiles [ios] $ /usr/bin/security find-identity -p codesigning -v

27) XXXXX "Mac Developer: Ashish Karpe (YYYYY)"

Which is similar as in xcode in mac laptop so I am not able to figure out what is wrong her !


回答1:


At last I got the solution and now I can saw we can build IPA from Jenkins Master (Ubuntu AWS instance) using MAC laptop as slave.

My mistake was there were too many provisioning profiles created. I Xcode on Mac laptop when I used one profile (10 digit Development Team ID) which was working properly so I used same on Jenkins side but it failed !

Furthermore Jenkins showed all the detected profiles when I configured Provisioning profiles on Jenkins master and tried with another 10 digit Development Team ID which worked for me.

All together now I am able to create IPA using Jenkins build but I am not sure why my profile which worked in Xcode worked but didn't worked in Jenkins.

Since, my task is done to marking it here as Answer so in case someone else face similar issues, he can try with 10 digit Development Team ID to get it working !

Hope so this helps someone as I was frustrated a lot and had started hating IOS Deployment !



来源:https://stackoverflow.com/questions/46580092/jenkins-build-failed-xcode-couldnt-find-a-provisioning-profile-matching

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!