Xcode 7 Bots Fastlane:如何使用Fastlane的Deliver自动部署一个应用程序到itunes连接

问题:如何使用Deliver从 Xcode 7和Server 4.1上运行的Bot上传IPA到itunesconnect?

我已经能够使用Xcode 6.4,使用机器人的服务器4.1和Deliver(通过fastlane)来建立一个持续的集成解决方案.一旦我升级到Xcode 7 beta-3,我的Bots停止工作.

以下是我为Xcode 6.4做了什么的简要概述:

>在“Bot设置”中选择“执行归档操作”
>从post触发器:echo gem install –user-install deliver #Run安装Gem
>从post触发器:echo export PATH = $PATH:/var/_xcsbuildd/.gem/ruby/2.0.0/bin #Run将宝石添加到路径
>从帖子触发:

echo `DELIVER_PASSWORD="Password"
/var/_xcsbuildd/.gem/ruby/2.0.0/bin/deliver testflight 
"${IPA_PATH}" -a 101233338 -u example@gmail.com --beta`

一切都很好,每次整合后,buildunes都被上传到itunesconnect.

当我升级到Xcode 7时,我无法再通过Deliver上传到itunesconnect.这是我的Xcode 7工作流程:

>测试通行证
档案成功
>帖子触发1:成功构建IPA(使用this apple developer post推荐)

xcrun xcodebuild -exportArchive -archivePath 
 $XCS_ARCHIVE -exportPath $XCS_ARCHIVE
 -exportOptionsPlist /Library/Developer/XcodeServer/ExportOptions.plist 
 -IDEPostProgressNotifications=YES 
 -DVTAllowServerCertificates=YES 
 -DVTSigningCertificateSourceLogLevel=3 
 -DVTSigningCertificateManagerLogLevel=3 
 -DTDKProvisioningProfileExtraSearchPaths=/Library/Developer/XcodeServer/ProvisioningProfiles

>尝试使用交付方式上传IPA:

echo `DELIVER_PASSWORD="Password"
/var/_xcsbuildd/.gem/ruby/2.0.0/bin/deliver testflight 
"${IPA_PATH}" -a 101233338 -u example@gmail.com --beta`

结果:
构建服务问题:终止xcodebuild,因为它没有输出太长时间.

注意:我可以采用机器人制作的IPA,并通过终端上传.

更新

Xcode没有打印所有的日志,当我将输出重定向到一个文件,看起来像Deliver运行很好

ESC[37m[12:03:08]: ESC[0mESC[32mReady to upload new build to TestFlight (CiTest - 1018099468)ESC[0m
ESC[37m[12:03:08]: ESC[0mUploading ipa file to iTunesConnect
ESC[37m[12:03:08]: ESC[0mGoing to upload updated app to iTunesConnect
ESC[37m[12:03:08]: ESC[0mESC[32mThis might take a few minutes,please don't interrupt the scriptESC[0m
ESC[37m[12:03:08]: ESC[0mESC[32mWaiting for iTunes Connect transporter to be finished.ESC[0m
ESC[37m[12:03:08]: ESC[0mESC[32miTunes Transporter progress... this might take a few minutes...ESC[0m

只是xcode服务器在传递完成之前转义该进程.

跟进:有没有人遇到过这样的问题或类似的问题?

解决方法

我从苹果开发者论坛发现了这个线程:
https://forums.developer.apple.com/thread/9812

万一你无法打开它.有人说

It seems that Xcode bot trigger scripts have a 10 second timeout – which is far too short to do any useful work. I can replicate this by adding a “Before Integration” trigger containing nothing but a call to “sleep 10”. When the integration runs,it fails with the error “terminated xcodebuild since it produced no output for too long”.

可能的温度解决方案可能是

make sure you produce some output when your longer running task is running? Not a fix,but might be a workaround.

人们回答说

I have done this and the error no longer occurs. I was using a bash script and needed to echo the output from time to time to workaround this issue.

希望这将有助于此刻.

相关文章

当我们远离最新的 iOS 16 更新版本时,我们听到了困扰 Apple...
欧版/美版 特别说一下,美版选错了 可能会永久丧失4G,不过只...
一般在接外包的时候, 通常第三方需要安装你的app进行测...
前言为了让更多的人永远记住12月13日,各大厂都在这一天将应...