Amazon S3 Storage Integration – User Manual
Amazon S3 integration allows administrators and vendors to store and retrieve media files (such as product images) efficiently. This guide explains how to configure Amazon S3 storage on the admin and vendor panels, how to set up the S3 bucket on the Amazon side, and how to test the integration within the affiliate script.
Section 1: Setting Up Amazon S3
Step 1: Log in to the Amazon S3 Console
- Visit the Amazon S3 Console.
- Sign in with your AWS account credentials.
Step 2: Create an S3 Bucket
- Navigate to Buckets and click Create Bucket.
- Provide a unique bucket name (e.g.,
affiliate-media-bucket
). - Choose your preferred AWS Region (e.g.,
us-west-2
). - Keep the default settings or configure access controls as needed.
- Click Create Bucket.
Step 3: Configure Permissions
- Adjust Block Public Access Settings:
- Go to the Permissions tab of your S3 bucket.
- Click Edit under the Block Public Access (BPA) settings.
- If your files (e.g., product images) need to be publicly accessible:
- Uncheck Block all public access.
- Confirm changes when prompted.
- Set a Bucket Policy:
- Under the Permissions tab, scroll to the Bucket Policy section.
- Click Edit and paste the following policy:
- Replace
YOUR_BUCKET_NAME
with your actual S3 bucket name. - Save the policy.
- Caution:
- Public access is only necessary if your files need to be accessed without authentication.
- Always review and enable public access settings judiciously to avoid exposing sensitive data.
Section 2: Configuring S3 on the Affiliate Script
Admin Panel: Configuring Amazon S3
- Log in to the Admin Panel of your affiliate script.
- Navigate to Useful Links → Settings → Amazon S3 Storage.
- Fill in the required fields:
- Bucket Name: Enter the name of your S3 bucket (e.g.,
affiliate-media-bucket
). - Region: Enter the AWS region of your bucket (e.g.,
us-west-2
).
- Bucket Name: Enter the name of your S3 bucket (e.g.,
- Save the settings.
Vendor Panel: Configuring Amazon S3
- Vendors log in to the Vendor Panel.
- Navigate to Useful Links → Settings → Amazon S3 Storage.
- Enter the Bucket Name and Region as provided by the admin or as per their own S3 setup.
- Click Test Connection to verify the configuration.
- Save the settings.
Section 3: Using Amazon S3 Integration
Uploading Media to Amazon S3
Admin Side:
- Navigate to Local Store → Products.
- Click Add New Product.
- In the product creation form, under Product Images, you will see an S3 button.
- Click the S3 button:
- If your S3 settings are correct, a popup will appear displaying the files available in your S3 bucket.
- You can select existing images or upload new ones directly to S3 via this interface.
- Select the desired image for your product.
- Complete the product details and save.
Vendor Side:
- Vendors navigate to Store → Products.
- Click Add New Product.
- Follow the same steps as above to use the S3 button for product images.
Testing and Validation
- Verify S3 Access from Affiliate Script:
- Using the S3 button within the product creation page confirms that the affiliate script can access your S3 bucket.
- If the popup shows your S3 files, the integration is working.
- Check Image Display:
- On the storefront or product page, verify that the product image displays correctly.
- This ensures that public access permissions are set appropriately.
Section 4: Troubleshooting
Common Issues
- S3 Button Not Showing Files or Not Working:
- Ensure that the Bucket Name and Region are correctly entered in the affiliate script settings.
- Use the Test Connection button to verify connectivity.
- Check for error messages and consult the system logs if necessary.
- Permission Denied Errors:
- Verify that your S3 bucket permissions allow the affiliate script to access the files.
- Ensure that the IAM user has appropriate permissions (e.g.,
AmazonS3FullAccess
).
- Images Not Displaying on the Website:
- Confirm that the bucket’s public access settings and bucket policy allow for public reading of objects.
- Check the image URLs to ensure they point to the correct S3 location.
Key Notes
- File Management: Files uploaded to S3 do not consume your web server’s storage, enhancing performance and scalability.
- Security Considerations:
- Only grant the minimum necessary permissions to IAM users.
- Be cautious when enabling public access; only public files (like product images) should be accessible.
- Testing Connectivity:
- Always use the Test Connection button after configuring or changing S3 settings.
- Regularly check the integration by adding new products and uploading images.