2016-02-05 67 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版本
然後再試一次。

相關問題