amazon-web-services - 配置 aws cli 使用 fakes3

标签 amazon-web-services amazon-s3 aws-cli

热衷于设置假 s3,让它通过 docker setup 工作。在端口 4569 上运行。我不知道如何使用 aws cli(版本 1.10.6)进行测试。专门更改访问的端口。

即想做一个命令

 $ aws s3 cp test.txt s3://mybucket/test2.txt

我需要指定端口,我试过了
  • --port settings on command line :即 AWS_ACCESS_KEY_ID=ignored AWS_SECRET_ACCESS_KEY=ignored aws s3 --profile fakes3 cp test.txt s3://mybucket/test2.txt(表示无效参数)
  • adding a profile and including end_point="localhost:4569 在 ~/.aws` 中的配置中。给出关于 AUTH Key
  • 的错误
  • 在 443 上运行 fakes3 但随后与我的本地机器发生冲突

  • 有没有人让 aws cli 与 fakes3 一起工作?
     $ aws s3 --version
     aws-cli/1.10.6 Python/2.7.11 Darwin/15.2.0 botocore/1.3.28
    

    最佳答案

    使用 --endpoint-url 参数。如果 fakes3 正在监听端口 4569,请尝试以下操作:

    aws --endpoint-url=http://localhost:4569 s3 ls
    

    关于amazon-web-services - 配置 aws cli 使用 fakes3,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/36514290/

    相关文章:

    amazon-web-services - AWS S3 中的空文件夹

    javascript - 无法读取未定义的属性 'username' - JavaScript

    javascript - 如果我没有将回调包装在 function() {} 中,则 jQuery.ajax() 调用成功,否则失败

    amazon-web-services - AWS CLI 筛选器返回特定 AMI 名称的最新 AMI 的唯一列表

    amazon-web-services - AWS CLI 从 AWS CLI 获取私有(private)存储桶的下载 S3 URL

    amazon-web-services - EC2 卷 : how do I set it so that it WILL delete on termination?

    mysql - 自动将一个账户的RDS中的Mysql数据复制到另一个账户的RDS

    python - Django 和 S3 - 静态 URL 不会改变

    amazon-s3 - Google Drive 将用作我们的 SaaS 存储

    aws-sdk - AWS SDK 与 AWS CLI - AWS 云形成 - Terraform