iOS code signing - troubleshooting
GitHub

iOS code signing - troubleshooting

To make iOS code signing work on Bitrise, you generally need three things:

To get your code signing files, you can:

If you suspect an error is related to code signing, there is almost certainly a problem with one of these three. When trying to build an iOS app on Bitrise, we strongly recommend generating an .ipa file of the app locally, on your own machine first. If that fails, the build will certainly fail on Bitrise, too.

Let’s look into what you can do to make sure code signing works!

The Xcode Archive & Export for iOS Step fails with the error message Code signing error

Most of the time, this error means your project is missing either the correct .p12 certificate file or the correct provisioning profile - or the Select method for export input of the Step is set incorrectly. Here’s what you can do:

The iOS Auto Provision Step fails

The iOS Auto Provision Step manages your provisioning profiles for you: it downloads the profiles from the Apple Developer portal and installs them for you. Here’s what you can do if this Step fails:

I uploaded a Distribution certificate and an App Store type provisioning profile but I cannot deploy to the App Store because of a code signing error!

To export an .ipa file with the app-store or ad-hoc export methods, you also need to upload a Development certificate and Development type provisioning profile, as the first step of the .ipa export process uses that to generate an .xcodearchive file.

I have added the Run Cocoapods Install Step and now my builds are failing

Installing dependencies can result in a failed build for many reasons. When it comes to iOS code signing, problems can occur if you use the iOS Auto Provision Step. In practice, this means that in your Bitrise workflow, Steps that install dependencies - such as Run Cocoapods Install or Carthage - should be BEFORE the iOS Auto Provision Step.