By johnkk
Amazon S3 supports file uploads into private buckets via HTML forms, direct from the user’s browser - without an Authentication header.
This is documented for signature v4
https://docs.aws.amazon.com/AmazonS3/latest/API/sigv4-authentication-HTTPPOST.html https://docs.aws.amazon.com/AmazonS3/latest/API/sigv4-post-example.html
and here for v2:
https://docs.aws.amazon.com/AmazonS3/latest/dev/HTTPPOSTExamples.html https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingHTTPPOST.html
I am currently using code as described in the last link for S3 and I’m not sure how to migrate it to Spaces.
It is basically a php-backed HTML form where I calculate the policy and signatures on the backend using ajax and then let the user POST direct to S3 with the valid values in order to upload the file. Any help welcome!
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!
Hi,
so you can do this on DO, using a different technique:
combine these things: Use the “Using temporary access credentials” technique from here: https://medium.com/@ashan.fernando/upload-files-to-aws-s3-using-signed-urls-fa0a0cf489db
and then obvs this stuff server side: https://developers.digitalocean.com/documentation/v2/#authentication
This comment has been deleted
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.