sydadder
sydadder

Reputation: 483

How to Upload to AWS S3 with Transfer Acceleration using Python BOTO

How can I pass a Transfer Acceleration endpoint-url to the boto upload_file function while trying to upload a file to S3?

My current code is:

s3.Bucket(BUCKET).upload_file(filetoupload, pathnfilename, ExtraArgs={'ACL':'public-read'})

Upvotes: 0

Views: 623

Answers (1)

Marcin
Marcin

Reputation: 238111

You would provide it with when you created your resource object:

s3 = boto3.resource('s3', endpoint_url="the_endpoint")

Upvotes: 1

Related Questions