第一次混帐aws.push弹性魔豆错误 [英] Error on first git aws.push to elastic beanstalk

查看:188
本文介绍了第一次混帐aws.push弹性魔豆错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我是新来的弹性魔豆,我试图推出一个Rails 4的应用程序。我按照莅临指导的http://docs.aws.amazon.com/elasticbeanstalk/latest/dg/command-reference-get-started.html但是当我去做

I am new to Elastic Beanstalk and am trying to launch a Rails 4 app. I have followed the guide here http://docs.aws.amazon.com/elasticbeanstalk/latest/dg/command-reference-get-started.html but when I go to do

git aws.push

它告诉我,我更新了错误。

It tells me that my update had errors.

[Instance: i-a6482b8b Module: AWSEBAutoScalingGroup ConfigSet: null] Command failed on instance. Return code: 1 Output: Error occurred during build: Command hooks failed .

在EBS日志只是挤满了许多令人困惑的项目,我不熟悉。这是很难说什么,分享什么,但是这两个领域中脱颖而出

The ebs log is just jam packed with lots of confusing items I am not familiar with. It is hard to tell what to share but these two areas stood out

  1. 很多没有在这里所以这不是一个伟大的标志。还呼吁一堆蟒蛇文件,这是令人困惑,因为我要运行64位的亚马逊的Linux 2014.03 v1.0.4运行的Ruby 2.0(乘客独立)。

  1. Lots of No's here so that isn't a great sign. Also calls a bunch of python files which is confusing because I should be running 64bit Amazon Linux 2014.03 v1.0.4 running Ruby 2.0 (Passenger Standalone).

14-09-22 05:31:28375 [信息]运行configSet红外线WriteApplication2 2014年9月22日05:31:28376 [信息]运行配置红外线WriteApplication2 指定28376 [调试]没有包:2014年9月22日05:31 指定28376 [调试]没有群体:2014年9月22日05:31 2014年9月22日05:31:28377 [DEBUG]没有用户指定的 指定28377 [调试]无来源:2014年9月22日05:31 2014年9月22日05:31:28377 [DEBUG]写作内容到/ opt / elasticbeanstalk /斌/ download_source_bundle 2014年9月22日05:31:28377 [DEBUG]检索从<一个内容href="https://s3.amazonaws.com/elasticbeanstalk-env-resources-us-east-1/eb_patching_resources/download_source_bundle.py" rel="nofollow">https://s3.amazonaws.com/elasticbeanstalk-env-resources-us-east-1/eb_patching_resources/download_source_bundle.py 2014年9月22日05:31:28624 [调试]设置模式的/ opt / elasticbeanstalk /斌/ download_source_bundle到000750 2014年9月22日05:31:28625 [DEBUG]设置所有者0和组0的/ opt / elasticbeanstalk /斌/ download_source_bundle 2014年9月22日05:31:28625 [调试]运行命令01downloadVersion 2014年9月22日05:31:28626 [DEBUG]没有测试命令01downloadVersion 2014年9月22日05:31:29354 [信息]命令01downloadVersion成功 2014年9月22日05:31:29,355 [DEBUG]命令01downloadVersion输出: 2014年9月22日05:31:29,355 [调试]运行命令02deleteVersionDownloadScriptFile 2014年9月22日05:31:29356 [DEBUG]没有测试命令02deleteVersionDownloadScriptFile 2014年9月22日05:31:29,370 [信息]命令02deleteVersionDownloadScriptFile成功 2014年9月22日05:31:29371 [DEBUG]命令02deleteVersionDownloadScriptFile输出: 指定29371 [调试]号服务:2014年9月22日05:31 2014年9月22日05:31:29384 [信息]运行configSet红外线嵌入式preBuild 2014年9月22日05:31:29388 [信息]运行configSet钩形preAppDeploy 2014年9月22日05:31:29389 [信息]运行配置钩形preAppDeploy 指定29389 [调试]没有包:2014年9月22日05:31 指定29389 [调试]没有群体:2014年9月22日05:31 2014年9月22日05:31:29389 [DEBUG]没有用户指定的 指定29390 [调试]无来源:2014年9月22日05:31 指定29390 [调试]号文件:2014年9月22日05:31 2014年9月22日05:31:29390 [调试]运行命令挂钩 2014年9月22日05:31:29390 [DEBUG]没有测试命令挂钩 2014年9月22日05:31:41367 [错误]命令挂钩(directoryHooksExecutor.py --path的/ opt / elasticbeanstalk /钩/ appdeploy / pre /)失败 2014年9月22日05:31:41367 [DEBUG]命令挂钩的输出: 2014年9月22日05:31:41368 [错误]构建的钩形preAppDeploy过程中遇到的错误:命令挂钩失败 回溯(最近通话最后一个):   文件/usr/lib/python2.6/site-packages/cfnbootstrap/construction.py,线路511,在run_config     CloudFormationCarpenter(配置,self._auth_config).build(工作日志)   文件/usr/lib/python2.6/site-packages/cfnbootstrap/construction.py,247线,在建     修改['命令'] =命令工具()。申请(self._config.commands)   文件/usr/lib/python2.6/site-packages/cfnbootstrap/command_tool.py,线路113,在申请     提高ToolError(U命令%s失败%名称) ToolError:命令挂钩失败 2014年9月22日05:31:41369 [错误]未处理的构建过程中的异常:命令挂钩失败 回溯(最近通话最后一个):   文件/选择/ AWS /斌/ CFN-初始化,第122行,在     worklog.build(detail.metadata,configSets)   文件/usr/lib/python2.6/site-packages/cfnbootstrap/construction.py,117线,在建     承包商(元数据).build(configSets,个体经营)   文件/usr/lib/python2.6/site-packages/cfnbootstrap/construction.py,502线,在建     self.run_config(配置,工作日志)   文件/usr/lib/python2.6/site-packages/cfnbootstrap/construction.py,线路511,在run_config     CloudFormationCarpenter(配置,self._auth_config).build(工作日志)   文件/usr/lib/python2.6/site-packages/cfnbootstrap/construction.py,247线,在建     修改['命令'] =命令工具()。申请(self._config.commands)   文件/usr/lib/python2.6/site-packages/cfnbootstrap/command_tool.py,线路113,在申请     提高ToolError(U命令%s失败%名称)

