0

I've setup an Amazon CloudFront CDN to point to an Amazon S3 Bucket. It works great, I love how it's streamlined much of my process!

But I have a problem, every time I do a new upload to it, the new files are permission restricted and I have to go through and manually make things public. What is worse is that it doesn't appear that making a top-level directory public fixes this, even when "re-applied" each time.

Is there some way I can tell Amazon S3 "Yes, keep this folder and everything in it public until I say otherwise"?

5
  • There are no true directory-level permissions in S3, at all. Multi-object operations are exactly that -- the existing objects. How exactly are you uploading the files and then how are you making things public? May 7, 2016 at 15:32
  • I am uploading with SmartFTP, and I am setting permissions through the S3 Web Interface.
    – Ciel
    May 7, 2016 at 15:33
  • SmartFTP should have a way to set the ACL on objects when you upload. You want public-read. May 7, 2016 at 19:49
  • Thank you for the help. Unfortunately I cannot find such an option, I will keep trying though. What you say about the buckets not having directory level permissions makes sense. If I understand it right, S3 isn't a filesystem - it's more like tables in a database, and the folder is just the index of the table.
    – Ciel
    May 7, 2016 at 20:18
  • Sort of. The index is at the root of the bucket, and the folders don't actually exist. They are derived from the object prefixes, delimited by /. Some tools allow you to "create" a folder, which is just an empty object with a / as the last character in its key (name), a placeholder so you can "select" the folder and upload files "in" it. To upload "foo.jpg" into folder "bar" the actual process behind the scenes is to upload a file named "bar/foo.jpg". The root of the bucket in S3 is empty string, not "/", which is why the object name wouldn't begin with "/" in this example. May 7, 2016 at 21:12

0

You must log in to answer this question.

Browse other questions tagged .