带有非登录钥匙串的 CodeSign

CodeSign with non-login keychain

求stack overflow和Google这对双胞胎大神好几个小时了,没用

我有一台专用的构建机器,我正在尝试在其上设置 CI。显然代码签名失败 运行,因为登录钥匙串被锁定。

创建了一个新的钥匙串并将以下内容移至其中:

通过ssh登录到服务器。

运行 xcodebuild 失败并显示 Command CodeSign failed with a nonzero exit code

运行 security unlock-keychain -p XXXXXX /Users/xxx/Library/Keychains/automation.keychain-db

运行 xcodebuild 并且它仍然失败 Command CodeSign failed with a nonzero exit code

运行 security unlock-keychain -p XXXXXX /Users/xxx/Library/Keychains/login.keychain-db

运行 xcodebuild 现在成功通过了。我错过了什么?自动化钥匙串中还有什么不存在的?

您是否已将您的钥匙串添加到搜索列表中?喜欢

security list-keychains -d user -s "$MY_KEYCHAIN" $(security list-keychains -d user | sed s/\"//g)