14-09-22 05:31:28,375 [INFO] Running configSet Infra-WriteApplication2 2014-09-22 05:31:28,376 [INFO] Running config Infra-WriteApplication2 2014-09-22 05:31:28,376 [DEBUG] No packages specified 2014-09-22 05:31:28,376 [DEBUG] No groups specified 2014-09-22 05:31:28,377 [DEBUG] No users specified 2014-09-22 05:31:28,377 [DEBUG] No sources specified 2014-09-22 05:31:28,377 [DEBUG] Writing content to /opt/elasticbeanstalk/bin/download_source_bundle 2014-09-22 05:31:28,377 [DEBUG] Retrieving contents from https://s3.amazonaws.com/elasticbeanstalk-env-resources-us-east-1/eb_patching_resources/download_source_bundle.py 2014-09-22 05:31:28,624 [DEBUG] Setting mode for /opt/elasticbeanstalk/bin/download_source_bundle to 000750 2014-09-22 05:31:28,625 [DEBUG] Setting owner 0 and group 0 for /opt/elasticbeanstalk/bin/download_source_bundle 2014-09-22 05:31:28,625 [DEBUG] Running command 01downloadVersion 2014-09-22 05:31:28,626 [DEBUG] No test for command 01downloadVersion 2014-09-22 05:31:29,354 [INFO] Command 01downloadVersion succeeded 2014-09-22 05:31:29,355 [DEBUG] Command 01downloadVersion output: 2014-09-22 05:31:29,355 [DEBUG] Running command 02deleteVersionDownloadScriptFile 2014-09-22 05:31:29,356 [DEBUG] No test for command 02deleteVersionDownloadScriptFile 2014-09-22 05:31:29,370 [INFO] Command 02deleteVersionDownloadScriptFile succeeded 2014-09-22 05:31:29,371 [DEBUG] Command 02deleteVersionDownloadScriptFile output: 2014-09-22 05:31:29,371 [DEBUG] No services specified 2014-09-22 05:31:29,384 [INFO] Running configSet Infra-EmbeddedPreBuild 2014-09-22 05:31:29,388 [INFO] Running configSet Hook-PreAppDeploy 2014-09-22 05:31:29,389 [INFO] Running config Hook-PreAppDeploy 2014-09-22 05:31:29,389 [DEBUG] No packages specified 2014-09-22 05:31:29,389 [DEBUG] No groups specified 2014-09-22 05:31:29,389 [DEBUG] No users specified 2014-09-22 05:31:29,390 [DEBUG] No sources specified 2014-09-22 05:31:29,390 [DEBUG] No files specified 2014-09-22 05:31:29,390 [DEBUG] Running command hooks 2014-09-22 05:31:29,390 [DEBUG] No test for command hooks 2014-09-22 05:31:41,367 [ERROR] Command hooks (directoryHooksExecutor.py --path /opt/elasticbeanstalk/hooks/appdeploy/pre/) failed 2014-09-22 05:31:41,367 [DEBUG] Command hooks output: 2014-09-22 05:31:41,368 [ERROR] Error encountered during build of Hook-PreAppDeploy: Command hooks failed Traceback (most recent call last): File "/usr/lib/python2.6/site-packages/cfnbootstrap/construction.py", line 511, in run_config CloudFormationCarpenter(config, self._auth_config).build(worklog) File "/usr/lib/python2.6/site-packages/cfnbootstrap/construction.py", line 247, in build changes['commands'] = CommandTool().apply(self._config.commands) File "/usr/lib/python2.6/site-packages/cfnbootstrap/command_tool.py", line 113, in apply raise ToolError(u"Command %s failed" % name) ToolError: Command hooks failed 2014-09-22 05:31:41,369 [ERROR] Unhandled exception during build: Command hooks failed Traceback (most recent call last): File "/opt/aws/bin/cfn-init", line 122, in worklog.build(detail.metadata, configSets) File "/usr/lib/python2.6/site-packages/cfnbootstrap/construction.py", line 117, in build Contractor(metadata).build(configSets, self) File "/usr/lib/python2.6/site-packages/cfnbootstrap/construction.py", line 502, in build self.run_config(config, worklog) File "/usr/lib/python2.6/site-packages/cfnbootstrap/construction.py", line 511, in run_config CloudFormationCarpenter(config, self._auth_config).build(worklog) File "/usr/lib/python2.6/site-packages/cfnbootstrap/construction.py", line 247, in build changes['commands'] = CommandTool().apply(self._config.commands) File "/usr/lib/python2.6/site-packages/cfnbootstrap/command_tool.py", line 113, in apply raise ToolError(u"Command %s failed" % name)

