如何通过命令行为 iOS 开发安装开发者证书/私钥和配置文件? [英] How to install developer certificate/private key and provisioning profile for iOS development via command line?
问题描述
我正在为 iOS 应用程序项目配置自动构建服务器.我已经完成了大部分.现在,这是最后一轮.安全.
I'm configuring automated build server for iOS application project. I've done most of it. Now, it's the final round. The security.
开发人员证书/私钥和配置文件可以通过 GUI 轻松安装到钥匙串中.但我想通过命令行来自动化配置过程.通过命令行导出/导入证书、私钥、配置文件.
Developer certificate/private key and provisioning profile can be easily installed into Keychain with GUI. But I want to do this via command line to automate even the configuring process. Exporting/importing certificates, private keys, provisioning profiles via command line.
非常感谢任何建议.
推荐答案
我发现了以下提示:http://lists.apple.com/archives/apple-cdsa/2010/Mar/msg00021.html
命令是security
.我正在阅读手册页.试用后我会更新这个答案:)
The command is security
. I'm reading manual page. I'll update this answer later after trial :)
--(编辑)--
首先,我们必须手动授予对钥匙串中证书/密钥的始终允许"访问权限一次.我不知道如何在没有 GUI 的情况下做到这一点.
First, we have to give 'Always Allow' access to the certificates/keys in the Keychain manually once. I don't know how to do this without GUI.
并在为每个会话运行构建工具之前运行命令 security unlock-keychain
.我使用过 SSH,所以每次登录会话都必须执行一次.
And run the command security unlock-keychain
before running build tool for every session. I've used SSH, so I had to execute it once for every login sessions.
这篇关于如何通过命令行为 iOS 开发安装开发者证书/私钥和配置文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!