I am using the below upload function to upload in a bucket but this does not overwrite the existing file in the bucket. If I upload an image with a particular format and update the image. The overwrite function does not work.
def upload(byte_stream, path, filename): bucket = doconn.get_bucket() object_key = os.path.join(path, filename) params = dict( Key=object_key, Body=byte_stream, ACL='public-read' ) bucket.put_object(**params) return object_key
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
Click below to sign up and get $100 of credit to try our products over 60 days!