AWS-SDK-PHP多部分文件副本从一个存储桶到不同区域的另一个存储桶
我正在尝试使用AWS-SDK-PHP多部分副本从一个存储桶中复制到不同区域的另一个存储桶。它在同一区域时起作用,但在使用以下代码的不同区域中不行:
$s3Client = new S3Client([
'region' => 'us-west-2',
'version' => '2006-03-01',
'credentials' => [
'key' => AWS_KEY_ID,
'secret' => AWS_SECRET,
]
]);
$copier = new MultipartCopy($s3Client, '/'.$from_bucket_name.'/'.$from_path,
[
'bucket' => 'toBucket',
'key' => $upload->client_id . '/videos/' . $upload->file_name, //to path
'part_size' => $part_size,
'concurrency' => $concurrency
]);
对此的任何帮助将不胜感激!
I am trying to use aws-sdk-php multipart copy to copy from one bucket to another bucket in different regions. It works when on the same regions, but not when in different regions using the below code:
$s3Client = new S3Client([
'region' => 'us-west-2',
'version' => '2006-03-01',
'credentials' => [
'key' => AWS_KEY_ID,
'secret' => AWS_SECRET,
]
]);
$copier = new MultipartCopy($s3Client, '/'.$from_bucket_name.'/'.$from_path,
[
'bucket' => 'toBucket',
'key' => $upload->client_id . '/videos/' . $upload->file_name, //to path
'part_size' => $part_size,
'concurrency' => $concurrency
]);
Any help on this would be greatly appreciated!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论