在构建基于CocoaPods的Xcode工作区时,Jenkins中的权限错误

时间:2014-04-22 01:26:38

标签: ios xcode jenkins cocoapods

我试图设置Jenkins来编译iOS Xcode项目。 xcode项目使用CocoaPods。但是,当我尝试构建时,我在Jenkins中收到此错误。 Pods /目录中的所有文件都具有完全写入/读取/执行权限。有什么想法吗?

/bin/sh -c /Users/Shared/Jenkins/Library/Developer/Xcode/DerivedData/MyApp-dripdwqnufuksvhcfgcgxajaahyq/Build/Intermediates/MyApp.build/Debug-iphonesimulator/MyApp.build/Script-EAAE77068BA044C9B06632CE.sh 

/Users/samy/Work/mobile/iphone/MyApp/Pods/Pods-resources.sh: line 5:     /Users/samy/Work/mobile/iphone/MyApp/Pods/resources-to-copy-MyApp.txt: Permission denied

** BUILD FAILED **

The following build commands failed:

PhaseScriptExecution Copy\ Pods\ Resources /Users/Shared/Jenkins/Library/Developer/Xcode/DerivedData/MyApp-dripdwqnufuksvhcfgcgxajaahyq/Build/Intermediates/MyApp.build/Debug-iphonesimulator/MyApp.build/Script-EAAE77068BA044C9B06632CE.sh

(1 failure)
Build step 'Xcode' marked build as failure
Finished: FAILURE

3 个答案:

答案 0 :(得分:1)

"完全读/写/执行权限"为了谁?哪个用户?詹金斯通常在其自己的用户下运行,称为jenkins

答案 1 :(得分:1)

我遇到的唯一解决方法是将整个Xcode项目移动到jenkins用户目录。

答案 2 :(得分:0)

您可能想要添加自定义构建设置PODS_ROOT

PODS_ROOT=$(PROJECT_DIR)/Pods