From 8cae871478f384fc5a78a2468177c567f1cf086f Mon Sep 17 00:00:00 2001 From: Emad Rad Date: Sat, 14 Sep 2024 11:31:38 +0330 Subject: [PATCH] docs: S3 configuration added --- README.md | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/README.md b/README.md index df8bd4de..78e8f5e4 100644 --- a/README.md +++ b/README.md @@ -36,6 +36,24 @@ on LMS ![Preview H5P content in LMS](https://github.com/edly-io/h5pxblock/blob/master/docs/images/preview_content.png?raw=true) +### Configuring S3 as a Storage Backend + +When utilizing AWS S3 to store content, it is essential to configure your settings appropriately. Specifically, you must define the `H5PXBLOCK_STORAGE` setting in your common configuration file, as S3 integration does not support private buckets. + +Here is the required configuration: + +```python +H5PXBLOCK_STORAGE = { + "storage_class": "storages.backends.s3boto3.S3Boto3Storage", + "settings": { + "bucket_name": "my-s3-public-bucket", + "querystring_auth": False, + "custom_domain": "my-s3-public-bucket.s3.eu-central-1.amazonaws.com" + }, +} +``` + +Please ensure that your bucket is publicly accessible to enable seamless content storage and retrieval via S3. # Working with translations