I've been trying to transfer the objects from one bucket of an account1 to another bucket of an account2.
I'm trying to:
source_bucket = s3.Bucket('source-bucket')
destination_bucket = s3.Bucket('destination-bucket')
destination_keys = [object.key for object in destination_bucket.objects.all()]
for object in source_bucket.objects.all():
if (object.key not in destination_keys):
# copy object.key to destination
How can I make the copy?