0

I've got a MinIO bucket (which uses the S3 API for access) and I want to copy all its data into an AWS S3 bucket. They both use the same API, but the I can't find a tool that lets me copy directly from one bucket to another using two sets of credentials.

The only way I can think of is to use s3cmd to download the files one at a time using the MinIO credentials, then use the AWD CLI to upload them to S3.

Does anyone know of a better way?

Mourndark
  • 159
  • 3
  • 14

1 Answers1

2

You can use the minio client to copy content from one bucket to another. If I configure two aliases in minio:

mc alias set source https://minio-server... minio_access_key minio_secret_key
mc alias set destination https://s3.amazonaws.com/ aws_access_key aws_secret_key

Then I can copy from source to destination like this:

mc cp source/bucket/path/to/file destination/bucket/path/to/file

I would argue that, in general, the minio client is probably the best s3 cli available. There's no point to using s3cmd for one operation, the aws cli for another, etc. Just use mc.

larsks
  • 43,623
  • 14
  • 121
  • 180