On my previous post I wrote on how to create an iOS relase build for ad-hoc distribution. But soon after I created and published a release build for a cliente, I was confronted with an aditional challenge. What if I want to add additional devices to the distribution package?
If you do a small search on the web and forums the news you’ll get is that you have to go through the complete packaging process again and again for each new device.
The news I have is: YOU DON’T!! What you have to do is update the existing mobile provisioning profile with the new device’s ID and distribute it along side with the original application's package.
Here’s a step by step.
The first step is to get the unique identifier of the device
- Connect the device to the computer via USB
- Start iTunes
- In iTunes select, in the right column, the device
- On the Summary tab press on the text of Serial Number
- After pressing the text displays the identifier (UDID)
- Press Ctrl + C (Windows) Cmd + C (Mac)
- Go to https://developer.apple.com/membercenter and log in
- Press iOS Provision Portal
- On the left column select Devices
- At right press the Add Devices button
- In Device Name field assign a intuitive name to the device.
- Fill the the device’s ID field with UDID you copied earlier
- If you need to add more equipment press the + button to the right
- At the end press Submit and the new equipment is added
- In the left column press Provisioning
- Select the Distribution tab
- In the row that corresponds to the distribution license press Edit on the right and then select Modify
- In the Devices Section you should see the newly added. Select it, and all the devices you wish to assign to the license
- Submit Press when finished
- After you press Submit the license status may be in Process. If this happens press the F5 key to refresh the page. The status should switch to Active.
- Press the Download button to download the license file. The file name is [LicenceFileName].mobileprovision
There are two ways you can send the application and licence files to your users.
- One is by email. Then the user can install both files with iTunes. First the licence file and then synchronize the application file.
- The other way is to publish both files on a web server just like on this previous post.
In order to go with the second option, follow these steps.
- Go to this previous post and follow the same last steps on how to configure the webpage
- Then on the index.html file you must add also a link to the licence. The complete code is as follows
<body style="height: 100%;">
- You also must add a new MIME type for the licence file
This web page will have two links. One for the licence file and the other for the application installation package.
The application package is the same that was generated on this previous post.
Installing the application in new devices
To install the application, you must first install the licence and then the application. Send the link of the webpage by email.
- To install the licence you must click on the Download Licence link
- Install the licence clicking on Install
- After the licence is installed. Press OK.
note: If when downloading the certificate an error message appears, this can mean that the device is not authorized to use this application, that is, the UDID of this device is not associated with the licence
- Return to the web page and click Download Application. This will initiate the download and installation of the application.
And you’re done. If you need to add more devices, just repeat the process. At the end, on the webpage, replace only the licence file (.mobileprovisioning file).