[TIMOB-9505] iOS: New feature to add ability to choose keychain at codesign
GitHub Issue | n/a |
---|---|
Type | New Feature |
Priority | Medium |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2012-08-03T13:48:50.000+0000 |
Affected Version/s | Release 2.1.0 |
Fix Version/s | Sprint 2012-14 Core, Release 2.1.1, Release 3.0.0 |
Components | iOS |
Labels | SupportTeam, core |
Reporter | Varun Joshi |
Assignee | Neeraj Gupta |
Created | 2012-06-12T14:29:05.000+0000 |
Updated | 2012-08-03T13:48:50.000+0000 |
Description
Currently, even when we set the default keychain to the separate keychain in OS X, codesign will still look at not only the separate keychain but also the default login keychain.
The codesign man pages say that we are allowed to pass an argument with the keychain that we would like to use and codesign will only look at that keychain.
It has been requested to add a new feature to have the ability to select the desired keychain from command line through builder.py.
TESTING
----Create a new Keychain in "Keychain Access" and name it "test". Any password is OK.
Copy your existing 'iPhone Developer' and 'iPhone Distribution' certificates and then Paste (DO NOT DRAG) them into the new keychain. Dragging moves them to the new keychain - pasting puts a reference in it.
*Make sure* that the keychain is "locked" by clicking the lock button in the upper-left if necessary.
Create a new app in TiStudio which you have both developer and distribution/packaging credentials for.
In order to get the correct command-line invokes for your created app, you will want to do the following in Studio:Go to Preferences -> Titanium Studio -> Troubleshooting
Select debug level "All"
Click "Debug specific components"
Uncheck all components EXCEPT for
com.aptana.core/debug/shell
Apply changes
WITHOUT SPECIFIED KEYCHAIN:Build for device in TiStudio
Build for distribution in TiStudio
PASS: App builds WITH SPECIFIED KEYCHAIN: To do this, for now you will need to run the builder.py manually from the command line. Studio does not support keychain selection yet; this is a separate feature request that will be filed with them and then linked from this ticket. In order to get the correct invoke line, you will need to have enabled Studio's shell logging, but the ticket includes templates. You can get you invoke line by:In Studio, go to Help -> Titanium Studio -> View Log File
Find a builder.py invoke for the project (either "install" or "distribute" command). If you performed the last test just before this one, they should be at the bottom of the file.
Now you will want to get your keychain file. In the terminal, runAnd copy the path to your keychain file that you just created. From the console, you will want to run an invoke similar to the following:
If the correct keychain is being used, you should be presented with a dialog box to unlock the "temp" keychain which you created. You will also want to run the "distribute" command in addition to "install", which *does* take different arguments. Check the studio logs again to get the correct invoke.
[PR 2575](https://github.com/appcelerator/titanium_mobile/pull/2575) merged in for 2_1_X branch
Varun to close - email sent
Closing this issue
Should this work with the "adhoc" command as well?
Yes it should work for adhoc command as well.
Yes you're correct Sabil
Reopen to edit spelling error