- Home
- Code signing
- iOS code signing
- iOS code signing for Ionic and Cordova projects
iOS code signing for Ionic and Cordova projects
Bitrise supports both manual and automatic provisioning for the iOS code signing of Ionic and Cordova apps as well.
Naturally, Bitrise supports iOS applications built with either Ionic or Cordova. However, the code signing process is slightly different compared to a native Xcode project.
Bitrise supports both manual and automatic provisioning for Ionic and Cordova apps as well - and once again, the processes are somewhat different.
Ionic/Cordova code signing with manual code signing asset management
-
Generate the native Xcode project locally from your Ionic or Cordova project by calling
cordova platform add ios
orionic cordova platform add ios
. -
Upload the files to bitrise.io: open the Project settings page and select Code signing on the left. Upload a certificate and a provisioning profile.
-
Make sure you have the Certificate and profile installer Step in your Workflow.
-
Add the Generate cordova build configuration Step to your Workflow. It must come after the Certificate and profile installer Step.
-
Fill in the required inputs for the Step. Please note that both the Code Signing Identity and the Provisioning Profile are required inputs for iOS apps even though they are not marked as such.
-
Build configuration: you can set it to either
debug
orrelease
. -
Code Sign Identity: enter a Developer or a Distribution identity.
-
Provisioning Profile: enter the appropriate provisioning profile.
-
Packaging Type: this controls what type of build is generated by Xcode. Set the type of code signing you need.
-
-
Add the Cordova archive or the Ionic archive Step to your Workflow.
-
Fill in the required inputs.
-
The Platform input needs to be set to:
device
. -
The Build command configuration input must match the Build configuration input of the Generate cordova build configuration Step.
This Step must come after the Generate cordova build configuration Step in the Workflow.
-
-
Run your build!
Ionic/Cordova code signing with automatic code signing asset management
-
Make sure your .p12 signing certificates are uploaded to bitrise.io.
-
Add the Cordova prepare or the Ionic prepare Step to your Workflow. These Steps call the
platform rm
andplatform add
commands. -
Add the Manage iOS Code Signing Step to your Workflow. If you have both the Certificate and Profile Installer and the Manage iOS Code Signing Steps in your Workflow, your build might encounter unexpected issues.
The Step will export:
-
The project’s development team.
-
The installed codesign identity’s name.
-
The installed provisioning profile.
One code signing Step only
If you have both the Certificate and profile installer and the Manage iOS Code Signing Steps in your Workflow, your build might encounter unexpected issues.
-
-
Select the Apple service connection method (based on the Apple service you have set up in Bitrise) and the Distribution method.
-
Add the Generate cordova build configuration Step to your Workflow.
-
Configure the Step to use the code signing settings exported by the Manage iOS Code Signing Step:
Development distribution example:
- generate-cordova-build-configuration: inputs: - development_team: $BITRISE_DEVELOPER_TEAM - package_type: development - code_sign_identity: iPhone Developer - configuration: debug
Production distribution example:
- generate-cordova-build-configuration: inputs: - development_team: $BITRISE_DEVELOPER_TEAM - package_type: app-store - code_sign_identity: iPhone Developer - configuration: release
-
Add the Cordova Archive or the Ionic Archive Step to your Workflow.
-
Fill in the required inputs.
-
The Platform input needs to be set to:
device
. -
The Build command configuration input must match the Build configuration input of the Generate cordova build configuration Step.
-
-
Set the Should remove platforms as prepare step? to
false
. This is crucial: it ensures the Step will not remove and re-add the platform of the native projects generated in the Cordova prepare or the Ionic prepare Step. -
Run your build!