如果文件夹名称使用AWS GLUE或LAMBDA匹配,则将文件夹从AWS存储库中的一个文件夹复制到另一个文件夹
我有2个AWS存储桶登台,目的地都具有相同数量的子文件夹,让我们假设3。 如此登台的3个名称为A,B,C和目的地具有3 a,b,c。现在,我想从3个子文件夹A,B,C到目的地A,B和C中复制文件,仅当使用AWS GLUE或AWS匹配该名称IE A与A,B,B,B,C到C时,它仅在另一个存储桶中存在。 Lambda。另外,该子文件夹中的文件A,B和C内部的文件可以是任何类型的。
I have 2 AWS buckets staging and destination both have the same number of subfolders let's assume 3.
So staging as 3 named a, b, c and destination have 3 a, b, c. Now i want to copy files from 3 subfolders a, b, c to destination a, b, and c which is present in another bucket only when the name matches ie a to a, b to b, c to c using AWS glue or AWS lambda. Also, the file inside this subfolder a, b, and c can be of any type.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您可以使用Python在Lambda中使用这样的解决方案;
通过boto3 同步两个桶
您可以使用CLI。检查页面底部的示例。
https://docs.aws.aws.aws.aws.amazon.com/cli.com/cli/cli/最新的/参考/s3/sync.html
您还可以从控制台设置S3批次复制。
https://aws.amazon.com/about-aws/whats-new/2022/02/amazon-s3-batch-replication-synchronizes-exististing-data-data-between-between-backets/
You could use a solution like this in lambda using python;
Sync two buckets through boto3
You could use the cli. Check the examples at the bottom of the page.
https://docs.aws.amazon.com/cli/latest/reference/s3/sync.html
You could also set up s3 batch replication from the console.
https://aws.amazon.com/about-aws/whats-new/2022/02/amazon-s3-batch-replication-synchronizes-existing-data-between-buckets/