这是看上去极其恶劣的另一个领域。我已经安装了Git的,我不知道为什么它是问包...

This is another area that looked exceptionally bad. I have git installed and am not sure why it is asking about bundle...

  • 在捆绑安装 不要运行捆扎机为根。打捆可以要求sudo的,如果它是必要的,并 安装你的包作为根将打破这个应用程序的所有非root 用户在本机上。 从 https://rubygems.org/ 取宝石元........ 您需要安装GIT中能够使用的宝石从git仓库。求助 安装git的,请参考GitHub的教程在 https://help.github.com/articles/set-up-git
  • bundle install Don't run Bundler as root. Bundler can ask for sudo if it is needed, and installing your bundle as root will break this application for all non-root users on this machine. Fetching gem metadata from https://rubygems.org/........ You need to install git to be able to use gems from git repositories. For help installing git, please refer to GitHub's tutorial at https://help.github.com/articles/set-up-git

2014年9月22日05:31:41280 [错误](4868 MainThread)directoryHooksExecutor.py-33] [根directoryHooksExecutor错误]脚本/opt/elasticbeanstalk/hooks/appdeploy/$p$p/10_bundle_install.sh失败,返回code 11

2014-09-22 05:31:41,280 [ERROR] (4868 MainThread) [directoryHooksExecutor.py-33] [root directoryHooksExecutor error] Script /opt/elasticbeanstalk/hooks/appdeploy/pre/10_bundle_install.sh failed with returncode 11

我为code段为奇数道歉,我只是不能取胜的今天!

I apologize for the code snippets being odd, I just can't win today!

有没有人有AWS /弹性魔豆的经验,可以指导我如何解决此?

Does anyone have AWS/Elastic Beanstalk experience that can guide me in how to troubleshoot this?

推荐答案

你有混帐安装在您的EC2实例?

Do you have git installed on your ec2 instance?

您可以通过使用ebextension安装。创建一个名为 .ebextensions / 01-git.config 。文件名应该有一个的.config 扩展。

You can install it by using an ebextension. Create a file called .ebextensions/01-git.config. The file name should have a .config extension.

的文件的内容可以是如下:

The contents of the file can be as follows:

packages:
  yum:
    git: []

这文件是YAML格式,以便缩进是非常重要的。 你可以阅读更多关于包ebextensions第<一href="http://docs.aws.amazon.com/elasticbeanstalk/latest/dg/customize-containers-ec2.html#customize-containers-format-packages">here. 提交该文件并重新运行git aws.push。这将部署新的应用程序版本,您的环境,这将在您的EC2实例安装的git。

This file is in YAML format so indentation is important. You can read more about packages section of ebextensions here. Commit this file and run git aws.push again. It will deploy a new application version to your environment and that will install git on your EC2 instances.

最有可能您的Gemfile有消息人士的git的网址。这就是为什么打捆尝试使用混帐获取。 您也可以考虑使用vendored宝石,弹性青苗。阅读更多<一href="http://blogs.aws.amazon.com/application-management/post/Tx2XVRWSS4E971S/Locally-Packaging-Gem-Dependencies-for-Ruby-Applications-in-Elastic-Beanstalk">here.

Most likely your Gemfile has sources as git urls. That is why bundler is trying to fetch using git. You can also consider using vendored gems with Elastic Beanstalk. Read more here.

另外对于Python文件,这些都是Python脚本的弹性魔豆运行到部署应用程序的版本在您的实例。

Also regarding the python files, those are python scripts that Elastic Beanstalk runs to deploy the application version on your instances.

这篇关于第一次混帐aws.push弹性魔豆错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