تحميل الكائنات إلى S3 الخاص لا يعمل

After doing a big research, I’ve not found any guide to upload images to S3 with private ACL.

I’m experiencing a weird behavior where the backups work but not uploadimg of images.

I narrowed the issue down to a problem with ACL of the bucket (I proved that the problem is the ACL since I’m able to upload file using the sdk without specifing the ACL flag). In some cases the “block access to public” permission are set at account level and not bucket level so deactivating the checkbox in the bucket config won’t work.

I noticed that the S3 upload config code was updated, and now the ACL is set based on a param, is there away to pass that config down? discourse/s3_store.rb at tests-passed · discourse/discourse · GitHub

إعجاب واحد (1)

Secure Media Uploads describes how to limit uploads to logged in users. Perhaps that will help?

إعجابَين (2)

I tried that, images get uploaded but I get a 500 error in the dashboard with no clue, no logs

@mahcr،

أواجه نفس المشكلة. يمكنني إجراء النسخ الاحتياطي ولكن لا يمكنني تحميل الصور بسبب “الدلو لا يسمح بـ ACLs”.

بالنسبة لـ IAM، قمت بإرفاق سياسة AmazonS3FullAccess، ولكن لا يزال نفس الخطأ.

هل لديك أي حل؟

إعجاب واحد (1)

أواجه نفس المشكلة: النسخ الاحتياطي يعمل ولكن التحميل لا يعمل.

هذا الدليل قديم:

يبدو أن هذا الدليل قيم لجزء شبكة توصيل المحتوى (CDN)، ولكنه ليس الحل الكامل:

حصلت على نفس المشكلة أيضًا. تحميل النسخ الاحتياطي يعمل ولكن تحميل الصور يظهر “الدلو لا يسمح بـ ACLs”
وتم إصلاحه عن طريق تعديل إذن واحد في IAM وإعدادين في الدلو

أولاً، قمت بتغيير الدليل حول إذن IAM من “s3:HeadBucket” إلى “s3:ListBucket” لأن أمازون قالت إن HeadBucket ليس إذنًا صالحًا

ثم اتبعت الدليل ليكون مطابقًا تمامًا كما هو في صفحة الإذن في الدلو

ثم الجزء الأكثر أهمية، تمكين ACLs، يسمى Edit Object Ownership في علامة التبويب Permissions، مع تمكين ACLs وتعيينها إلى object writer، كل شيء على ما يرام الآن

آمل أن تساعدك تجربتي

3 إعجابات