WP Media Folder Addon: Amazon S3 Integration
1. Create an IAM User
The Amazon S3 integration with WP Media Folder is included in the Add-on. You need to install this add-on (plugin) in addition to WP Media Folder. The addon includes integration for Google Drive, Google Photo, Dropbox and OneDrive too.
First, you need login to Amazon Console or sign up if you don't have a AWS S3 account.
Once you have logged into the console, you will need to create a new IAM user. Then go to the IAM Users page in the AWS Console, click the Add user button.
Next enter a name for the user and select the checkbox for Programmatic access as Access type, then click the Next: Permissions button.
To allow the new user to manage buckets and objects in the S3 service, you need to grant specific permissions. Click on the “Attach existing policies directly” button, and then enter “S3” in the filter policies input box. Select the “AmazonS3FullAccess” policy, then click the Next: Tags button.
You can skip this step or add your key if needed. Then click on the Next: Review button.
If everything looks good, click the Create user button.
A security screen will be displayed with security credentials for the user, which consists of an Access Key ID and a Secret Access Key. Amazon will not show these again so please download them as a .csv and also copy them somewhere safe. If you lose them, you can always create a new set of keys from the console but you cannot retrieve the secret key again later.
Create a bucket
In order to use Amazon S3, you should create a new bucket. Please go to the bucket area: https://s3.console.aws.amazon.com/s3/buckets. Then click on Create bucket button.
In the General configuration, input bucket name, select a AWS Region, and in Object Ownership section, select ACLs enabled > Object writer option.
In the Block Public Access settings for this bucket section, untick the option: "Block all public access" and tick on the option: "I acknowledge that the current..." as on the image below.
Then let all the rest options as default, and click on Create bucket button.
Finally, a new bucket should be created successfully with the status of Access column: "Objects can be public".
Or you can create s new bucket in WP Media Folder settings. Navigate to menu Settings > WP Media Folder > Cloud > Offload Media > Amazon S3, click on Bucket settings and selection button. At the bottom of the popup, input the bucket name and click on Create button.
2. Login to Amazon S3 from WP Media Folder
Return to the WordPress dashboard and click on the menu Settings > WP Media Folder > Cloud > Offload Media > Amazon S3 tab. Paste the following into the form fields:
- Access Key ID
- Secret Access Key
After that, save the settings and the connection should be a success. Please go to the next step to discover AWS S3 features.
3. How does it work? What can I do with Amazon S3?
How does it work?
Once you've connected WP Media Folder with Amazon S3 and please select a bucket or create a new one where all your data will be stored.
And you can enable Copy to Amazon S3 option, all your new media uploaded will be sent to Amazon S3.
And if you want to sync your uploaded media before using Amazon S3 integration, click on Synchronize with Amazon S3 button. Then it will send all your existing media library to your S3 bucket.
In order to offload the media on your site, you should enable Remove after upload option, your media library will be completely stored on Amazon S3 instead of your server.
By enabling Attachment label option, the information on each media will be displayed when you hover on the aws3 label on the top right.
When you want to change your media location or remove the plugin, click on Retrieve Amazon S3 Media button, then all your media will be copied from Amazon to your media library. All former link added in your content will remain in place (no broken link).
Advanced settings and actions
Cloudfront is integrated with our plugin. First, you should go to this link to configure an Amazon CloudFront.
Then you need to enable this option and then add your custom domain (CNAME).
You can select a bucket to import folders and files from S3 server to your Media library. Or copy all files from a bucket to another one.