我创建了两个配置文件(一个用于源,一个用于目标存储桶)并使用以下命令进行复制:
aws s3 cp --profile source_profile s3://source_bucket/file.txt --profile target_profile s3://target_profile/
Run Code Online (Sandbox Code Playgroud)
但它会低于错误.
fatal error: An error occurred (403) when calling the HeadObject operation: Forbidden
Run Code Online (Sandbox Code Playgroud)
看起来我们不能使用aws命令使用多个配置文件.