S3 Bucket and Policy Setup for Bagisto Amazon S3 Extension

Updated 14 October 2024

Creating an S3 bucket with the necessary bucket policies setup is one of the most basic and important things that a user must do to use the Laravel eCommerce Amazon S3 Extension.

Using our module, users may connect their Bagisto store to an Amazon S3 bucket. However, in AWS, you must first create a bucket and set up the appropriate bucket policy.

To use with the Laravel eCommerce Amazon S3 Extension, follow the below-mentioned steps to set up S3 bucket policies.

1: Creation of an IAM user

2: Creation of an S3 bucket

3: Bucket Policy Setup

4: CORS Configuration

 

Creation of an I AM User

(i) Firstly, Sign in to your AWS account and select the I AM service.

 

Amazon S3 Full Access

 

Amazon S3 Full Access

 

(ii) Select Access management | Users from the side navigation menu, and then Add user.

 

Amazon S3 Full Access

 

(iii) Set the Username and Access Permissions.

Enter the new username in the User name section, then tick the Programmatic access option in the Access type section to give the user only programmatic access, then click Next: Permissions.

 

Amazon S3 Full Access

 

(iv) Select Attach existing policies directly, followed by Create policy. After that, search for Amazon S3 Full Access, check the box, and Select Next: Tags.

 

Amazon S3 Full Access

 

(v) Select Next: Review, and finally, Create User after you’re done.

 

Create User

 

(vi) Download the .CSV file and save the new user’s credentials (Access Key ID and Secret Access Key).

 

CSV file

 

Creation of an S3 Bucket

(i) Select the S3 among the available AWS services or you can search for an S3 service in the search box.

 

S3 Bucket

 

(ii) You are redirected to the S3 dashboard by clicking on S3 in the previous step. Here you may get a list of your buckets across regions and you can also create a new bucket.

For new bucket create, just click on Create bucket as shown below.

 

Create bucket

 

(iii) In Create bucket wizard:

 

Create bucket

 

(iv) At last scroll down to the bottom and click Create bucket.

 

Create bucket

 

Your bucket has been created. Note down the name and the region of the bucket since you’ll need it later.

 

Bucket Policy Setup

There are two things that must be required in order to set up a bucket policy, IAM User ARN and Bucket name.

S3 permissions for the awsexamplebucket1 bucket – an example of a bucket policy.

 

 

CORS Configuration

CORS configuration allows you to set up your bucket to accept cross-origin requests. If you’re using the S3 console to configure CORS, you’ll need to deploy JSON to do so.

Only JSON CORS configurations are supported by the new S3 console.

 

 

Your S3 bucket is now set up to work with Bagisto. Simply browse to AWS Integration in your Bagisto admin if you already have the module installed.

Provide the Access key, Secret key, and the S3 bucket information that you created in the preceding stages.

 

S3 bucket information

 

S3 bucket information

 

Save your information, and you’re ready to use Bagisto with an S3 bucket.

 

You can also check out our Laravel eCommerce Amazon S3 Extension Module and User Guide (https://bagisto.com/en/laravel-ecommerce-amazon-s3-extension/) for more information.

 

In case of any help, query, or feedback please contact us or raise a ticket.

 

Thank you for reading this document,

Keep in touch!!

. . .

Leave a Comment

Your email address will not be published. Required fields are marked*


Be the first to comment.

Start a Project




    Message Sent!

    If you have more details or questions, you can reply to the received confirmation email.

    Back to Home