Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

xcodebuild / Jenkins can't find the PROVISIONING_PROFILE for an iOS job

I can build with Jenkins/xcodebuild when the project has the correct Provisioning Profile selected.

We want to be able to set the provisioning profile in xcodebuild.

Unfortunately, when the jenkins user runs

xcodebuild PROVISIONING_PROFILE="XXX"

...Lots of build output...

Check dependencies

Code Sign error: Provisioning profile 'XXX' can't be found

I can run the same line and have it work with a regular user account, accessing the file in ~/Library/MobileDevice/Provisioning Profiles/

The provisioning profiles are stored in /Users/Shared/Jenkins/LibraryMobileDevice/Provisioning Profiles

Anyone know where else the Jenkins user would be looking for these?

like image 407
Luke Avatar asked Nov 04 '22 09:11

Luke


1 Answers

To answer this question: the provisioning profiles must be named after the UUID.

If you download and do not rename a .mobileprovision file, it will not be read by xcodebuild

A script for doing so is in another StackOverflow answer

like image 188
Luke Avatar answered Nov 08 '22 18:11

Luke