2016-02-05 36 views
0

当我运行EB应用部署,我得到这个错误:部署Rails应用程序,以弹性魔豆不停地进行故障

[email protected]:~/-hidden-$ eb deploy 
WARNING: You have uncommitted changes. 
Creating application version archive "app-9115-160205_135915". 
Uploading -hidden-/app-9115-160205_135915.zip to S3. This may take a while. 
Upload Complete. 
INFO: Environment update is starting.        
INFO: Deploying new version to instance(s).       
ERROR: [Instance: i-024e83b0ed9b09096] Command failed on instance. Return code: 5 Output: (TRUNCATED)...ies/ruby-2.2.3/lib/ruby/gems/2.2.0/extensions/x86_64-linux/2.2.0-static/tiny_tds-0.6.2/gem_make.out 
An error occurred while installing tiny_tds (0.6.2), and Bundler cannot 
continue. 
Make sure that `gem install tiny_tds -v '0.6.2'` succeeds before bundling. 
Hook /opt/elasticbeanstalk/hooks/appdeploy/pre/10_bundle_install.sh failed. For more detail, check /var/log/eb-activity.log using console or EB CLI. 
INFO: Command execution completed on all instances. Summary: [Successful: 0, Failed: 1]. 
ERROR: Unsuccessful command execution on instance id(s) 'i-024e83b0ed9b09096'. Aborting the operation. 
ERROR: Failed to deploy application.         

ERROR: Failed to deploy application. 

我可以在我的本地机器上,并在EC2实例安装成功tiny_tds,但我部署时出现此错误。我对ruby,rails,git和其他编程极其新颖。基本上,我正在为heroku制作一个应用程序,并将其转换为EB环境。

+0

你可以ssh到实例并运行'gem install tiny_tds -v'0.6.2'',这样你就能明白它为什么失败了?我不熟悉这个宝石......它有一个本地扩展或一些依赖,在默认配置中不存在。您也可以下载日志并查找详细的错误消息。如何获取日志:http://docs.aws.amazon.com/elasticbeanstalk/latest/dg/using-features.logging.html –

+0

获取:tiny_tds-0.6.2.gem(100%) 构建原生扩展。这可能需要一段时间... 错误:安装tiny_tds时出错: 错误:无法构建gem本机扩展。 /opt/rubies/ruby-2.2.3/bin/ruby -r ./siteconf20160208-24889-1votup9.rb extconf.rb 检查iconv.h中的iconv_open()...是 检查sybfront.h ...没有 ----- freetds不见了。 ----- *** extconf.rb失败*** 由于某种原因无法创建Makefile,可能缺少必要的 库和/或头文件。检查mkmf.log文件以获取更多详细信息。您可能需要配置选项 。 –

+0

因此,尝试安装本机扩展时失败。您应该ssh到机器并尝试运行gem install tiny_tds。你需要额外的软件包。您可以通过在ec2实例上运行gem install来找到哪些。 –

回答

0

请删除Gemfile中的tiny_tds版本
然后再试一次。

相关问题