繁体   English   中英

设置EB CLI - 错误非类型get_frozen_credentials

[英]Setting up the EB CLI - error nonetype get_frozen_credentials

Select a default region
1) us-east-1 : US East (N. Virginia)
2) us-west-1 : US West (N. California)
3) us-west-2 : US West (Oregon)
4) eu-west-1 : EU (Ireland)
5) eu-central-1 : EU (Frankfurt)
6) ap-southeast-1 : Asia Pacific (Singapore)
7) ap-southeast-2 : Asia Pacific (Sydney)
8) ap-northeast-1 : Asia Pacific (Tokyo)
9) ap-northeast-2 : Asia Pacific (Seoul)
10) sa-east-1 : South America (Sao Paulo)
11) cn-north-1 : China (Beijing)
(default is 3):5

当我选择一个数字或只是留空时出现以下错误:

错误:AttributeError ::'NoneType'对象没有属性'get_frozen_credentials'

在运行eb init之后--debug:

回溯(最近调用最后一次):文件“/ usr / local / bin / eb”,第11行,在sys.exit(main())文件“/Library/Python/2.7/site-packages/ebcli/core/ebcore .py“,第149行,在主app.run()文件”/Library/Python/2.7/site-packages/cement/core/foundation.py“,第694行,运行self.controller._dispatch()文件” /Library/Python/2.7/site-packages/cement/core/controller.py“,第455行,在_dispatch中返回func()文件”/Library/Python/2.7/site-packages/cement/core/controller.py“ ,第461行,在_dispatch中返回func()文件“/Library/Python/2.7/site-packages/ebcli/core/abstractcontroller.py”,第57行,默认为self.do_command()文件“/Library/Python/2.7 /site-packages/ebcli/controllers/initialize.py“,第67行,在do_command self.set_up_credentials()文件”/Library/Python/2.7/site-packages/ebcli/controllers/initialize.py“,第152行,in set_up_credentials如果不是initializeops.credentials_are_valid():文件“/Library/Python/2.7/site-packages/ebcli/operations/initializeops.py”,第24行,在credentials_are_vali中 d elasticbeanstalk.get_available_solution_stacks()文件“/Library/Python/2.7/site-packages/ebcli/lib/elasticbeanstalk.py”,第239行,在get_available_solution_stacks中结果= _make_api_call('list_available_solution_stacks')文件“/Library/Python/2.7/ site-packages / ebcli / lib / elasticbeanstalk.py“,第37行,在_make_api_call ** operation_options中)文件”/Library/Python/2.7/site-packages/ebcli/lib/aws.py“,第207行,在make_api_call response_data中= operation(** operation_options)文件“/Library/Python/2.7/site-packages/botocore/client.py”,第310行,在_api_call中返回self._make_api_call(operation_name,kwargs)文件“/Library/Python/2.7/ site-packages / botocore / client.py“,第396行,在_make_api_call operation_model,request_dict中)文件”/Library/Python/2.7/site-packages/botocore/endpoint.py“,第111行,在make_request中返回self._send_request( request_dict,operation_model)文件“/Library/Python/2.7/site-packages/botocore/endpoint.py”,第136行,在_send_request request = self.create_request(re quest_dict,operation_model)文件“/Library/Python/2.7/site-packages/botocore/endpoint.py”,第120行,在create_request operation_name = operation_model.name)文件“/Library/Python/2.7/site-packages/botocore/ hooks.py“,第226行,在emit中返回self._emit(event_name,kwargs)文件”/Library/Python/2.7/site-packages/botocore/hooks.py“,第209行,在_emit response = handler(**) kwargs)文件“/Library/Python/2.7/site-packages/botocore/signers.py”,第90行,在处理程序中返回self.sign(operation_name,request)文件“/Library/Python/2.7/site-packages/botocore /signers.py“,第123行,签名signature_version)文件”/Library/Python/2.7/site-packages/botocore/signers.py“,第153行,in get_auth_instance kwargs ['credentials'] = self._credentials.get_frozen_credentials ()AttributeError:'NoneType'对象没有属性'get_frozen_credentials'

您收到此错误是因为您没有初始化AWS Access Key IDAWS Secret Access Key您应该通过运行pip install awscli安装第一个pip install awscli

需要配置aws之后: aws configure

在此之后,您可以运行eb init

也陷入这个错误。 不确定根本原因。 但我仍然在优胜美地。 当我尝试AWS的安装脚本curl -s https://s3.amazonaws.com/elasticbeanstalk-cli-resources/install-ebcli.py | python curl -s https://s3.amazonaws.com/elasticbeanstalk-cli-resources/install-ebcli.py | python它下载EB CLI 3.7.3(Python的2.7.1)。 一位同事尝试使用自制软件在他的机器上(因为他有一段时间没有运行brew更新)设法获得版本3.5.4,它完美地工作。

看起来亚马逊可能已经破坏了Yosemite用户的更新,而不是等待我刚刚下载了工作版本并且没有运行eb init问题

这是我采取的步骤:

  1. 亚马逊在创建一个符号链接到3.7版本usr/local/bin称为eb 删除此链接rm /usr/local/bin/eb
  2. cd /usr/local/Library
  3. 使用自制软件的brew log awsebcli来查找版本3.5.4(21e20f5)的更新提交的sha。
  4. 运行git checkout 21e20f5 /usr/local/Library/Formula/aws-elasticbeanstalk.rb
  5. 现在运行brew install awsebclieb init应该正常运行。

希望有所帮助!

嘿,我遇到了同样的问题,在Arch Linux上第一次运行eb。

对我eb init不是简单地使用eb init

尝试参数化的init,例如用于交互式init

eb init -i

参考: https//docs.aws.amazon.com/elasticbeanstalk/latest/dg/eb3-init.html

希望有帮助:)

我有同样的问题。

我安装了aws-cli(brew install awsebcli)

接下来,运行“aws configure”并提供正确的详细信息。

这解决了我的问题。

也有同样的问题,但解决了一些如何。 正如我第一次这样做,我更喜欢按照一步一步的文档,但导致上述问题,但通过以下简单步骤解决

$ mkdir HelloWorld
$ cd HelloWorld
$ eb init -p PHP
$ echo "Hello World" > index.html
$ eb create dev-env
$ eb open

在我的情况下,按照文档步骤我从来没有要求id / secret但是使用上面的命令它是可能的。

希望它对你有用!

使用凭证存储在~/.aws/credentials ,甚至在调用aws configure ,我仍然必须使用--profile profile_name和失败的命令以及“无属性'get_frozen_credentials'”错误。 这为我修好了。

我有同样的问题,但上述都没有帮助我。 创建IAM用户http://docs.aws.amazon.com/IAM/latest/UserGuide/id_users_create.html并为其生成新密钥而不是使用root和root密钥并以传统方式执行操作后,我的问题得以解决。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM