douju3911 2014-07-19 20:23
浏览 41
已采纳

RiakCS S3 PHP客户端库

Is there any RiakCS S3 PHP client library out there? The best I could find was S3cmd command line client software.

Also I've seen there is Riak PHP Client, but it looks like there is nothing related to S3.

I've installed aws-sdk-php-laravel and used same credentials as for RiakCS S3 but it doesn't seem to work. Error message below:

The AWS Access Key Id you provided does not exist in our records.

Thank you for any guidance or advice.

  • 写回答

2条回答 默认 最新

  • doujian1050 2014-07-21 22:38
    关注

    Actually, if you are using Riak, it wouldn't be a proxy, it would be a completely different endpoint. So you should do it this way with the base_url option:

    $s3 = S3Client::factory([
        'base_url'       => 'http://127.0.0.1:8080',
        'region'         => 'my-region',
        'key'            => 'my-key',
        'secret'         => 'my-secret',
        'command.params' => ['PathStyle' => true]
    ]);
    

    Using 'command.params' allows you to set a parameter used in every operation. You will need to use the 'PathStyle' option on every request to make sure the SDK does not move your bucket into the host part of the URL like it is supposed to do for Amazon S3.

    This is was all talked about on an issue on GitHub.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?

悬赏问题

  • ¥60 用visual studio编写程序,利用间接平差求解水准网
  • ¥15 Llama如何调用shell或者Python
  • ¥20 谁能帮我挨个解读这个php语言编的代码什么意思?
  • ¥15 win10权限管理,限制普通用户使用删除功能
  • ¥15 minnio内存占用过大,内存没被回收(Windows环境)
  • ¥65 抖音咸鱼付款链接转码支付宝
  • ¥15 ubuntu22.04上安装ursim-3.15.8.106339遇到的问题
  • ¥15 blast算法(相关搜索:数据库)
  • ¥15 请问有人会紧聚焦相关的matlab知识嘛?
  • ¥15 网络通信安全解决方案