Xamarin.iOS Profiling (First Deployment)

    Kartik Parashar

A guide to easy set up your iOS machine for Deployment of your application. There are several steps in iOS to set up and run your application on actual device not simulator. Simulator didn't required any certificate or provisional profiles for the deployment of your application. People find it difficult to search all the steps sequentially on internet. So, this blog will provide you all the essential steps from certificate creation to deployment of your app.

Prerequisites

You will require an Apple Developer Program membershipa MAC machinean iOS device.

Steps to create.CSR file

1: Open your Mac > Go to Keychain Access



2: Right click on Keychain Access > Select Certificate Assistance > Select Request a certificate from a certificate authority.



3: Now fill details like your Email and Common Name then select Save to disk.



4: Press Continue > Give location where you want to save .CSR file.



You have successfully created .CSR file which will be used later to create certificate on developer account.

Steps to create certificate on Developer Account

1: Login into your Developer Account > Go to Certificates, IDs & Profiles.


2: Now add a certificate by clicking on + sign.


3: Select iOS Development for development profile and click continue.


4: Again continue.



5: Now upload your .CSR file that you created in the last step and click continue.



6: Now, you will see a screen which says that your certificate is ready, Download it and double click it to install it in the Keychain.


7: Add it to the keychain.

8: If you want to create a certificate for production than you just have to select App Store and Ad Hoc instead of iOS App Development.



Now you can close Keychain.

Steps to Register Devices

1: On the extreme left side click on Devices > All > Click + sign.

2: Add the device name & UDID of the device on which you want to run your app.


Your device is now registered successfully and now appear in the device list. You can now add more devices by following the same process.

Steps to Create App IDs


1: Every app has its own unique app id. So, you have to create an App ID for your application. On the left side menu, click Identifiers > App IDs > Click + sign


2: Now fill the following information:


3: Now your App ID successfully created.


Steps to Create Provisional Profiles

1: On the left side menu go to Provisional Profiles > Development > Click + sign.


2: Choose iOS Development then click Continue

3: Next step asks you for App ID. Select App ID that you created in previous steps.

 4: Then select your certificate that you created in the previous steps.

 5: Now select the device, this profile is valid for.


6: Now enter the name for the profile and continue.


7: Download the certificate.

8: As, you are already here, create Distribution profile too but you only need Distribution profile when you want to submit your app on the App Store. Just click on Add Another.


9: Next few steps are same as you followed in creation of the development profile.

10: Verify your certificates.


Now you can able to deploy your application on actual device.

Reference : Some of the screen shots are taken from https://www.raywenderlich.com/127936/submit-an-app-part-1 .