Ruby   发布时间:2022-04-03  发布网站:大佬教程  code.js-code.com
大佬教程收集整理的这篇文章主要介绍了ruby-on-rails – Capistrano gzip:stdin:意外结束文件中断大佬教程大佬觉得挺不错的,现在分享给大家,也给大家做个参考。
我有Capistrano部署的问题.部署过程正在被丢弃,并出现Gzip错误.

它能是什么?

cap flow deploy 

* execuTing `flow' 
* execuTing `deploy' 
* execuTing `deploy:update' 
** transaction: start 
* execuTing `deploy:update_code' 
* getTing (via checkout) 
revision to /tmp/20111214204507 
execuTing locally: cp -R . /tmp/20111214204507 
c    ommand finished in 413ms 
compressing /tmp/20111214204507 to /tmp/20111214204507.tar.gz 
execuTing locally: tar chzf 20111214204507.tar.gz 20111214204507 
command finished in 2419ms 
servers: ["10.11.10.10"] 
password: ** sftp upload /tmp/20111214204507.tar.gz -> /tmp/20111214204507.tar.gz 
[10.11.10.10] /tmp/20111214204507.tar.gz 
[10.11.10.10] done * sftp upload complete * execuTing "cd /home/tieto/dvs_production/releases && tar xzf /tmp/20111214204507.tar.gz && rm /tmp/20111214204507.tar.gz" 
servers: ["10.11.10.10"] 
[10.11.10.10] execuTing command 
[err :: 10.11.10.10] 
[err :: 10.11.10.10] gzip: 
[err :: 10.11.10.10] stdin: unexpected end of file 
[err :: 10.11.10.10] tar: 
[err :: 10.11.10.10] Child returned status 1 
[err :: 10.11.10.10] 
[err :: 10.11.10.10] tar: 
[err :: 10.11.10.10] Error exit delayed from previous errors 
[err :: 10.11.10.10] 
command finished in 62ms 
[deploy:update_code] rolling BACk * execuTing "rm -rf /home/flow/production/releases/20111214204507; true" 
servers: ["10.11.10.10"] 
[10.11.10.10] execuTing command 
command finished in 69ms 
failed: "sh -c 'cd /home/flow/production/releases && tar xzf /tmp/20111214204507.tar.gz && rm /tmp/20111214204507.tar.gz'" on 10.11.10.10

解决方法

答案在这里,如果您或其他人尝试本地部署仍然遇到此问题:
http://f3internet.com/articles/2010/06/18/deploying-static-sites-with-capistrano/

这行[10.11.10.10]完成了* sftp上传完成*执行“cd / home / tieto / dvs_production / releases&& tar xzf /tmp/20111214204507.tar.gz>& rm /tmp/20111214204507.tar. gz“正试图同时解压缩并删除临时副本.

解决方案是在同一台机器上定义本地/远程复制目录:

set :copy_dir,"/home/#{local_user}/tmp"
set :remote_copy_dir,"/tmp"

大佬总结

以上是大佬教程为你收集整理的ruby-on-rails – Capistrano gzip:stdin:意外结束文件中断全部内容,希望文章能够帮你解决ruby-on-rails – Capistrano gzip:stdin:意外结束文件中断所遇到的程序开发问题。

如果觉得大佬教程网站内容还不错,欢迎将大佬教程推荐给程序员好友。

本图文内容来源于网友网络收集整理提供,作为学习参考使用,版权属于原作者。
如您有任何意见或建议可联系处理。小编QQ:384754419,请注明来意。